/// <summary> /// Method Name : GoToDesboardAsync /// Author : Hiren Patel /// Creation Date : 1 Feb 2018 /// Purpose : Use for Update Estimed /// Revision : /// </summary> private async Task GoToDesboardAsync() { string retMessage = string.Empty; try { // Valuation RemoveCurrencyFormat(); ValuationDeductibleModel valuationDeductibleModel = UtilityPCL.ValuationDeductibleList().Where(a => a.DeductibleName == estimateModel.ValuationDeductible).SingleOrDefault(); if (valuationDeductibleModel != null) { estimateModel.ValuationDeductible = valuationDeductibleModel.DeductibleCode; } if (estimateModel.IsAddressEdited || estimateModel.IsServiceDate || estimateModel.IsWhatMatterMostEdited || estimateModel.IsValuationEdited) { loadingOverlay = UIHelper.ShowLoadingScreen(View); RemoveCurrencyFormat(); APIResponse <EstimateModel> aPIResponse = await estimate.PutEstimateData(estimateModel, estimateModel.MoveNumber); loadingOverlay.Hide(); if (aPIResponse.STATUS) { await UpdateMoveDataAsync(); } else { UIHelper.ShowMessage(aPIResponse.Message); } } else { await UpdateMoveDataAsync(); } } catch (Exception error) { retMessage = error.Message; } finally { if (!string.IsNullOrEmpty(retMessage)) { UIHelper.ShowMessage(retMessage); } } }
/// Method Name : GoToDesboardAsync /// Author : Sanket Prajapati /// Creation Date : 12 Dec 2017 /// Purpose :Use for Update Estimed /// Revision : /// </summary> private async Task GoToDesboardAsync() { Estimate estimate; estimate = new Estimate(); string retMessage = string.Empty; try { progressDialog = UIHelper.SetProgressDailoge(this); if (estimateModel.IsAddressEdited || estimateModel.IsServiceDate || estimateModel.IsWhatMatterMostEdited || estimateModel.IsValuationEdited) { APIResponse <EstimateModel> aPIResponse = await estimate.PutEstimateData(estimateModel, estimateModel.MoveNumber); if (aPIResponse.STATUS) { await UpdateMoveDataAsync(); } else { AlertMessage(aPIResponse.Message); } } else { await UpdateMoveDataAsync(); } } catch (Exception error) { retMessage = error.Message; progressDialog.Dismiss(); } finally { progressDialog.Dismiss(); if (!string.IsNullOrEmpty(retMessage)) { AlertMessage(retMessage); } } }