// DELETE api/deposit/5 public IHttpActionResult Delete(int id) { try { _depositService.Delete(id); return(Ok()); } catch (BankClientException ex) { return(BadRequest(ex.Message)); } catch (Exception ex) { return(InternalServerError(ex)); } }
public async Task DeleteDeposit(Deposit deposit) { await _depositService.Delete(deposit); }
public ActionResult Delete(Guid id, FormCollection collection) { _depositService.Delete(id); return(RedirectToAction("Index", new DepositListFiltersModel().GetRouteValues()).WithSuccess("Depósito Eliminado")); }
public async Task <IActionResult> Delete(int id) { await _depoService.Delete(id); return(RedirectToAction("Index")); }