public ActionResult DeleteConfirmed(int id) { SHOPLOOKUP sHOPLOOKUP = db.SHOPLOOKUPs.Find(id); db.SHOPLOOKUPs.Remove(sHOPLOOKUP); db.SaveChanges(); return(RedirectToAction("Index")); }
public ActionResult Edit([Bind(Include = "ID,ShopType")] SHOPLOOKUP sHOPLOOKUP) { if (ModelState.IsValid) { db.Entry(sHOPLOOKUP).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(sHOPLOOKUP)); }
public ActionResult Create([Bind(Include = "ID,ShopType")] SHOPLOOKUP sHOPLOOKUP) { if (ModelState.IsValid) { db.SHOPLOOKUPs.Add(sHOPLOOKUP); db.SaveChanges(); return(RedirectToAction("Index")); } return(View(sHOPLOOKUP)); }
// GET: ShopLookup/Edit/5 public ActionResult Edit(int?id) { if (id == null) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } SHOPLOOKUP sHOPLOOKUP = db.SHOPLOOKUPs.Find(id); if (sHOPLOOKUP == null) { return(HttpNotFound()); } return(View(sHOPLOOKUP)); }