From 0c5d7c997afc3689bb6fa61da70fcacbbacd07d1 Mon Sep 17 00:00:00 2001 From: preyearegmi Date: Tue, 8 Jan 2019 15:25:59 +0900 Subject: [PATCH] Account Id key added to kftc account --- .../AutoDebitAccount.java | 21 ++++++-- .../homeV2/presenter/HomeV2Presenter.java | 8 --- .../gateway/SendMoneyV2Gateway.java | 3 -- .../model/SendMoneyAPIRequestBody.java | 50 +++---------------- .../presenter/SendMoneyV2Presenter.java | 5 +- 5 files changed, 25 insertions(+), 62 deletions(-) diff --git a/app/src/main/java/com/gmeremit/online/gmeremittance_native/autodebitV2/model/autodebitaccountlisting/AutoDebitAccount.java b/app/src/main/java/com/gmeremit/online/gmeremittance_native/autodebitV2/model/autodebitaccountlisting/AutoDebitAccount.java index 4bcafbe9..04361f6f 100644 --- a/app/src/main/java/com/gmeremit/online/gmeremittance_native/autodebitV2/model/autodebitaccountlisting/AutoDebitAccount.java +++ b/app/src/main/java/com/gmeremit/online/gmeremittance_native/autodebitV2/model/autodebitaccountlisting/AutoDebitAccount.java @@ -70,6 +70,17 @@ public class AutoDebitAccount implements Parcelable { @SerializedName("AutoDebit") @Expose private String autoDebit; + @SerializedName("KftcAccountId") + @Expose + private String kftcAccountId; + + public String getKftcAccountId() { + return kftcAccountId; + } + + public void setKftcAccountId(String kftcAccountId) { + this.kftcAccountId = kftcAccountId; + } public String getErrorCode() { return errorCode; @@ -239,6 +250,9 @@ public class AutoDebitAccount implements Parcelable { this.autoDebit = autoDebit; } + public AutoDebitAccount() { + } + @Override public int describeContents() { return 0; @@ -267,9 +281,7 @@ public class AutoDebitAccount implements Parcelable { dest.writeString(this.accHolderInfo); dest.writeString(this.walletName); dest.writeString(this.autoDebit); - } - - public AutoDebitAccount() { + dest.writeString(this.kftcAccountId); } protected AutoDebitAccount(Parcel in) { @@ -294,9 +306,10 @@ public class AutoDebitAccount implements Parcelable { this.accHolderInfo = in.readString(); this.walletName = in.readString(); this.autoDebit = in.readString(); + this.kftcAccountId = in.readString(); } - public static final Parcelable.Creator CREATOR = new Parcelable.Creator() { + public static final Creator CREATOR = new Creator() { @Override public AutoDebitAccount createFromParcel(Parcel source) { return new AutoDebitAccount(source); diff --git a/app/src/main/java/com/gmeremit/online/gmeremittance_native/homeV2/presenter/HomeV2Presenter.java b/app/src/main/java/com/gmeremit/online/gmeremittance_native/homeV2/presenter/HomeV2Presenter.java index 368ea33b..b7b97da4 100644 --- a/app/src/main/java/com/gmeremit/online/gmeremittance_native/homeV2/presenter/HomeV2Presenter.java +++ b/app/src/main/java/com/gmeremit/online/gmeremittance_native/homeV2/presenter/HomeV2Presenter.java @@ -89,13 +89,7 @@ public class HomeV2Presenter extends BasePresenter implements HomeV2PresenterInt public void manuallyUpdateKYCForStatusToSubmitted() { String kycMessage = "Your registration request is in approval process. You will soon be able to use GME services."; String kycTitle = "Verification in Process"; -// String pennyTestTitle = "Verify your Bank Account"; -// String pennyTestMessage = "Please complete your primary bank account verification process."; -// view.showPennyTestViewIfRequired(true,pennyTestTitle,pennyTestMessage); view.showKYCVerifiedIfRequired(true, kycMessage, kycTitle, true, null); -// gateway.updateSubmittedKycInCache(true); -// gateway.updateVerifiedUserInCache(false); - } @Override @@ -105,8 +99,6 @@ public class HomeV2Presenter extends BasePresenter implements HomeV2PresenterInt String pennyTestTitle = "Continue the registration process"; String pennyTestMessage = "Please verify your primary bank account to complete the registration."; view.showKYCVerifiedIfRequired(false, "", "", true, () -> view.showPennyTestViewIfRequired(true, pennyTestTitle, pennyTestMessage)); -// view.showPennyTestViewIfRequired(true,pennyTestTitle,pennyTestMessage); - } @Override diff --git a/app/src/main/java/com/gmeremit/online/gmeremittance_native/sendmoneyV2/gateway/SendMoneyV2Gateway.java b/app/src/main/java/com/gmeremit/online/gmeremittance_native/sendmoneyV2/gateway/SendMoneyV2Gateway.java index df4cef07..2f463f28 100644 --- a/app/src/main/java/com/gmeremit/online/gmeremittance_native/sendmoneyV2/gateway/SendMoneyV2Gateway.java +++ b/app/src/main/java/com/gmeremit/online/gmeremittance_native/sendmoneyV2/gateway/SendMoneyV2Gateway.java @@ -35,8 +35,6 @@ public class SendMoneyV2Gateway extends PrivilegedGateway implements SendMoneyV2 String senderAmount, String recieverAmount, String paymentMethodId, String calculationPreference, String recipientCountryName, String recieverCountryId, String bankId,String payoutPartnerId,String userID,String paymentType) { - - JsonObject jsonObject=new JsonObject(); jsonObject.addProperty("sCountry",senderCountryId); jsonObject.addProperty("sCurrency",senderCurrency); @@ -53,7 +51,6 @@ public class SendMoneyV2Gateway extends PrivilegedGateway implements SendMoneyV2 jsonObject.addProperty("payOutPartner",payoutPartnerId); jsonObject.addProperty("userId",userID); - return HttpClientV2.getInstance().calculateForSendMoneyExchangeRateV2(auth,jsonObject); } diff --git a/app/src/main/java/com/gmeremit/online/gmeremittance_native/sendmoneyV2/model/SendMoneyAPIRequestBody.java b/app/src/main/java/com/gmeremit/online/gmeremittance_native/sendmoneyV2/model/SendMoneyAPIRequestBody.java index 74289c04..a10ef7ba 100644 --- a/app/src/main/java/com/gmeremit/online/gmeremittance_native/sendmoneyV2/model/SendMoneyAPIRequestBody.java +++ b/app/src/main/java/com/gmeremit/online/gmeremittance_native/sendmoneyV2/model/SendMoneyAPIRequestBody.java @@ -83,9 +83,7 @@ public class SendMoneyAPIRequestBody { @SerializedName("foreX_SESSION_ID") @Expose private String foreXSESSIONID; - @SerializedName("kftcLogId") - @Expose - private String kftcLogId; + @SerializedName("paymentType") @Expose private String paymentType; @@ -100,15 +98,9 @@ public class SendMoneyAPIRequestBody { private String receiverAccountNo; //KFTF Related Params - @SerializedName("kftcAccountNum") - @Expose - private String kftcAccNo; - @SerializedName("kftcAccessToken") - @Expose - private String kftcAccessToken; - @SerializedName("kftcFintechUseNo") + @SerializedName("KftcAccountId") @Expose - private String kftcFintechUseNo; + private String kftcAccountId; public String getUser() { @@ -319,12 +311,12 @@ public class SendMoneyAPIRequestBody { this.foreXSESSIONID = foreXSESSIONID; } - public String getKftcLogId() { - return kftcLogId; + public String getKftcAccountId() { + return kftcAccountId; } - public void setKftcLogId(String kftcLogId) { - this.kftcLogId = kftcLogId; + public void setKftcAccountId(String kftcAccountId) { + this.kftcAccountId = kftcAccountId; } public String getPaymentType() { @@ -359,33 +351,5 @@ public class SendMoneyAPIRequestBody { this.receiverAccountNo = receiverAccountNo; } - public String getKftcAccNo() { - return kftcAccNo; - } - - public void setKftcAccNo(String kftcAccNo) { - if(kftcAccNo==null) - kftcAccNo=""; - this.kftcAccNo = kftcAccNo; - } - - public String getKftcAccessToken() { - return kftcAccessToken; - } - - public void setKftcAccessToken(String kftcAccessToken) { - if(kftcAccessToken==null) - kftcAccessToken=""; - this.kftcAccessToken = kftcAccessToken; - } - public String getKftcFintechUseNo() { - return kftcFintechUseNo; - } - - public void setKftcFintechUseNo(String kftcFintechUseNo) { - if(kftcFintechUseNo==null) - kftcFintechUseNo=""; - this.kftcFintechUseNo = kftcFintechUseNo; - } } diff --git a/app/src/main/java/com/gmeremit/online/gmeremittance_native/sendmoneyV2/presenter/SendMoneyV2Presenter.java b/app/src/main/java/com/gmeremit/online/gmeremittance_native/sendmoneyV2/presenter/SendMoneyV2Presenter.java index b2b6e23b..3a1e6f76 100644 --- a/app/src/main/java/com/gmeremit/online/gmeremittance_native/sendmoneyV2/presenter/SendMoneyV2Presenter.java +++ b/app/src/main/java/com/gmeremit/online/gmeremittance_native/sendmoneyV2/presenter/SendMoneyV2Presenter.java @@ -245,9 +245,7 @@ public class SendMoneyV2Presenter extends BasePresenter implements SendMoneyV2Pr sendMoneyAPIRequestBody.setIsAgreed(Constants.TRUE_STRING); //KFTC Related Params - sendMoneyAPIRequestBody.setKftcAccNo(selectedPaymentType.getAccountNum()); - sendMoneyAPIRequestBody.setKftcAccessToken(selectedPaymentType.getAccessToken()); - sendMoneyAPIRequestBody.setKftcFintechUseNo(selectedPaymentType.getFintechUseNo()); + sendMoneyAPIRequestBody.setKftcAccountId(selectedPaymentType.getKftcAccountId()); sendMoneyAPIRequestBody.setTxnPassword(password); @@ -304,7 +302,6 @@ public class SendMoneyV2Presenter extends BasePresenter implements SendMoneyV2Pr @Override public Observable getForex(String recieveAmount, String senderAmount, boolean shouldCaulatedByRecipient, String recieverCurrency) { - String senderCountryId = gateway.getUserCountryId(); String senderCurrency = gateway.getUserPreferredCurrency(); String paymentMethodId = selectedPaymentModeData.getId();