Browse Source

send money receipt success card changed

pull/1/head
Amrit Giri 4 years ago
parent
commit
dc8df5963d
  1. 12
      GME Remit/Modules/RemittanceModules/OverseasModules/SendMoneyReceipt/User Interface/View/SendMoneyReceipt.storyboard
  2. 43
      GME Remit/Modules/RemittanceModules/OverseasModules/SendMoneyReceipt/User Interface/View/SendMoneyReceiptViewController.swift
  3. 10
      GME Remit/Modules/RemittanceModules/OverseasModules/SendMoneyReceipt/User Interface/Wireframe/SendMoneyReceiptWireframe.swift
  4. 4
      GME Remit/Modules/RemittanceModules/OverseasModules/SendMoneyVerification/User Interface/View/SendMoneyVerificationViewController.swift

12
GME Remit/Modules/RemittanceModules/OverseasModules/SendMoneyReceipt/User Interface/View/SendMoneyReceipt.storyboard

@ -638,12 +638,12 @@ notices to get JME Number for this transfer.</string>
<outlet property="addressLabel" destination="Gge-7S-SaJ" id="Sdx-aU-zgy"/>
<outlet property="addressTitleLabel" destination="YY3-KP-E09" id="1IZ-EK-KNV"/>
<outlet property="agentBankLabel" destination="98o-ui-Lmx" id="o9N-GP-4tV"/>
<outlet property="amountLabelSuccess" destination="8Ie-zf-9e4" id="eWl-DY-rGU"/>
<outlet property="amountLabelSuccess" destination="8Ie-zf-9e4" id="qg6-4M-9wa"/>
<outlet property="bankContainerView" destination="Kml-N2-XoF" id="SDx-tp-ict"/>
<outlet property="branchLabel" destination="gWt-Rx-LIV" id="vYW-fW-Zia"/>
<outlet property="branchTitleLabel" destination="tPz-r0-qXQ" id="EcH-Cb-x3N"/>
<outlet property="branchView" destination="FWa-U9-qgm" id="wGU-O8-UrG"/>
<outlet property="chargeLabelSuccess" destination="Jcm-Pf-Svb" id="fPB-1l-IAe"/>
<outlet property="chargeLabelSuccess" destination="Jcm-Pf-Svb" id="7Ee-F9-uEZ"/>
<outlet property="controlNoInfoLabel" destination="iff-4Y-StW" id="dw4-5f-sXl"/>
<outlet property="doneButton" destination="vlt-YJ-pwY" id="lW3-BS-VYD"/>
<outlet property="exRateTitleLabel" destination="pTI-kV-y2i" id="bSY-2B-msg"/>
@ -652,8 +652,8 @@ notices to get JME Number for this transfer.</string>
<outlet property="fullnameLabel" destination="oTd-t6-aTn" id="94U-1L-PeQ"/>
<outlet property="gmeControlNumberLabel" destination="NUp-Lj-dKf" id="BlJ-Y6-Yku"/>
<outlet property="infoView" destination="rub-fY-JfS" id="hk9-mU-JoW"/>
<outlet property="infoViewSuccess" destination="q9w-yT-RR1" id="VNd-hW-k0e"/>
<outlet property="makePaymentLabelSuccess" destination="ep6-Oj-aXg" id="L5F-Bg-lMg"/>
<outlet property="infoViewSuccess" destination="q9w-yT-RR1" id="dar-H7-7Rr"/>
<outlet property="makePaymentLabelSuccess" destination="ep6-Oj-aXg" id="zks-ED-Zpo"/>
<outlet property="mobileContainerView" destination="W4g-Xv-Fmk" id="ZFd-uB-7eQ"/>
<outlet property="mobileNoLabel" destination="SJg-la-JAc" id="XIo-nM-Lye"/>
<outlet property="mobileTitleLabel" destination="bTl-Ab-V1o" id="F8f-mH-7Gt"/>
@ -670,7 +670,7 @@ notices to get JME Number for this transfer.</string>
<outlet property="serviceTitleLabel" destination="52t-h8-txs" id="pxx-Vh-hcw"/>
<outlet property="shadowView" destination="fKI-eb-ZTN" id="JPH-j2-8dx"/>
<outlet property="tansactionDateTitleLabel" destination="0F1-wm-gWq" id="Ehr-9W-dU3"/>
<outlet property="toJmeLabelSuccess" destination="6W5-fI-bNq" id="WT3-MH-kaD"/>
<outlet property="toJmeLabelSuccess" destination="6W5-fI-bNq" id="51r-bC-DR9"/>
<outlet property="totalAmountHeaderLabel" destination="N0H-j3-s7Q" id="ATn-2o-Ouj"/>
<outlet property="totalAmountLabel" destination="63I-2O-WVX" id="hpc-ve-FfO"/>
<outlet property="totalPayoutAmountContainerView" destination="fMD-Tq-Dwt" id="79S-Be-nIl"/>
@ -681,7 +681,7 @@ notices to get JME Number for this transfer.</string>
<outlet property="transactionReportButtonStackView" destination="PMG-MW-2Jh" id="ORN-l5-YsL"/>
<outlet property="transferFeeLabel" destination="5Mm-Rr-tjC" id="rnt-2u-HXK"/>
<outlet property="transferSuccessfullTitleLabel" destination="JkE-DM-feU" id="qBu-N3-Xdg"/>
<outlet property="weReceivedLabelSuccess" destination="jCr-3b-QWa" id="vWt-xA-Ipz"/>
<outlet property="weReceivedLabelSuccess" destination="jCr-3b-QWa" id="PNR-Ew-VBx"/>
</connections>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="b3B-PU-UlH" userLabel="First Responder" sceneMemberID="firstResponder"/>

