Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
payments-vendor-simulator
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
2
Merge Requests
2
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
payments
payments-vendor-simulator
Commits
acfc696e
Commit
acfc696e
authored
Sep 13, 2021
by
Christopher Cottier
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dynamic address data add. Dummy data ported to response object to have context on fields
parent
9d85fc75
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
35 additions
and
42 deletions
+35
-42
CreditCardAdditionalData.java
...lator/creditcard/domain/dto/CreditCardAdditionalData.java
+29
-29
CreditCardAuthorizeResponse.java
...or/creditcard/domain/dto/CreditCardAuthorizeResponse.java
+3
-3
CreditCardRequest.java
...dorsimulator/creditcard/domain/dto/CreditCardRequest.java
+1
-9
CreditCardService.java
...endorsimulator/creditcard/services/CreditCardService.java
+2
-1
No files found.
src/main/java/com/nisum/paymentvendorsimulator/creditcard/domain/dto/CreditCardAdditionalData.java
View file @
acfc696e
...
...
@@ -11,34 +11,34 @@ import lombok.Setter;
@NoArgsConstructor
public
class
CreditCardAdditionalData
{
private
String
avsResult
;
private
String
cardSummary
;
private
String
refusalReasonRaw
;
private
String
eci
;
private
String
acquirerAccountCode
;
private
String
expiryDate
;
private
String
xid
;
private
String
cavvAlgorithm
;
private
String
cardBin
;
private
String
threeDAuthenticated
;
private
String
cvcResultRaw
;
private
String
paymentMethodVariant
;
private
String
acquirerReference
;
private
String
cardIssuingCountry
;
private
String
liabilityShift
;
private
String
authCode
;
private
String
cardHolderName
;
private
String
isCardCommercial
;
private
String
threeDOffered
;
private
String
threeDOfferedResponse
;
private
String
authorisationMid
;
private
String
issuerCountry
;
private
String
cvcResult
;
private
String
cavv
;
private
String
threeDAuthenticatedResponse
;
private
String
avsResultRaw
;
private
String
paymentMethod
;
private
String
cardPaymentMethod
;
private
String
acquirerCode
;
private
String
avsResult
=
"4 AVS not supported for this card type"
;
private
String
cardSummary
=
"1111"
;
private
String
refusalReasonRaw
=
"AUTHORISED"
;
private
String
eci
=
"N/A"
;
private
String
acquirerAccountCode
=
"TestPmmAcquirerAccount"
;
private
String
expiryDate
=
"8/2018"
;
private
String
xid
=
"N/A"
;
private
String
cavvAlgorithm
=
"N/A"
;
private
String
cardBin
=
"411111"
;
private
String
threeDAuthenticated
=
"false"
;
private
String
cvcResultRaw
=
"1"
;
private
String
paymentMethodVariant
=
"visa"
;
private
String
acquirerReference
=
"7CAI01SQB4C"
;
private
String
cardIssuingCountry
=
"NL"
;
private
String
liabilityShift
=
"false"
;
private
String
authCode
=
"52328"
;
private
String
cardHolderName
=
"Naga Bolla"
;
private
String
isCardCommercial
=
"unknown"
;
private
String
threeDOffered
=
"false"
;
private
String
threeDOfferedResponse
=
"N/A"
;
private
String
authorisationMid
=
"1000"
;
private
String
issuerCountry
=
"NL"
;
private
String
cvcResult
=
"1 Matches"
;
private
String
cavv
=
"N/A"
;
private
String
threeDAuthenticatedResponse
=
"N/A"
;
private
String
avsResultRaw
=
"4"
;
private
String
paymentMethod
=
"visa"
;
private
String
cardPaymentMethod
=
"visa"
;
private
String
acquirerCode
=
"TestPmmAcquirer"
;
}
src/main/java/com/nisum/paymentvendorsimulator/creditcard/domain/dto/CreditCardAuthorizeResponse.java
View file @
acfc696e
...
...
@@ -12,8 +12,8 @@ import lombok.Setter;
public
class
CreditCardAuthorizeResponse
{
CreditCardAdditionalData
additionalData
;
private
String
pspReference
;
private
String
resultCode
;
private
String
authCode
;
private
String
pspReference
=
"8525125417115"
;
private
String
resultCode
=
"Authorised"
;
private
String
authCode
=
"52329"
;
}
src/main/java/com/nisum/paymentvendorsimulator/creditcard/domain/dto/CreditCardRequest.java
View file @
acfc696e
...
...
@@ -14,15 +14,7 @@ public class CreditCardRequest {
CreditCardAmount
amount
;
String
reference
;
String
merchantAccount
;
CreditCardAddress
billingAddress
;
// String returnUrl; // for Adyen payment, not classic integration, do we need?
@Override
public
String
toString
()
{
return
"CreditCardRequest{"
+
"card="
+
card
+
", amount="
+
amount
+
", reference='"
+
reference
+
'\''
+
", merchantAccount='"
+
merchantAccount
+
'\''
+
'}'
;
}
}
src/main/java/com/nisum/paymentvendorsimulator/creditcard/services/CreditCardService.java
View file @
acfc696e
...
...
@@ -23,8 +23,9 @@ public class CreditCardService {
CreditCardResponse
res
=
new
CreditCardResponse
();
res
.
setCardNumber
(
ccRequest
.
getCard
().
getNumber
());
res
.
setCvv
(
ccRequest
.
getCard
().
getCvc
());
res
.
setId
(
"123456789"
);
CreditCardAddress
ccAddress
=
new
CreditCardAddress
(
"5708 Owens Dr"
,
"APT 106"
,
"Pleasanton"
,
"USA"
,
"USA"
,
"94588"
);
CreditCardAddress
ccAddress
=
ccRequest
.
getBillingAddress
(
);
res
.
setBillingAddress
(
ccAddress
);
res
.
setAmount
(
ccRequest
.
getAmount
().
getValue
());
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment