Project

General

Profile

Specification » History » Version 1

Soh Keong, 10/27/2020 12:04 PM

1 1 Soh Keong
{{toc}}
2
3
h1. Specification
4
5
h1. Programming Guide
6
7
h3. Jar version 
8
9
|_. version |_. Description  |
10
| 2.2       | Init           |
11
12
h3. Jar File Download
13
14
"Jar":/redmine/attachments/download/492/VoucherService-1.5.jar
15
"Properties":/redmine/attachments/download/493/service.properties
16
17
h3. properties file
18
19
* *service.properties*
20
21
# *json.url*                - Dotnet team URL
22
# *json.key*                - provided by json
23
# *connection.timeout*      - set connection timeout
24
# *connection.read.timeout* - set connection read timeout
25
26
h2. Methods
27
28
h3. Common Instance
29
30
<pre>
31
com.cosway.voucher.service.VoucherService service = new com.cosway.voucher.service.VoucherService();
32
</pre>
33
34
h3. getRandomByType
35
36
<pre>
37
com.cosway.voucher.bean.response.VoucherRandomResponseBean resultBean = service.getRandomByType(VoucherRandomByType voucherBean)
38
</pre>
39
40
* *com.cosway.voucher.bean.request.VoucherRandomByType*
41
> * *quantity*    - Int
42
> * *voucherType* - String
43
44
* *com.cosway.voucher.bean.response.VoucherRandomResponseBean*
45
> * *errorCode*    - String
46
> * *errorMsg*     - String
47
> * *totalRecords* - Int
48
> * *voucherList*  - List<VoucherBean>
49
>> * *voucherCode*   - String
50
51
h3. checkVoucher / getVoucherByMemberId
52
53
<pre>
54
com.cosway.voucher.bean.response.VoucherCheckResponseBean resultBean = service.checkVoucher(VoucherCheckBean bean)
55
com.cosway.voucher.bean.response.VoucherCheckResponseBean resultBean = service.getVoucherByMemberId(VoucherByMemberId bean)
56
</pre>
57
58
* *com.cosway.voucher.bean.request.VoucherCheckBean*
59
> * *memberId* - String
60
> * *voucherList*  - List<VoucherBean>
61
>> * *voucherCode*   - String
62
63
* *com.cosway.voucher.bean.request.VoucherByMemberId*
64
> * *memberId* - String
65
66
* *com.cosway.voucher.bean.response.VoucherCheckResponseBean*
67
> * *errorCode*    - String
68
> * *errorMsg*     - String
69
> * *totalRecords* - Int
70
> * *voucherList*  - List<VoucherDetailBean>
71
>> * *errorCode*      - String
72
>> * *errorMsg*       - String
73
>> * *voucherCode*    - String
74
>> * *memberId*       - String
75
>> * *startDate*      - Date
76
>> * *expiryDate*     - Date
77
>> * *amount*         - double
78
>> * *lock*           - boolean
79
>> * *bookingStatus*  - String
80
>> * *promoCode*      - String
81
82
h3. addVoucher / cancelVoucher / utilizeVoucher / lockVoucher / unlockVoucher
83
84
<pre>
85
86
</pre>