public ActionResult DeleteConfirmed(short id) { SET_CLIENTS set_clients = db.SET_CLIENTS.Single(s => s.CLIENT_NO == id); db.SET_CLIENTS.DeleteObject(set_clients); db.SaveChanges(); return(RedirectToAction("Index")); }
// // GET: /Clients/Delete/5 public ActionResult Delete(short id = 0) { SET_CLIENTS set_clients = db.SET_CLIENTS.Single(s => s.CLIENT_NO == id); if (set_clients == null) { return(HttpNotFound()); } return(View(set_clients)); }
public ActionResult Edit(SET_CLIENTS set_clients) { if (ModelState.IsValid) { db.SET_CLIENTS.Attach(set_clients); db.ObjectStateManager.ChangeObjectState(set_clients, EntityState.Modified); db.SaveChanges(); return(RedirectToAction("Index")); } return(View(set_clients)); }
public ActionResult Create(SET_CLIENTS set_clients) { if (ModelState.IsValid) { db.SET_CLIENTS.AddObject(set_clients); db.SaveChanges(); return(RedirectToAction("Index")); } return(View(set_clients)); }