Beispiel #1
0
 public ActionResult Delete(int id, ToolVM toolVM)
 {
     if (toolManager.DeleteTool(toolVM.Id))
     {
         return(RedirectToAction("Index"));
     }
     else
     {
         ModelState.AddModelError("", "Ошибка сохранения данных.");
         return(RedirectToAction("Delete", new { id = id }));
     }
 }