public ActionResult Delete(int id) { ecm.Models.item item = db.items.Find(id); db.items.Remove(item); db.SaveChanges(); return(RedirectToAction("items")); }
public ActionResult Edit(int id) { ecm.Models.item item = db.items.Find(id); if (item == null) { return(HttpNotFound()); } return(View(item)); }
public ActionResult ProductDetails(int id) { ViewBag.title = "Product Details"; ecm.Models.item item = db.items.Find(id); if (item == null) { return(HttpNotFound()); } return(View(item)); }