public async Task <ActionResult> DeleteMerchant(DeleteMerchantDialogViewModel vm) { if (string.IsNullOrEmpty(vm.Id)) { return(this.JsonFailResult(Phrases.FieldShouldNotBeEmpty, "#frmDeleteMerchant")); } await _payMerchantClient.Api.DeleteAsync(vm.Id); return(this.JsonRequestResult("#merchantsList", Url.Action("MerchantsList"))); }
public ActionResult DeleteMerchantDialog(string merchant, string id) { var viewModel = new DeleteMerchantDialogViewModel { Caption = "Delete merchant", Name = merchant, Id = id }; return(View(viewModel)); }