public ActionResult DeleteConfirmed(int id) { TahDoList tahdolist = db.TahDoLists.Find(id); db.TahDoLists.Remove(tahdolist); db.SaveChanges(); return(RedirectToAction("Index")); }
public ActionResult Edit(TahDoList tahdolist) { if (ModelState.IsValid) { db.Entry(tahdolist).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(tahdolist)); }
// GET: TahDoLists/Delete/5 public ActionResult Delete(int id) { TahDoList tahDoList = db.TahDoLists.Find(id); if (tahDoList == null) { return(HttpNotFound()); } return(View(tahDoList)); }
public ActionResult Edit([Bind(Include = "Id,Title,CreatedAt,Priority,Cost,Summary,Done,DoneAt")] TahDoList tahDoList) { if (ModelState.IsValid) { db.Entry(tahDoList).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(tahDoList)); }
public ActionResult Create(TahDoList tahdolist) { if (ModelState.IsValid) { db.TahDoLists.Add(tahdolist); db.SaveChanges(); return(RedirectToAction("Index")); } return(View(tahdolist)); }
public ActionResult Create([Bind(Include = "Id,Title,CreatedAt,Priority,Cost,Summary,Done,DoneAt")] TahDoList tahDoList) { if (ModelState.IsValid) { db.TahDoLists.Add(tahDoList); db.SaveChanges(); return(RedirectToAction("Index")); } return(View(tahDoList)); }
// // GET: /TahDoList/Delete/5 public ActionResult Delete(int id) { TahDoList tahdolist = db.TahDoLists.Find(id); return(View(tahdolist)); }
// // GET: /TahDoList/Details/5 public ViewResult Details(int id) { TahDoList tahdolist = db.TahDoLists.Find(id); return(View(tahdolist)); }