diff --git a/GMERemittance/Library/CountryInfo.swift b/GMERemittance/Library/CountryInfo.swift index 89aaf041..0205d416 100644 --- a/GMERemittance/Library/CountryInfo.swift +++ b/GMERemittance/Library/CountryInfo.swift @@ -275,7 +275,7 @@ class CountryInfo { "bd" : "100000", // Bangladesh "by" : "1000", // Belarus "ge" : "1000", // Georgia - "id" : "15000000", // indonesia + "id" : "1000000", // indonesia "kz" : "1000", // Kazakhstan "kg" : "1000", // Kyrgyzstan "my" : "10000", // Malaysia diff --git a/GMERemittance/Module/Resend/User Interface/View/ResendViewController.swift b/GMERemittance/Module/Resend/User Interface/View/ResendViewController.swift index 9ecb352d..0456dc63 100644 --- a/GMERemittance/Module/Resend/User Interface/View/ResendViewController.swift +++ b/GMERemittance/Module/Resend/User Interface/View/ResendViewController.swift @@ -171,7 +171,7 @@ class ResendViewController: UIViewController { } func selectedAcunt(acunt: Account) { - guard let index = self.selectedIndex, let transaction = self.transactions.elementAt(index: index), let requestModel = self.requestModel, let transactionId = self.filteredTransaction.elementAt(index: index)?.transactionId else {return} + guard let index = self.selectedIndex, let transaction = self.filteredTransaction.elementAt(index: index), let requestModel = self.requestModel, let transactionId = self.filteredTransaction.elementAt(index: index)?.transactionId else {return} requestModel.autoDebitAccount = acunt requestModel.transaction = transaction diff --git a/GMERemittance/Module/SendMoney/SendMoneyVerification/User Interface/View/SendMoneyVerification.storyboard b/GMERemittance/Module/SendMoney/SendMoneyVerification/User Interface/View/SendMoneyVerification.storyboard index 01fa3b89..6b15bee2 100644 --- a/GMERemittance/Module/SendMoney/SendMoneyVerification/User Interface/View/SendMoneyVerification.storyboard +++ b/GMERemittance/Module/SendMoney/SendMoneyVerification/User Interface/View/SendMoneyVerification.storyboard @@ -1,11 +1,11 @@ - + - + @@ -392,6 +392,38 @@ + @@ -494,6 +526,9 @@ + + + diff --git a/GMERemittance/Module/SendMoney/SendMoneyVerification/User Interface/View/SendMoneyVerificationViewController.swift b/GMERemittance/Module/SendMoney/SendMoneyVerification/User Interface/View/SendMoneyVerificationViewController.swift index 5df1b9de..bf6edeb4 100644 --- a/GMERemittance/Module/SendMoney/SendMoneyVerification/User Interface/View/SendMoneyVerificationViewController.swift +++ b/GMERemittance/Module/SendMoney/SendMoneyVerification/User Interface/View/SendMoneyVerificationViewController.swift @@ -38,6 +38,7 @@ class SendMoneyVerificationViewController: UITableViewController { @IBOutlet weak var exchangeRateLabel: UILabel! @IBOutlet weak var serviceChargeLabel: UILabel! @IBOutlet weak var payoutAgentBankLabel: UILabel! + @IBOutlet weak var accountNoLabel: UILabel! @IBOutlet weak var payoutCountryTitleLabel: UILabel! @IBOutlet weak var payoutModeTitleLabel: UILabel! @@ -45,6 +46,7 @@ class SendMoneyVerificationViewController: UITableViewController { @IBOutlet weak var exchangeRateTitleLabel: UILabel! @IBOutlet weak var serviceChargeTitleLabel: UILabel! @IBOutlet weak var payoutAgentBankTitleLabel: UILabel! + @IBOutlet weak var accountNumTitlelabel: UILabel! // title labels @IBOutlet weak var recieverDetailsLabel: UILabel! @@ -54,6 +56,8 @@ class SendMoneyVerificationViewController: UITableViewController { @IBOutlet weak var agreeAndSendButton: UIButton! @IBOutlet weak var bankNameStackView: UIStackView! + @IBOutlet weak var accountNumberStackView: UIStackView! + var url: String? @@ -120,6 +124,9 @@ class SendMoneyVerificationViewController: UITableViewController { mQwertyTransKeyView?.delegate = self mNumberTransKeyView?.delegate = self self.bankNameStackView.isHidden = (self.requestModel?.bank?.name ?? "").isEmpty + self.accountNumberStackView.isHidden = (self.requestModel?.paymemtMode?.accountNumber ?? "").isEmpty + + } override func viewDidDisappear(_ animated: Bool) { @@ -221,6 +228,7 @@ class SendMoneyVerificationViewController: UITableViewController { self.exchangeRateLabel.text = self.requestModel?.exchangeRateDetail?.exchangeRate self.serviceChargeLabel.text = self.requestModel?.exchangeRateDetail?.transferFee self.payoutAgentBankLabel.text = self.requestModel?.bank?.name + self.accountNoLabel.text = self.requestModel?.paymemtMode?.accountNumber } func askPassword() { diff --git a/GMERemittance/Recipient/RecipientListViewController.swift b/GMERemittance/Recipient/RecipientListViewController.swift index 96d44755..175ccfe6 100644 --- a/GMERemittance/Recipient/RecipientListViewController.swift +++ b/GMERemittance/Recipient/RecipientListViewController.swift @@ -143,18 +143,7 @@ extension RecipientListViewController: UITableViewDelegate,UITableViewDataSource // TODO:- for kftc enable this in next release self.showMethodSelection(for: index) - - - // remove this - -// if let navigation = self.navigationController { -// if let reciepient = self.reciepients?.elementAt(index: index) { -// let wireframe = SendMoneyParentWireframe() -// let acunt = Account() -// acunt.type = "wallet" -// wireframe.open(for: reciepient, with: acunt, in: navigation) -// } -// } + } diff --git a/GMERemittance/SideMenu/AboutGMEViewController.swift b/GMERemittance/SideMenu/AboutGMEViewController.swift index df189433..801b7109 100644 --- a/GMERemittance/SideMenu/AboutGMEViewController.swift +++ b/GMERemittance/SideMenu/AboutGMEViewController.swift @@ -32,6 +32,30 @@ class AboutGMEViewController: UIViewController { let URLLinkedInApp: String = "linkedin://company/gmeremit/" let URLLinkedInBrowser: String = "https://www.linkedin.com/company/gmeremit/" + +// var defaultCountries = ["Nepal", "Cambodia", "Philipinnes", "Sri Lanka", "Vietnam", "India", "Pakistan", "azerbaijan", "Bangladesh", "Belarus", "Georgia", "Indonesia", "Kazakhstan", "Kyrgyzstan", "Malaysia", "Moldova", "Mongolia", "Myanmar", "Russian Federation", "Singapore", "Tajikistan", "Thailand", "Uzbekistan"] +// var defaultCountryCodes = ["np", "kh", "ph", "lk", "vn", "in", "pk", "az", "bd", "by", "ge", "id", "kz", "kg", "my", "md", "mn", "mm", "ru", "sg", "tj", "th", "uz", "en"] + + + let FacebookUrls: [String: String] = [ + "np" : "https://www.facebook.com/gmenepal/", + "kh" : "https://www.facebook.com/gmecambodia/", + "lk" : "https://www.facebook.com/gmeremitsrilanka/", + "vn" : "https://www.facebook.com/gmevietnam/", + "ph" : "https://www.facebook.com/gmephilippines/", + "bd" : "https://www.facebook.com/gmebangladesh/", + "id" : "https://www.facebook.com/gmeindonesia/", + "th" : "https://www.facebook.com/gmethailand/", + "mn" : "https://www.facebook.com/gmemongolia/", + "uz" : "https://www.facebook.com/gmeuzbekistan/", + "in" : "https://www.facebook.com/GMEindia/", + "pk" : "https://www.facebook.com/gmepakistan/", + "mm" : "https://www.facebook.com/gmemyanmar/" + + ] + + + override func viewDidLoad() { super.viewDidLoad() self.versionLabel.text = Utility.getAppVersion() @@ -58,36 +82,33 @@ class AboutGMEViewController: UIViewController { } @IBAction func checkForUpdate(_ sender: Any) { - +// } @IBAction func openLinkedIn(_ sender: Any) { - UIApplication.tryURL(urls: [self.URLLinkedInApp, - self.URLLinkedInBrowser - ]) +// UIApplication.tryURL(urls: [self.URLLinkedInApp, +// self.URLLinkedInBrowser +// ]) } @IBAction func openFacebook(_ sender: Any) { - UIApplication.tryURL(urls: [self.URLFacebookApp, - self.URLFacebookApp2, - self.URLFacebookBrowser - ]) + guard let nativeCountry = UserDefaults.standard.string(forKey: UserKeys.countryCode) else {return} + UIApplication.tryURL(url: self.FacebookUrls[nativeCountry.lowercased()] ?? "") } } extension UIApplication { - class func tryURL(urls: [String]) { + class func tryURL(url: String) { + let application = UIApplication.shared - for url in urls { - if application.canOpenURL(URL(string: url)!) { - if #available(iOS 10.0, *) { - application.open(URL(string: url)!, options: [:], completionHandler: nil) - } else { - // Fallback on earlier versions - } - return + if let _url = URL(string: url), application.canOpenURL(_url) { + if #available(iOS 10.0, *) { + application.open(URL(string: url)!, options: [:], completionHandler: nil) + } else { + // Fallback on earlier versions } + return } } }