public ActionResult Delete(TaskModel collection) { try { // TODO: Add delete logic here var idP = collection.Project; tk.Delete(collection.TaskID); return(RedirectToAction("Details", "Project", new { id = idP })); } catch { return(View()); } }
public bool Delete(int taskID) { int result = _taskManagement.Delete(taskID); return(result > 0); }