//[ValidateAntiForgeryToken] public ActionResult DeleteConfirmed(int id) { Opencell opencell = db.Opencells.Find(id); db.Opencells.Remove(opencell); db.SaveChanges(); return(RedirectToAction("Index")); }
// // GET: /OpenCell/Delete/5 public ActionResult Delete(int id = 0) { Opencell opencell = db.Opencells.Find(id); if (opencell == null) { return(HttpNotFound()); } return(View(opencell)); }
//[ValidateAntiForgeryToken] public ActionResult Edit(Opencell opencell) { if (ModelState.IsValid) { db.Entry(opencell).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(opencell)); }
// [ValidateAntiForgeryToken] public ActionResult Create(Opencell opencell) { if (ModelState.IsValid) { db.Opencells.Add(opencell); db.SaveChanges(); return(RedirectToAction("Index")); } return(View(opencell)); }