43
GME Remit/Modules/RemittanceModules/OverseasModules/SendMoneyReceipt/User Interface/View/SendMoneyReceiptViewController.swift

@ -18,6 +18,12 @@ enum ReceiptType {
case overseas
}
enum ReceiptParent {
case sendMoney
case notice
case report
}
class SendMoneyReceiptViewController: UIViewController {
// MARK: IBOutlets
@ -38,6 +44,9 @@ class SendMoneyReceiptViewController: UIViewController {
let payoutAmountText = "total_payout_amount_text".localized()
let gmeControlNumberText = "jme_control_no_text".localized()
let doneText = "done_text".localized()
let headerSuccess = "send_money_success_header_text".localized()
let bodySuccess = "send_money_success_body_text".localized()
let footerSuccess = "send_money_success_footer_text".localized()
}
@IBOutlet weak var fullnameLabel: UILabel!
@ -45,6 +54,17 @@ class SendMoneyReceiptViewController: UIViewController {
@IBOutlet weak var controlNoInfoLabel: UILabel!
@IBOutlet weak var transactionDateLabel: UILabel!
@IBOutlet weak var infoView: UIView!
@IBOutlet weak var infoViewSuccess: UIView!
@IBOutlet weak var weReceivedLabelSuccess: UILabel!
@IBOutlet weak var amountLabelSuccess: UILabel!
@IBOutlet weak var makePaymentLabelSuccess: UILabel!
@IBOutlet weak var chargeLabelSuccess: UILabel!
@IBOutlet weak var toJmeLabelSuccess: UILabel!
@IBOutlet weak var shadowView: UIView!
@IBOutlet weak var exchangeRateLabel: UILabel!
@IBOutlet weak var relationLabel: UILabel!
@ -97,7 +117,7 @@ class SendMoneyReceiptViewController: UIViewController {
var presenter: SendMoneyReceiptModuleInterface?
weak var hudDelegate: HUDStatusDelegate?
var shouldShowCancelAmmendButton = false
var isFromTransactionHistory = false
var receiptParent: ReceiptParent = .sendMoney
var controlNo: String?
var transactionId: String?
var type: MailBoxType?
@ -124,6 +144,9 @@ class SendMoneyReceiptViewController: UIViewController {
self.setupNormalNavigation()
self.setupBackButton()
self.infoView.isHidden = self.receiptParent == .sendMoney
self.infoViewSuccess.isHidden = self.receiptParent != .sendMoney
switch receiptType {
case .overseas:
transactionDateContainerView.isHidden = false
@ -148,15 +171,11 @@ class SendMoneyReceiptViewController: UIViewController {
override func viewDidAppear(_ animated: Bool) {
super.viewDidAppear(animated)
// if !isFromTransactionHistory {
// StoreReviewHelper.shared.checkAndAskForReview()
// }
}
// MARK: IBActions
@IBAction func done(_ sender: UIButton) {
if (isFromTransactionHistory) {
if self.receiptParent == .report {
self.navigationController?.popViewController(animated: true)
} else {
self.navigationController?.popToRootViewController(animated: true)
@ -184,12 +203,17 @@ class SendMoneyReceiptViewController: UIViewController {
// all setup should be done here
setupBackButton()
configureLanguage()
infoViewSuccess.layer.cornerRadius = 20
infoView.layer.cornerRadius = 20
requestToCancelButton.layer.cornerRadius = 20
requestToChangeButton.layer.cornerRadius = 20
}
func configureLanguage() {
self.weReceivedLabelSuccess.text = StringConstants().headerSuccess
self.makePaymentLabelSuccess.text = StringConstants().headerSuccess
self.toJmeLabelSuccess.text = StringConstants().footerSuccess
self.transferSuccessfullTitleLabel.text = StringConstants().transferSuccessText
self.tansactionDateTitleLabel.text = StringConstants().transactionDateText
self.recieverTitleLabel.text = StringConstants().recieverText
@ -264,7 +288,11 @@ class SendMoneyReceiptViewController: UIViewController {
self.accountNoView.isHidden = accountNo == ""
self.accountNoLabel.text = self.reciept?.accountNo
self.relationLabel.text = self.reciept?.collAmount?.decimalToCurrency(as: .krw)
self.transferFeeLabel.text = self.reciept?.serviceCharge?.decimalToCurrency(as: .krw)
let charge = self.reciept?.serviceCharge?.decimalToCurrency(as: .krw)
self.transferFeeLabel.text = charge
self.chargeLabelSuccess.text = charge
self.exchangeRateLabel.text = self.reciept?.exRate
let controlNo = self.reciept?.controNo ?? ""
@ -276,6 +304,7 @@ class SendMoneyReceiptViewController: UIViewController {
self.totalAmountLabel.text = totalAmount
self.totalAmountHeaderLabel.text = totalAmount
self.amountLabelSuccess.text = totalAmount
}
}

10
GME Remit/Modules/RemittanceModules/OverseasModules/SendMoneyReceipt/User Interface/Wireframe/SendMoneyReceiptWireframe.swift

@ -12,7 +12,7 @@ class SendMoneyReceiptWireframe {
weak var view: UIViewController!
var transactionId: String?
var controlNo: String?
var isFromTransactionReport = false
var receiptParent: ReceiptParent = .sendMoney
var shouldShowCancelAmmendButton = false
let mailboxwireFrame = MessageComposeWireframe()
@ -31,7 +31,7 @@ extension SendMoneyReceiptWireframe: SendMoneyReceiptWireframeInput {
viewController.controlNo = self.controlNo // todo: refractor later
viewController.transactionId = self.transactionId // todo: refractor later
viewController.shouldShowCancelAmmendButton = self.shouldShowCancelAmmendButton
viewController.isFromTransactionHistory = self.isFromTransactionReport
viewController.receiptParent = self.receiptParent
viewController.receiptType = receiptType
viewController.presenter = presenter
interactor.output = presenter
@ -49,7 +49,7 @@ extension SendMoneyReceiptWireframe: SendMoneyReceiptWireframeInput {
source: UINavigationController
) {
receiptType = type
isFromTransactionReport = false
receiptParent = .sendMoney
self.transactionId = transactionId
self.pushMainView(in: source)
@ -63,7 +63,7 @@ extension SendMoneyReceiptWireframe: SendMoneyReceiptWireframeInput {
source: UINavigationController
) {
receiptType = type
isFromTransactionReport = true
receiptParent = .report
self.transactionId = transactionId
self.shouldShowCancelAmmendButton = shouldShowCancelAmmendButton
@ -77,7 +77,7 @@ extension SendMoneyReceiptWireframe: SendMoneyReceiptWireframeInput {
shouldShowCancelAmmendButton: Bool,
source: UINavigationController
) {
isFromTransactionReport = false
receiptParent = .notice
self.transactionId = transactionId
self.shouldShowCancelAmmendButton = shouldShowCancelAmmendButton
self.controlNo = controlNo

4
GME Remit/Modules/RemittanceModules/OverseasModules/SendMoneyVerification/User Interface/View/SendMoneyVerificationViewController.swift

@ -260,11 +260,7 @@ extension SendMoneyVerificationViewController: SendMoneyVerificationViewInterfac
}
func showLoading() {
if hudDelegate != nil {
self.hudDelegate?.showLoading()
} else {
self.showProgressHud()
}
}

Loading…
Cancel
Save