Browse Source

add GMEStyleAlertView

pull/1/head
InKwon James Kim 5 years ago
parent
commit
444d4d184e
  1. 16
      GME Remit.xcodeproj/project.pbxproj
  2. BIN
      GMERemittance/.DS_Store
  3. 4
      GMERemittance/AppDelegate.swift
  4. 78
      GMERemittance/Extension/UIViewControllerExtension.swift
  5. 20
      GMERemittance/Extension/UIViewExtension.swift
  6. 4
      GMERemittance/Library/WebLinks/WebLinksViewController.swift
  7. 2
      GMERemittance/Library/WebLinks/WkWebView/WkWebViewController.swift
  8. 4
      GMERemittance/Module/AutoDebitModules/AddAccount/User Interface/View/AddAccountViewController.swift
  9. 4
      GMERemittance/Module/AutoDebitModules/AutoDebit/User Interface/View/AutoDebitViewController.swift
  10. 2
      GMERemittance/Module/BiometricAuthModules/BiometricAuthenticationNotification/User Interface/View/BiometricAuthenticationNotificationViewController.swift
  11. 6
      GMERemittance/Module/ExchangeRates/User Interface/View/ExchangeRatesViewController.swift
  12. 2
      GMERemittance/Module/ForgotPassword/User Interface/View/ForgotPasswordViewController.swift
  13. 4
      GMERemittance/Module/Home/User Interface/View/HomeViewController.swift
  14. 2
      GMERemittance/Module/Login/User Interface/View/LoginViewController.swift
  15. 4
      GMERemittance/Module/Profile/ProfileChangePasswordViewController.swift
  16. 2
      GMERemittance/Module/RegisterModules/KYC/Kyc/User Interface/View/KycViewController.swift
  17. 2
      GMERemittance/Module/RegisterModules/KYC/kycForm1/User Interface/View/kycForm1ViewController.swift
  18. 2
      GMERemittance/Module/RegisterModules/KYC/kycForm2/User Interface/View/kycForm2ViewController.swift
  19. 4
      GMERemittance/Module/RegisterModules/KYC/kycForm3/User Interface/View/kycForm3ViewController.swift
  20. 2
      GMERemittance/Module/RegisterModules/PennyTest/User Interface/View/PennyTestViewController.swift
  21. 8
      GMERemittance/Module/RegisterModules/PennyTestSubmit/User Interface/View/PennyTestSubmitViewController.swift
  22. 2
      GMERemittance/Module/RegisterModules/Register/User Interface/View/RegisterViewController.swift
  23. 2
      GMERemittance/Module/RewardModules/OrderHistory/User Interface/View/OrderHistoryViewController.swift
  24. 6
      GMERemittance/Module/RewardModules/Redeem/User Interface/View/RedeemViewController.swift
  25. 2
      GMERemittance/Module/SendMoneyModules/Recipient/AddReciepient/User Interface/View/AddReciepientViewController.swift
  26. 2
      GMERemittance/Module/SendMoneyModules/Recipient/EditReciepient/User Interface/View/EditReciepientViewController.swift
  27. 4
      GMERemittance/Module/SendMoneyModules/Recipient/RecipientListViewController.swift
  28. 2
      GMERemittance/Module/SendMoneyModules/Resend/User Interface/View/ResendViewController.swift
  29. 4
      GMERemittance/Module/SendMoneyModules/ResendExchange/User Interface/View/ResendExchangeViewController.swift
  30. 2
      GMERemittance/Module/SendMoneyModules/SelectCoupon/User Interface/View/SelectCouponViewController.swift
  31. 2
      GMERemittance/Module/SendMoneyModules/SendMoneyCode/User Interface/View/SendMoneyCodeViewController.swift
  32. 2
      GMERemittance/Module/SendMoneyModules/SendMoneyExchangeRate/User Interface/View/SendMoneyExchangeRateViewController.swift
  33. 2
      GMERemittance/Module/SendMoneyModules/SendMoneyPaymentMode/User Interface/View/BankBranchPicker/BankBranchPickerViewController.swift
  34. 2
      GMERemittance/Module/SendMoneyModules/SendMoneyPaymentMode/User Interface/View/SendMoneyPaymentModeViewController.swift
  35. 2
      GMERemittance/Module/SendMoneyModules/SendMoneyReceipt/User Interface/View/SendMoneyReceiptViewController.swift
  36. 6
      GMERemittance/Module/SendMoneyModules/SendMoneyVerification/User Interface/View/SendMoneyVerificationViewController.swift
  37. 2
      GMERemittance/Module/SideMenu/Auto refund/AutoRefundsViewController.swift
  38. 3
      GMERemittance/Module/SideMenu/SettingViewController.swift
  39. 2
      GMERemittance/Module/SplashScreen/User Interface/View/SplashScreenViewController.swift
  40. 2
      GMERemittance/Module/TransactionHistoryModules/MessageCompose/User Interface/View/MessageComposeViewController.swift
  41. 2
      GMERemittance/Module/WalletStatement/User Interface/View/WalletStatementViewController.swift
  42. 6
      GMERemittance/Utility/ConfirmAlert/ConfirmViewController.swift
  43. 16
      GMERemittance/Utility/ConfirmAlert/ConfirmViewController.xib
  44. 91
      GMERemittance/Utility/GMEAlert/GMEAlertViewController.swift
  45. 141
      GMERemittance/Utility/GMEAlert/GMEAlertViewController.xib
  46. 2
      GMERemittance/Utility/HotLine/User Interface/View/HotLineViewController.swift

16
GME Remit.xcodeproj/project.pbxproj

