async void GetAccountCodes() { try { if (IosUtils.IosUtility.IsReachable()) { IosUtils.IosUtility.showProgressHud(""); accountOrderResponseList = await Webservices.WebServiceMethods.GetAccountForOrders(); IosUtility.hideProgressHud(); if (accountOrderResponseList != null && accountOrderResponseList.Count > 0) { var temp = accountOrderResponseList.Where(a => a.AccountId == SuperVC.LedgerOrderObj.AccountId).FirstOrDefault(); SelectedAccount = temp; if (SelectedAccount == null) { SelectedAccount = accountOrderResponseList[0]; } PickerModel = new AccountOrderPickerModel(accountOrderResponseList, TxtSelectAcoountTilte, SelectedAccount); IBAccountPicker.Model = PickerModel; ShowAccountAddress(); ShowUserCurrency(); } else { IosUtils.IosUtility.showAlertWithInfo(IosUtils.LocalizedString.sharedInstance.GetLocalizedString("LSErrorTitle", "LSErrorTitle"), IosUtils.LocalizedString.sharedInstance.GetLocalizedString("LSUnknownError", "LSErrorTitle")); } } } catch (Exception e) { IosUtility.hideProgressHud(); IosUtils.IosUtility.showAlertWithInfo(IosUtils.LocalizedString.sharedInstance.GetLocalizedString("LSErrorTitle", "LSErrorTitle"), IosUtils.LocalizedString.sharedInstance.GetLocalizedString("LSUnknownError", "LSErrorTitle")); } }
async void GetRevenueAccount() { try { if (IosUtils.IosUtility.IsReachable()) { IosUtils.IosUtility.showProgressHud(""); revenueAccountResponseList = await Webservices.WebServiceMethods.GetRevenueOrders(compCode); IosUtility.hideProgressHud(); if (revenueAccountResponseList != null && revenueAccountResponseList.Count > 0) { var temp = revenueAccountResponseList.Where(a => a.AccountId == AccountId).FirstOrDefault(); SelectedAccount = temp; if (SelectedAccount == null) { SelectedAccount = revenueAccountResponseList[0]; } PickerModel = new AccountOrderPickerModel(revenueAccountResponseList, TxtRevenue, SelectedAccount); RevenuePicker.Model = PickerModel; isTaxEdit = false; GetTaxTypes(); } else { IosUtils.IosUtility.showAlertWithInfo(IosUtils.LocalizedString.sharedInstance.GetLocalizedString("LSErrorTitle", "LSErrorTitle"), IosUtils.LocalizedString.sharedInstance.GetLocalizedString("LSUnknownError", "LSErrorTitle")); } } } catch (Exception e) { IosUtility.hideProgressHud(); IosUtils.IosUtility.showAlertWithInfo(IosUtils.LocalizedString.sharedInstance.GetLocalizedString("LSErrorTitle", "LSErrorTitle"), IosUtils.LocalizedString.sharedInstance.GetLocalizedString("LSUnknownError", "LSErrorTitle")); } }