Project

General

Profile

Specification » History » Version 3

Soh Keong, 11/25/2020 03:52 PM

1 1 Soh Keong
{{toc}}
2
3
h1. Specification
4
5
h1. Activity Diagram
6
!express_checkout.png!
7
8
h1. Programming Guide
9
10
h3. Jar version 
11
12
|_. version |_. Description  |
13
| 1.0       | Init           |
14
15
h3. Jar File Download
16
17
"Jar":/redmine/attachments/download/524/Paypal_Connector-1.8.jar
18
"Properties":/redmine/attachments/download/525/paypal_Aces.properties
19
20
* *mol.properties*
21
22
# *PP_USER_MALL*                  - Provided by PayPal
23
# *PP_PASSWORD_MALL*              - Provided by PayPal
24
# *PP_SIGNATURE_MALL*             - Provided by PayPal
25
# *PP_CHECKOUT_URL_MALL*          - Provided by PayPal
26
# *PP_NVP_ENDPOINT_MALL*          - Provided by PayPal
27
# *PP_ALLOW_STATUS_PENDING_MALL*  - Provided by PayPal
28
# *API_VERSION*                   - Provided by PayPal
29
# *LOGO_IMG*                      - Logo @payment page
30
# *SOLUTIONTYPE*                  - Sole (no need Paypal account) / Mark (Must have Paypal account)
31
# *CONNECTION_TIMEOUT*            - Set connection timeout
32
# *READ_TIMEOUT*                  - Set connection read timeout
33
34
h3. Database Table
35
36
<pre>
37
CREATE TABLE PAYPAL_INTERFACE (
38
	ORDER_ID VARCHAR(15) NOT NULL, 
39
	TRX_TYPE VARCHAR(5),
40
	SHOPPER_REF_NO INTEGER,
41
	CHARGE_AMT DECIMAL(15,2), 
42
	CURRENCY_CODE VARCHAR(3),
43
	STATUS VARCHAR(2), 
44
	RESPONSE_CODE VARCHAR(20),
45
	RESPONSE_MESSAGE VARCHAR(100),
46
	IS_VALID CHARACTER NOT NULL, 
47
	PAY_DATE TIMESTAMP,
48
	CREATE_DATETIME TIMESTAMP NOT NULL,
49
	MODIFY_DATETIME TIMESTAMP, 
50
	PRIMARY KEY (ORDER_ID));
51
</pre>
52 2 Soh Keong
53
h3. getUrl
54
55
<pre>
56
com.ecosway.paypal.service.PaypalService service = new com.ecosway.paypal.service.PaypalServiceImpl();
57
58
String[] results = service.getUrl(Connection conn, com.ecosway.paypal.model.PaymentPaypal bean)
59
</pre>
60
61
# *String[] results* 
62 3 Soh Keong
> * *[0]* - com.ecosway.paypal.common.CommonConstant.PAYPAL_ACK_SUCCESS | PAYPAL_ACK_SUCCESS_WITH_WARNING | PAYPAL_ACK_ERROR
63
> * *[1]* - Token
64 2 Soh Keong
65
# *conn*        - Database connection.
66
# *bean*        - PaymentPaypal object.
67 3 Soh Keong
> * *company*         - String
68
> * *orderID*         - String
69
> * *amount*          - double
70
> * *currencyCode*    - String
71
> * *transactionType* - String
72
> * *shopperRefID*    - int
73
> * *paymentType*     - String
74
> * *returnUrl*       - String
75
> * *cancelUrl*       - String
76
> * *itemPaypalList*  - List<ItemPaypal>
77
>> * * *itemName*        - String 
78
>> * * *description*     - String
79
>> * * *itemCode*        - String
80
>> * * *itemPrice*       - double
81
>> * * *quantity*        - int
82 2 Soh Keong
83
h3. updateTransaction
84
85
<pre>
86
com.ecosway.paypal.model.ResponsePaypal resultBean = service.updateTransaction(Connection conn, HttpServletRequest request, String company)
87
</pre>
88
89
# *com.ecosway.paypal.model.ResponsePaypal*
90 3 Soh Keong
> * *company*         - String
91
> * *orderID*         - String
92
> * *amount*          - double
93
> * *currencyCode*    - String
94
> * *transactionType* - String
95
> * *status*          - String
96
> * *valid*           - boolean
97
> * *responseCode*    - String
98
> * *responseMessage* - String
99
> * *payDate*         - Date