@ -196,6 +196,8 @@
736A8C482277EB2A00337A50 /* BiometricAuthenticationNotification.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 736A8C3D2277EB2900337A50 /* BiometricAuthenticationNotification.storyboard */; };
736A8C492277EB2A00337A50 /* BiometricAuthenticationNotificationViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 736A8C3E2277EB2900337A50 /* BiometricAuthenticationNotificationViewController.swift */; };
736A8C4A2277EB2A00337A50 /* BiometricAuthenticationNotificationViewInterface.swift in Sources */ = {isa = PBXBuildFile; fileRef = 736A8C3F2277EB2900337A50 /* BiometricAuthenticationNotificationViewInterface.swift */; };
7384B28222CB377300DD04D9 /* GMEAlertViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7384B28022CB377300DD04D9 /* GMEAlertViewController.swift */; };
7384B28322CB377300DD04D9 /* GMEAlertViewController.xib in Resources */ = {isa = PBXBuildFile; fileRef = 7384B28122CB377300DD04D9 /* GMEAlertViewController.xib */; };
7389600A22C2F208003FEA90 /* TablePresenterModuleInterface.swift in Sources */ = {isa = PBXBuildFile; fileRef = 73895FF722C2F208003FEA90 /* TablePresenterModuleInterface.swift */; };
7389600B22C2F208003FEA90 /* TablePresenterServiceType.swift in Sources */ = {isa = PBXBuildFile; fileRef = 73895FFB22C2F208003FEA90 /* TablePresenterServiceType.swift */; };
7389600C22C2F208003FEA90 /* TablePresenterService.swift in Sources */ = {isa = PBXBuildFile; fileRef = 73895FFC22C2F208003FEA90 /* TablePresenterService.swift */; };
@ -2355,6 +2357,8 @@
736A8C3D2277EB2900337A50 /* BiometricAuthenticationNotification.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; path = BiometricAuthenticationNotification.storyboard; sourceTree = "<group>"; };
736A8C3E2277EB2900337A50 /* BiometricAuthenticationNotificationViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = BiometricAuthenticationNotificationViewController.swift; sourceTree = "<group>"; };
736A8C3F2277EB2900337A50 /* BiometricAuthenticationNotificationViewInterface.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = BiometricAuthenticationNotificationViewInterface.swift; sourceTree = "<group>"; };
7384B28022CB377300DD04D9 /* GMEAlertViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = GMEAlertViewController.swift; sourceTree = "<group>"; };
7384B28122CB377300DD04D9 /* GMEAlertViewController.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = GMEAlertViewController.xib; sourceTree = "<group>"; };
73895FF722C2F208003FEA90 /* TablePresenterModuleInterface.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TablePresenterModuleInterface.swift; sourceTree = "<group>"; };
73895FFB22C2F208003FEA90 /* TablePresenterServiceType.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TablePresenterServiceType.swift; sourceTree = "<group>"; };
73895FFC22C2F208003FEA90 /* TablePresenterService.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TablePresenterService.swift; sourceTree = "<group>"; };
@ -5601,6 +5605,15 @@
path = View;
sourceTree = "<group>";
};
7384B27F22CB375400DD04D9 /* GMEAlert */ = {
isa = PBXGroup;
children = (
7384B28022CB377300DD04D9 /* GMEAlertViewController.swift */,
7384B28122CB377300DD04D9 /* GMEAlertViewController.xib */,
);
path = GMEAlert;
sourceTree = "<group>";
};
73895FF522C2F208003FEA90 /* TablePresenter */ = {
isa = PBXGroup;
children = (
@ -10346,6 +10359,7 @@
D96A4FBA2146075800CFD507 /* Utility */ = {
isa = PBXGroup;
children = (
7384B27F22CB375400DD04D9 /* GMEAlert */,
7312F6452281486200172BDD /* ConfirmAlert */,
73895FF522C2F208003FEA90 /* TablePresenter */,
73071AAF2296CF9B008840FD /* HotLine */,
@ -11887,6 +11901,7 @@
D93C276722000D630079BF03 /* iPhone_transkey_alnum_cap_1.png in Resources */,
D93C2C4322000D660079BF03 /* transkey_pattern_dot.png in Resources */,
D93C269022000D630079BF03 /* iPhone_transkey_landscape_alnum_sym_20.png in Resources */,
7384B28322CB377300DD04D9 /* GMEAlertViewController.xib in Resources */,
D93C2C1222000D660079BF03 /* pt-icon72.png in Resources */,
D93C2C0922000D660079BF03 /* pt-icon49.png in Resources */,
D93C2BBB22000D660079BF03 /* transkey_input_sym_13.png in Resources */,
@ -13515,6 +13530,7 @@
730D787F227A94E1007E517E /* RedeemService.swift in Sources */,
73BCCDCF228993040057B161 /* RewardGroupModuleInterface.swift in Sources */,
BE74AFBE227C8FF200F05CE7 /* AddAccountInteractorIO.swift in Sources */,
7384B28222CB377300DD04D9 /* GMEAlertViewController.swift in Sources */,
BE74AFC4227C8FF200F05CE7 /* AddAccountViewInterface.swift in Sources */,
D96BD11C216479E200DFE7D8 /* WalletStatementWireframeInput.swift in Sources */,
73071AC42296CF9B008840FD /* HotLineModuleInterface.swift in Sources */,

BIN
GMERemittance/.DS_Store

4
GMERemittance/AppDelegate.swift

@ -187,7 +187,7 @@ extension AppDelegate {
}) { (error) in
self.window?.rootViewController?.hideProgressHud()
self.window?.rootViewController?.alert(message: error.localizedDescription, title: "Warning"){
self.window?.rootViewController?.alert(type: .error, message: error.localizedDescription, title: "Warning"){
// if failed login, remove all in keychain, change logout status and then go splash screen
KeyChain.shared.removeAll()
self.goSplashScreen()
@ -284,7 +284,7 @@ extension AppDelegate: BiometricAuthenticationViewControllerDelegate{
secureKeypad.present(animated: true)
case .notBeConfigured, .biometryNotEnrolled:
viewController.alert(message: error.message)
viewController.alert(type: .error, message: error.message)
default:
break

78
GMERemittance/Extension/UIViewControllerExtension.swift

@ -48,7 +48,8 @@ extension UIViewController {
func alert(
type: AlertType = .error,
message: String?,
title: String? = "alert_text".localized(),
title: String = "alert_text".localized(),
rightButtomTitle: String = "ok_text".localized(),
okAction: (()->())? = nil
) {
let alertController = getAlert(
@ -57,16 +58,27 @@ extension UIViewController {
title: title
)
alertController.addAction(title: "ok_text".localized(), handler: okAction)
self.present(alertController, animated: true, completion: nil)
gmeAlert(
type: type,
title: title,
message: message,
rightButtonTitle: rightButtomTitle,
leftButtonTitle: nil,
rightButtonAction: okAction,
leftButtonAction: nil
)
// self.present(alertController, animated: true, completion: nil)
}
func alertWithOkCancel(
type: AlertType = .error,
type: AlertType = .normal,
message: String?,
title: String? = "Error",
okTitle: String? = "ok_text".localized(),
title: String = "Error",
okTitle: String = "ok_text".localized(),
style: UIAlertControllerStyle? = .alert,
cancelTitle: String? = "cancel_text".localized(),
cancelTitle: String = "cancel_text".localized(),
OkStyle: UIAlertActionStyle = .default,
cancelStyle: UIAlertActionStyle = .default,
okAction: (()->())? = nil,
@ -93,9 +105,19 @@ extension UIViewController {
alertController.addAction(cancelAlertAction)
alertController.addAction(okAlertAction)
// noAction.setValue(UIColor.black, forKey: "titleTextColor")
gmeAlert(
type: type,
title: title,
message: message,
rightButtonTitle: okTitle,
leftButtonTitle: cancelTitle,
rightButtonAction: okAction,
leftButtonAction: cancelAction
)
// noAction.setValue(UIColor.black, forKey: "titleTextColor")
self.present(alertController, animated: true, completion: nil)
// self.present(alertController, animated: true, completion: nil)
}
func alertWithOk(
@ -153,6 +175,42 @@ extension UIViewController {
}
self.present(alert, animated: true, completion: nil)
}
func gmeAlert(
type: AlertType = .normal,
title: String = "Alert",
message: String? = nil,
rightButtonTitle: String = "Ok",
leftButtonTitle: String? = nil,
rightButtonAction: (() -> Void)? = nil,
leftButtonAction: (() -> Void)? = nil
) {
let titleText: String
let customerWalletNumber = UserDefaults.standard.string(forKey: UserKeys.walletNumber) ?? ""
switch type {
case .error:
if customerWalletNumber != "" {
titleText = "\(title) (\(customerWalletNumber))"
} else {
titleText = title
}
case .normal:
titleText = title
}
let gmeAlertVC = GMEAlertViewController(
title: titleText,
message: message,
rightButtonTitle: rightButtonTitle,
leftButtonTitle: leftButtonTitle,
rightButtonAction: rightButtonAction,
leftButtonAction: leftButtonAction
)
present(gmeAlertVC, animated: false, completion: nil)
}
}
extension UIAlertController {
@ -215,7 +273,7 @@ extension UIViewController {
[NSAttributedStringKey.font: font]
}
// UINavigationBar.appearance().titleTextAttributes =
// [NSAttributedStringKey.font: font]
// UINavigationBar.appearance().titleTextAttributes =
// [NSAttributedStringKey.font: font]
}
}

20
GMERemittance/Extension/UIViewExtension.swift

@ -77,4 +77,24 @@ extension UIView {
animator.startAnimation()
}
func popUpBouncy(duration: Double = 0.1) {
alpha = 0.0
let transform = CGAffineTransform(scaleX: 0.8, y: 0.8)
self.transform = transform
UIView.animate(
withDuration:duration,
delay: duration,
usingSpringWithDamping: 0.2,
initialSpringVelocity: 10,
animations: {
self.alpha = 1.0
let transform = CGAffineTransform(scaleX: 1, y: 1)
self.transform = transform
}
)
}
}

4
GMERemittance/Library/WebLinks/WebLinksViewController.swift

@ -67,7 +67,7 @@ class WebLinksViewController: UIViewController {
webView?.loadRequest(request)
}
}else {
self.alert(message: "no_internet_connection_error".localized(), title: "")
self.alert(type: .error, message: "no_internet_connection_error".localized(), title: "")
}
}
}
@ -85,7 +85,7 @@ extension WebLinksViewController: UIWebViewDelegate {
func webView(_ webView: UIWebView, didFailLoadWithError error: Error) {
self.activityIndicator?.stopAnimating()
self.alert(message: error.localizedDescription)
self.alert(type: .error, message: error.localizedDescription)
}
}

2
GMERemittance/Library/WebLinks/WkWebView/WkWebViewController.swift

@ -94,7 +94,7 @@ extension WkWebViewController: WKScriptMessageHandler {
func userContentController(_ userContentController: WKUserContentController, didReceive message: WKScriptMessage) {
print(message.name)
if let body = message.body as? String {
self.alert(message: body, title: nil) {
self.alert(message: body) {
self.dismiss(animated: true, completion: nil)
}
}

4
GMERemittance/Module/AutoDebitModules/AddAccount/User Interface/View/AddAccountViewController.swift

@ -180,7 +180,7 @@ extension AddAccountViewController: AddAccountViewInterface {
}
func failureSetModel(error: Error) {
alert(message: error.localizedDescription, title: "Warning"){[weak self] in
alert(type: .error, message: error.localizedDescription, title: "Warning"){[weak self] in
guard let `self` = self else {return}
self.dismiss(animated: true, completion: nil)
}
@ -204,7 +204,7 @@ extension AddAccountViewController: AddAccountViewInterface {
}
func failure(error: Error) {
alert(message: error.localizedDescription, title: "Warning", okAction: nil)
alert(type: .error, message: error.localizedDescription, title: "Warning", okAction: nil)
}
func startLoading(){

4
GMERemittance/Module/AutoDebitModules/AutoDebit/User Interface/View/AutoDebitViewController.swift

@ -229,7 +229,7 @@ extension AutoDebitViewController: UITableViewDelegate {
extension AutoDebitViewController: AutoDebitViewInterface {
func didFailRefreshToken(with error: Error) {
alert(message: error.localizedDescription)
alert(type: .error, message: error.localizedDescription)
}
func didDeleteAccount() {
@ -238,6 +238,7 @@ extension AutoDebitViewController: AutoDebitViewInterface {
func didFailDeleteAccount(with error: Error) {
alert(
type: .error,
message: error.localizedDescription,
title: "Failed Delete",
okAction: nil
@ -258,6 +259,7 @@ extension AutoDebitViewController: AutoDebitViewInterface {
func didFailSetModel(with error: Error) {
alert(
type: .error,
message: error.localizedDescription,
title: "Failed Fetch KFTC Account List",
okAction: nil

2
GMERemittance/Module/BiometricAuthModules/BiometricAuthenticationNotification/User Interface/View/BiometricAuthenticationNotificationViewController.swift

@ -33,7 +33,7 @@ class BiometricAuthenticationNotificationViewController: UIViewController {
@IBAction func touchUseBiometricAuth(_ sender: UIButton) {
BiometricAuthenticationWireframe().showBiometricAuthentication() { error in
if error != nil {
self.alert(message: error!.message)
self.alert(type: .error, message: error!.message)
} else {
KeyChain.shared.save(data: "1", key: .biometricAuth)
self.dismiss(animated: true, completion: nil)

6
GMERemittance/Module/ExchangeRates/User Interface/View/ExchangeRatesViewController.swift

@ -206,7 +206,7 @@ class ExchangeRatesViewController: UIViewController {
}) { (error) in
self.hideProgressHud()
self.view.endEditing(true)
self.alert(message: error.localizedDescription)
self.alert(type: .error, message: error.localizedDescription)
}
// call api with these params
@ -412,7 +412,7 @@ class ExchangeRatesViewController: UIViewController {
}) { (error) in
self.hideProgressHud()
self.view.endEditing(true)
self.alert(message: error.localizedDescription)
self.alert(type: .error, message: error.localizedDescription)
}
}
@ -490,7 +490,7 @@ class ExchangeRatesViewController: UIViewController {
func show(error: String) {
self.view.endEditing(true)
self.alert(message: error)
self.alert(type: .error, message: error)
}
func showLoading() {

2
GMERemittance/Module/ForgotPassword/User Interface/View/ForgotPasswordViewController.swift

@ -110,6 +110,6 @@ extension ForgotPasswordViewController: ForgotPasswordViewInterface {
}
func show(error: String) {
self.alert(message: error)
self.alert(type: .error, message: error)
}
}

4
GMERemittance/Module/Home/User Interface/View/HomeViewController.swift

@ -609,11 +609,11 @@ extension HomeViewController: HomeViewInterface {
}
func show(error: String) {
self.alert(message: error)
self.alert(type: .error, message: error)
}
func show(panicError: String) {
self.alert(message: panicError, title: "Warning") {
self.alert(type: .error, message: panicError, title: "Warning") {
self.presenter?.logout()
}
}

2
GMERemittance/Module/Login/User Interface/View/LoginViewController.swift

@ -290,7 +290,7 @@ class LoginViewController: UIViewController {
// MARK: LoginViewInterface
extension LoginViewController: LoginViewInterface {
func show(error: String) {
self.alert(message: error)
self.alert(type: .error, message: error)
}
func showLoading() {

4
GMERemittance/Module/Profile/ProfileChangePasswordViewController.swift

@ -139,7 +139,7 @@ class ProfileChangePasswordViewController: UIViewController {
self.updatePassword(param: param)
}else {
let message = result.error
self.alert(message: message.localizedDescription)
self.alert(type: .error, message: message.localizedDescription)
}
}
@ -150,7 +150,7 @@ class ProfileChangePasswordViewController: UIViewController {
self.navigationController?.popViewController(animated: true)
})
}) { (error) in
self.alert(message: error.localizedDescription)
self.alert(type: .error, message: error.localizedDescription)
}
}

2
GMERemittance/Module/RegisterModules/KYC/Kyc/User Interface/View/KycViewController.swift

@ -188,7 +188,7 @@ extension KycViewController: KycViewInterface {
}
func show(error: String) {
self.alert(message: error)
self.alert(type: .error, message: error)
}
func showLoading() {

2
GMERemittance/Module/RegisterModules/KYC/kycForm1/User Interface/View/kycForm1ViewController.swift

@ -408,7 +408,7 @@ extension KycForm1ViewController: KycForm1ViewInterface {
}
func show(error: String) {
self.alert(message: error)
self.alert(type: .error, message: error)
}
func showLoading() {

2
GMERemittance/Module/RegisterModules/KYC/kycForm2/User Interface/View/kycForm2ViewController.swift

@ -440,7 +440,7 @@ extension KycForm2ViewController: KycForm2ViewInterface {
func show(error: String) {
self.alert(message: error)
self.alert(type: .error, message: error)
}
func showLoading() {

4
GMERemittance/Module/RegisterModules/KYC/kycForm3/User Interface/View/kycForm3ViewController.swift

@ -253,7 +253,7 @@ extension KycForm3ViewController: MultiMediaManagerDelegate {
}
func didFinishPickingWithError(error: String) {
self.alert(message: error)
self.alert(type: .error, message: error)
}
func hideBorder(view: UIView) {
@ -298,7 +298,7 @@ extension KycForm3ViewController: ImageCropperDelegate {
}
}
func didFailedCropWith(error: Error) {
self.alert(message: error.localizedDescription)
self.alert(type: .error, message: error.localizedDescription)
}
}

2
GMERemittance/Module/RegisterModules/PennyTest/User Interface/View/PennyTestViewController.swift

@ -107,7 +107,7 @@ class PennyTestViewController: UIViewController {
}
}) { (error) in
self.hideLoading()
self.alert(message: error.localizedDescription)
self.alert(type: .error, message: error.localizedDescription)
}
}

8
GMERemittance/Module/RegisterModules/PennyTestSubmit/User Interface/View/PennyTestSubmitViewController.swift

@ -123,7 +123,7 @@ class PennyTestSubmitViewController: UIViewController {
}) { (error) in
self.updatePennyTestRequestStatus()
self.hideLoading()
self.alert(message: error.localizedDescription)
self.alert(type: .error, message: error.localizedDescription)
}
}
@ -140,7 +140,7 @@ class PennyTestSubmitViewController: UIViewController {
}) { (error) in
self.updatePennyTestRequestStatus()
self.hideLoading()
self.alert(message: error.localizedDescription)
self.alert(type: .error, message: error.localizedDescription)
}
}
@ -161,7 +161,7 @@ class PennyTestSubmitViewController: UIViewController {
let customerId = Utility.getMyId()
let certNumber = self.verificationCodeTextField.text!.removeSpacesTrailingPreceding()
if certNumber.isEmpty || certNumber.count != 4 {
self.alert(message: "valid_verification_code_error".localized())
self.alert(type: .error, message: "valid_verification_code_error".localized())
return
}
@ -203,7 +203,7 @@ class PennyTestSubmitViewController: UIViewController {
}
)
}) { (error) in
self.alert(message: error.localizedDescription)
self.alert(type: .error, message: error.localizedDescription)
}
}

2
GMERemittance/Module/RegisterModules/Register/User Interface/View/RegisterViewController.swift

@ -213,7 +213,7 @@ extension RegisterViewController: RegisterViewInterface {
}
func show(error: String) {
self.alert(message: error)
self.alert(type: .error, message: error)
}
func show(message: String) {

2
GMERemittance/Module/RewardModules/OrderHistory/User Interface/View/OrderHistoryViewController.swift

@ -122,7 +122,7 @@ extension OrderHistoryViewController: OrderHistoryViewInterface {
}
func didFailFetchOrderHistory(with error: Error) {
alert(message: error.localizedDescription)
alert(type: .error, message: error.localizedDescription)
}
func stardLoading() {

6
GMERemittance/Module/RewardModules/Redeem/User Interface/View/RedeemViewController.swift

@ -270,7 +270,7 @@ extension RedeemViewController: RedeemViewInterface {
}
func setBranchesError(with error: Error){
alert(message: error.localizedDescription)
alert(type: .error, message: error.localizedDescription)
}
func submitSuccess(){
@ -286,7 +286,7 @@ extension RedeemViewController: RedeemViewInterface {
}
func submitFailure(with error: Error) {
alert(message: error.localizedDescription)
alert(type: .error, message: error.localizedDescription)
}
func startLoading(){
@ -298,7 +298,7 @@ extension RedeemViewController: RedeemViewInterface {
}
func failureRefreshRewardPoint(with error: Error) {
alert(message: error.localizedDescription, title: "Alert"){[weak self] in
alert(type: .error, message: error.localizedDescription, title: "Alert"){[weak self] in
guard let `self` = self else { return }
self.presenter?.goRewardHome()
}

2
GMERemittance/Module/SendMoneyModules/Recipient/AddReciepient/User Interface/View/AddReciepientViewController.swift

@ -302,7 +302,7 @@ class AddReciepientViewController: UIViewController {
}
internal func show(error: String) {
self.alert(message: error)
self.alert(type: .error, message: error)
}
}

2
GMERemittance/Module/SendMoneyModules/Recipient/EditReciepient/User Interface/View/EditReciepientViewController.swift

@ -327,7 +327,7 @@ class EditReciepientViewController: UIViewController {
}
func show(error: String) {
self.alert(message: error)
self.alert(type: .error, message: error)
}

4
GMERemittance/Module/SendMoneyModules/Recipient/RecipientListViewController.swift

@ -180,7 +180,7 @@ extension RecipientListViewController: UITableViewDelegate,UITableViewDataSource
}
}, failure: { (error) in
self.alert(message: error.localizedDescription)
self.alert(type: .error, message: error.localizedDescription)
self.hideProgressHud()
})
}
@ -211,7 +211,7 @@ extension RecipientListViewController: UITableViewDelegate,UITableViewDataSource
self.reciepients = reciepients?.reciepients
}) { (error) in
self.hideProgressHud()
self.alert(message: error.localizedDescription)
self.alert(type: .error, message: error.localizedDescription)
}
}

2
GMERemittance/Module/SendMoneyModules/Resend/User Interface/View/ResendViewController.swift

@ -210,7 +210,7 @@ extension ResendViewController: ResendViewInterface {
}
func show(error: String) {
self.alert(message: error)
self.alert(type: .error, message: error)
}
func show(models: [ResendTransactionModel]) {

4
GMERemittance/Module/SendMoneyModules/ResendExchange/User Interface/View/ResendExchangeViewController.swift

@ -358,11 +358,11 @@ extension ResendExchangeViewController: ResendExchangeViewInterface {
}
func showExchangeRate(error: String) {
self.alert(message: error)
self.alert(type: .error, message: error)
}
func show(error: String) {
self.alert(message: error, title: nil) {
self.alert(type: .error, message: error) {
self.navigationController?.popViewController(animated: true)
}
}

2
GMERemittance/Module/SendMoneyModules/SelectCoupon/User Interface/View/SelectCouponViewController.swift

@ -88,7 +88,7 @@ extension SelectCouponViewController: SelectCouponViewInterface {
}
func error(with error: Error) {
alert(message: error.localizedDescription)
alert(type: .error, message: error.localizedDescription)
}
func startLoading() {

2
GMERemittance/Module/SendMoneyModules/SendMoneyCode/User Interface/View/SendMoneyCodeViewController.swift

@ -229,7 +229,7 @@ extension SendMoneyCodeViewController: SendMoneyCodeViewInterface {
}
func show(error: String) {
self.alert(message: error)
self.alert(type: .error, message: error)
}
func expiredError(error: Error) {

2
GMERemittance/Module/SendMoneyModules/SendMoneyExchangeRate/User Interface/View/SendMoneyExchangeRateViewController.swift

@ -395,7 +395,7 @@ extension SendMoneyExchangeRateViewController: SendMoneyExchangeRateViewInterfac
}
func show(error: String) {
alert(message: error)
alert(type: .error, message: error)
}
func setCoupons(_ coupons: [Coupon]?) {

2
GMERemittance/Module/SendMoneyModules/SendMoneyPaymentMode/User Interface/View/BankBranchPicker/BankBranchPickerViewController.swift

@ -282,7 +282,7 @@ extension BankBranchPickerViewController: FetchBankBranchService {
self.filteredPlaces = models
}) { (error) in
self.hideProgressHud()
self.alert(message: error.localizedDescription)
self.alert(type: .error, message: error.localizedDescription)
}
}
}

2
GMERemittance/Module/SendMoneyModules/SendMoneyPaymentMode/User Interface/View/SendMoneyPaymentModeViewController.swift

@ -431,7 +431,7 @@ extension SendMoneyPaymentModeViewController: SendMoneyPaymentModeViewInterface
}
func show(error: String) {
self.alert(message: error)
self.alert(type: .error, message: error)
}
func showLoading() {

2
GMERemittance/Module/SendMoneyModules/SendMoneyReceipt/User Interface/View/SendMoneyReceiptViewController.swift

@ -244,7 +244,7 @@ extension SendMoneyReceiptViewController: SendMoneyReceiptViewInterface {
}
func show(error: String) {
self.alert(message: error)
self.alert(type: .error, message: error)
}
func show(model: SendMoneyReciept) {

6
GMERemittance/Module/SendMoneyModules/SendMoneyVerification/User Interface/View/SendMoneyVerificationViewController.swift

@ -232,7 +232,7 @@ extension SendMoneyVerificationViewController: SendMoneyVerificationViewInterfac
if let id = model?.id {
self.presenter?.openReciept(transactionId: id)
}else {
self.alert(message: "No Transaction recievied.")
self.alert(type: .error, message: "No Transaction recievied.")
}
}
}
@ -246,7 +246,7 @@ extension SendMoneyVerificationViewController: SendMoneyVerificationViewInterfac
}
}
self.alert(message: error)
self.alert(type: .error, message: error)
}
func showLoading() {
@ -307,7 +307,7 @@ extension SendMoneyVerificationViewController: BiometricAuthenticationViewContro
break
}
case .biometryNotEnrolled, .notBeConfigured, .biometryNotAvailable:
self.alert(message: error.message)
self.alert(type: .error, message: error.message)
default:
break
}

2
GMERemittance/Module/SideMenu/Auto refund/AutoRefundsViewController.swift

@ -148,7 +148,7 @@ class AutoRefundsViewController: UIViewController {
}
func show(error: String) {
self.alert(message: error)
self.alert(type: .error, message: error)
}
}

3
GMERemittance/Module/SideMenu/SettingViewController.swift

@ -89,7 +89,8 @@ class SettingViewController: UIViewController {
BiometricAuthenticationWireframe().showBiometricAuthentication() { error in
if error != nil {
DispatchQueue.main.async {
self.alert(message: error!.message)
// self.alert(message: error!.message)
self.gmeAlert(message: error!.message)
self.useBiometricAuthSwitch.setOn(false, animated: true)
}
} else {

2
GMERemittance/Module/SplashScreen/User Interface/View/SplashScreenViewController.swift

@ -93,7 +93,7 @@ class SplashScreenViewController: UIViewController {
// MARK: IBActions
private func checkJailBreak() {
if DTTJailbreakDetection.isJailbroken() {
alert(message: "Your device is jail broken.", title: "Alert!") {
alert(type: .error, message: "Your device is jail broken.", title: "Alert!") {
exit(0)
}
}

2
GMERemittance/Module/TransactionHistoryModules/MessageCompose/User Interface/View/MessageComposeViewController.swift

@ -124,7 +124,7 @@ extension MessageComposeViewController: MessageComposeViewInterface {
}
func show(error: String) {
self.alert(message: error)
self.alert(type: .error, message: error)
}
}

2
GMERemittance/Module/WalletStatement/User Interface/View/WalletStatementViewController.swift

@ -145,7 +145,7 @@ extension WalletStatementViewController: WalletStatementViewInterface {
}
func show(error: String) {
self.alert(message: error)
self.alert(type: .error, message: error)
}
func show(models: [WalletStatement]) {

6
GMERemittance/Utility/ConfirmAlert/ConfirmViewController.swift

@ -103,9 +103,9 @@ class ConfirmViewController: UIViewController {
}
private func roundView(){
mainView.layer.cornerRadius = 10
confirmButton.layer.cornerRadius = 10
cancelButton.layer.cornerRadius = 10
mainView.layer.cornerRadius = 5
confirmButton.layer.cornerRadius = 5
cancelButton.layer.cornerRadius = 5
}
private func setMultiLanguage(){

16
GMERemittance/Utility/ConfirmAlert/ConfirmViewController.xib

@ -43,7 +43,7 @@
<rect key="frame" x="0.0" y="20" width="375" height="647"/>
<subviews>
<view opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="4QK-EJ-W5i">
<rect key="frame" x="10" y="311.5" width="355" height="325.5"/>
<rect key="frame" x="10" y="309.5" width="355" height="327.5"/>
<subviews>
<view opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="gqp-C5-0ib" userLabel="Title">
<rect key="frame" x="0.0" y="5" width="355" height="44"/>
@ -67,13 +67,13 @@
</constraints>
</view>
<stackView opaque="NO" contentMode="scaleToFill" axis="vertical" distribution="fillEqually" translatesAutoresizingMaskIntoConstraints="NO" id="muo-Bg-1vO">
<rect key="frame" x="10" y="227.5" width="335" height="88"/>
<rect key="frame" x="10" y="227.5" width="335" height="100"/>
<subviews>
<button opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="mNW-zc-IvE">
<rect key="frame" x="0.0" y="0.0" width="335" height="44"/>
<color key="backgroundColor" red="0.92941176469999998" green="0.1058823529" blue="0.14117647059999999" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<rect key="frame" x="0.0" y="0.0" width="335" height="50"/>
<color key="backgroundColor" red="0.92941176469999998" green="0.1058823529" blue="0.14117647059999999" alpha="1" colorSpace="calibratedRGB"/>
<constraints>
<constraint firstAttribute="height" constant="44" id="Ui7-Wd-gqu"/>
<constraint firstAttribute="height" constant="50" id="Ui7-Wd-gqu"/>
</constraints>
<fontDescription key="fontDescription" name="SanFranciscoDisplay-Medium" family="San Francisco Display" pointSize="17"/>
<color key="tintColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
@ -85,11 +85,11 @@
</connections>
</button>
<button opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="HNX-GD-MMn">
<rect key="frame" x="0.0" y="44" width="335" height="44"/>
<rect key="frame" x="0.0" y="50" width="335" height="50"/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<fontDescription key="fontDescription" name="SanFranciscoDisplay-Regular" family="San Francisco Display" pointSize="17"/>
<state key="normal" title="Cancel">
<color key="titleColor" red="0.92941176469999998" green="0.1058823529" blue="0.14117647059999999" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<color key="titleColor" white="0.33333333333333331" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</state>
<connections>
<action selector="touchCancel:" destination="-1" eventType="touchUpInside" id="sJA-Fj-Z6F"/>
@ -171,7 +171,7 @@
<constraint firstItem="muo-Bg-1vO" firstAttribute="leading" secondItem="4QK-EJ-W5i" secondAttribute="leading" constant="10" id="0Q5-eh-W6s"/>
<constraint firstItem="gqp-C5-0ib" firstAttribute="leading" secondItem="4QK-EJ-W5i" secondAttribute="leading" id="8vZ-BZ-0zF"/>
<constraint firstItem="h9a-Vh-zMZ" firstAttribute="top" secondItem="gqp-C5-0ib" secondAttribute="bottom" constant="5" id="Mrk-xg-464"/>
<constraint firstAttribute="bottom" secondItem="muo-Bg-1vO" secondAttribute="bottom" constant="10" id="OWs-00-BQa"/>
<constraint firstAttribute="bottom" secondItem="muo-Bg-1vO" secondAttribute="bottom" id="OWs-00-BQa"/>
<constraint firstAttribute="trailing" secondItem="gqp-C5-0ib" secondAttribute="trailing" id="Prx-jA-5nD"/>
<constraint firstItem="h9a-Vh-zMZ" firstAttribute="leading" secondItem="4QK-EJ-W5i" secondAttribute="leading" constant="10" id="cAp-az-sPq"/>
<constraint firstAttribute="trailing" secondItem="muo-Bg-1vO" secondAttribute="trailing" constant="10" id="hau-qt-ucq"/>

91
GMERemittance/Utility/GMEAlert/GMEAlertViewController.swift

@ -0,0 +1,91 @@
//
// GMEAlertViewController.swift
// GME Remit
//
// Created by InKwon Devik Kim on 02/07/2019.
// Copyright © 2019 Gobal Money Express Co. Ltd. All rights reserved.
//
import UIKit
class GMEAlertViewController: UIViewController {
@IBOutlet private weak var titleLabel: UILabel!
@IBOutlet private weak var messageLabel: UILabel!
@IBOutlet private weak var rightButton: UIButton!
@IBOutlet private weak var leftButton: UIButton!
@IBOutlet private weak var mainView: UIView!
@IBOutlet private weak var transParentView: UIView!
private var rightButtonAction: (() -> Void)?
private var leftButtonAction: (() -> Void)?
private var titleText: String?
private var messageText: String?
private var rightButtonTitle: String?
private var leftButtonTitle: String?
override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: Bundle?) {
super.init(nibName: nibNameOrNil, bundle: nibBundleOrNil)
}
required init?(coder aDecoder: NSCoder) {
super.init(coder: aDecoder)
}
init(
title: String? = "Alert",
message: String? = nil,
rightButtonTitle: String? = nil,
leftButtonTitle: String? = nil,
rightButtonAction: (() -> Void)? = nil,
leftButtonAction: (() -> Void)? = nil
) {
super.init(nibName: "GMEAlertViewController", bundle: nil)
self.titleText = title
self.messageText = message
self.rightButtonTitle = rightButtonTitle
self.leftButtonTitle = leftButtonTitle
self.rightButtonAction = rightButtonAction
self.leftButtonAction = leftButtonAction
modalPresentationStyle = .overFullScreen
modalTransitionStyle = .crossDissolve
}
override func viewDidLoad() {
super.viewDidLoad()
mainView.layer.cornerRadius = 5
titleLabel.text = titleText
messageLabel.text = messageText
rightButton.setTitle(rightButtonTitle, for: .normal)
leftButton.setTitle(leftButtonTitle, for: .normal)
if leftButtonTitle == nil {
leftButton.isEnabled = false
leftButton.isHidden = true
}
}
override func viewWillAppear(_ animated: Bool) {
super.viewWillAppear(animated)
mainView.popUpBouncy()
}
@IBAction func touchRightButton(_ sender: UIButton) {
self.rightButtonAction?()
self.dismiss(animated: false, completion: nil)
}
@IBAction func touchLeftButton(_ sender: UIButton) {
self.leftButtonAction?()
self.dismiss(animated: false, completion: nil)
}
}

141
GMERemittance/Utility/GMEAlert/GMEAlertViewController.xib

@ -0,0 +1,141 @@
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="14490.70" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
<device id="retina4_7" orientation="portrait">
<adaptation id="fullscreen"/>
</device>
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="14490.49"/>
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
<customFonts key="customFonts">
<array key="SanFranciscoDisplay-Medium.otf">
<string>SanFranciscoDisplay-Medium</string>
</array>
<array key="SanFranciscoDisplay-Regular.otf">
<string>SanFranciscoDisplay-Regular</string>
</array>
</customFonts>
<objects>
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="GMEAlertViewController" customModule="GME_Remit" customModuleProvider="target">
<connections>
<outlet property="leftButton" destination="JWT-7G-nWP" id="QZf-VN-eQF"/>
<outlet property="mainView" destination="bog-Yc-fSF" id="j3k-Kd-I4w"/>
<outlet property="messageLabel" destination="vZn-aC-Kup" id="mOW-n2-gmG"/>
<outlet property="rightButton" destination="N77-z5-GBG" id="Uvu-ck-IeA"/>
<outlet property="titleLabel" destination="rfn-wg-MBE" id="tnN-AI-jb6"/>
<outlet property="transParentView" destination="Cco-Tf-vUV" id="8IM-dS-Gcg"/>
<outlet property="view" destination="i5M-Pr-FkT" id="sfx-zR-JGt"/>
</connections>
</placeholder>
<placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
<view clearsContextBeforeDrawing="NO" contentMode="scaleToFill" id="i5M-Pr-FkT">
<rect key="frame" x="0.0" y="0.0" width="375" height="667"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="Cco-Tf-vUV">
<rect key="frame" x="0.0" y="0.0" width="375" height="667"/>
<subviews>
<view opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="bog-Yc-fSF">
<rect key="frame" x="37.5" y="225.5" width="300" height="216"/>
<subviews>
<stackView opaque="NO" contentMode="scaleToFill" axis="vertical" spacing="8" translatesAutoresizingMaskIntoConstraints="NO" id="ivh-OD-kSD">
<rect key="frame" x="0.0" y="0.0" width="300" height="216"/>
<subviews>
<view opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="dwd-4A-fUB">
<rect key="frame" x="0.0" y="0.0" width="300" height="158"/>
<subviews>
<stackView opaque="NO" contentMode="scaleToFill" axis="vertical" spacing="5" translatesAutoresizingMaskIntoConstraints="NO" id="61r-PG-8gH">
<rect key="frame" x="20" y="20" width="260" height="118"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Alert" textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="rfn-wg-MBE">
<rect key="frame" x="0.0" y="0.0" width="260" height="46"/>
<fontDescription key="fontDescription" name="SanFranciscoDisplay-Medium" family="San Francisco Display" pointSize="18"/>
<nil key="textColor"/>
<nil key="highlightedColor"/>
</label>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="252" textAlignment="center" lineBreakMode="wordWrap" numberOfLines="5" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="vZn-aC-Kup">
<rect key="frame" x="0.0" y="51" width="260" height="67"/>
<string key="text">Welcome to the Swift community. Together we are working to build a programming language to empower everyone to turn their ideas into apps on any platform.</string>
<fontDescription key="fontDescription" name="SanFranciscoDisplay-Regular" family="San Francisco Display" pointSize="14"/>
<nil key="textColor"/>
<nil key="highlightedColor"/>
</label>
</subviews>
</stackView>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstItem="61r-PG-8gH" firstAttribute="top" secondItem="dwd-4A-fUB" secondAttribute="top" constant="20" id="Y3Q-hK-LiB"/>
<constraint firstAttribute="trailing" secondItem="61r-PG-8gH" secondAttribute="trailing" constant="20" id="YY9-FY-hXs"/>
<constraint firstAttribute="bottom" secondItem="61r-PG-8gH" secondAttribute="bottom" constant="20" id="toi-ga-lvE"/>
<constraint firstItem="61r-PG-8gH" firstAttribute="leading" secondItem="dwd-4A-fUB" secondAttribute="leading" constant="20" id="y8h-RS-tUt"/>
</constraints>
</view>
<stackView opaque="NO" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="TJL-Yy-ccg">
<rect key="frame" x="0.0" y="166" width="300" height="50"/>
<subviews>
<button opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="JWT-7G-nWP">
<rect key="frame" x="0.0" y="0.0" width="120" height="50"/>
<color key="backgroundColor" white="0.33333333333333331" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<fontDescription key="fontDescription" name="SanFranciscoDisplay-Medium" family="San Francisco Display" pointSize="17"/>
<color key="tintColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<state key="normal" title="Cancel"/>
<connections>
<action selector="touchLeftButton:" destination="-1" eventType="touchUpInside" id="9vJ-n6-nu4"/>
</connections>
</button>
<button opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="N77-z5-GBG">
<rect key="frame" x="120" y="0.0" width="180" height="50"/>
<color key="backgroundColor" red="0.92941176469999998" green="0.1058823529" blue="0.14117647059999999" alpha="1" colorSpace="calibratedRGB"/>
<constraints>
<constraint firstAttribute="height" constant="50" id="tPZ-6o-s4I"/>
</constraints>
<fontDescription key="fontDescription" name="SanFranciscoDisplay-Medium" family="San Francisco Display" pointSize="17"/>
<color key="tintColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<state key="normal" title="Ok"/>
<connections>
<action selector="touchRightButton:" destination="-1" eventType="touchUpInside" id="dG6-s0-YGh"/>
</connections>
</button>
</subviews>
<constraints>
<constraint firstItem="JWT-7G-nWP" firstAttribute="width" secondItem="TJL-Yy-ccg" secondAttribute="width" multiplier="0.4:1" id="99V-FO-kvl"/>
</constraints>
</stackView>
</subviews>
</stackView>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstAttribute="height" relation="greaterThanOrEqual" constant="150" id="490-Nq-19x"/>
<constraint firstItem="ivh-OD-kSD" firstAttribute="leading" secondItem="bog-Yc-fSF" secondAttribute="leading" id="BQq-aS-W9S"/>
<constraint firstAttribute="bottom" secondItem="ivh-OD-kSD" secondAttribute="bottom" id="FAl-3U-jfp"/>
<constraint firstAttribute="trailing" secondItem="ivh-OD-kSD" secondAttribute="trailing" id="V4L-LT-cbY"/>
<constraint firstItem="ivh-OD-kSD" firstAttribute="top" secondItem="bog-Yc-fSF" secondAttribute="top" id="rN2-dT-ts8"/>
</constraints>
</view>
</subviews>
<color key="backgroundColor" white="0.0" alpha="0.60223137842465746" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstItem="bog-Yc-fSF" firstAttribute="width" secondItem="Cco-Tf-vUV" secondAttribute="width" multiplier="0.8:1" id="Z37-ht-jiJ"/>
<constraint firstItem="bog-Yc-fSF" firstAttribute="centerY" secondItem="Cco-Tf-vUV" secondAttribute="centerY" id="hYN-Jk-X9O"/>
<constraint firstItem="bog-Yc-fSF" firstAttribute="centerX" secondItem="Cco-Tf-vUV" secondAttribute="centerX" id="l0W-ex-2mL"/>
</constraints>
</view>
</subviews>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstItem="Cco-Tf-vUV" firstAttribute="top" secondItem="i5M-Pr-FkT" secondAttribute="top" id="3qc-1x-oTc"/>
<constraint firstItem="fnl-2z-Ty3" firstAttribute="bottom" secondItem="Cco-Tf-vUV" secondAttribute="bottom" id="5HQ-le-1he"/>
<constraint firstItem="Cco-Tf-vUV" firstAttribute="leading" secondItem="fnl-2z-Ty3" secondAttribute="leading" id="IDA-9K-IHH"/>
<constraint firstItem="fnl-2z-Ty3" firstAttribute="trailing" secondItem="Cco-Tf-vUV" secondAttribute="trailing" id="Ohi-rJ-lhk"/>
</constraints>
<nil key="simulatedTopBarMetrics"/>
<nil key="simulatedBottomBarMetrics"/>
<viewLayoutGuide key="safeArea" id="fnl-2z-Ty3"/>
<point key="canvasLocation" x="39.200000000000003" y="46.326836581709152"/>
</view>
</objects>
</document>

2
GMERemittance/Utility/HotLine/User Interface/View/HotLineViewController.swift

@ -57,7 +57,7 @@ extension HotLineViewController: HotLineViewInterface {
}
func setError(with error: Error) {
alert(message: error.localizedDescription)
alert(type: .error, message: error.localizedDescription)
}
}

Loading…
Cancel
Save