public ActionResult DeleteConfirmed(int id) { TypeProcess typeProcess = db.TypeProcess.Find(id); db.TypeProcess.Remove(typeProcess); db.SaveChanges(); return(RedirectToAction("Index")); }
public ActionResult Edit([Bind(Include = "IdTypeProcess,Name,Descriptionq,Active,UseType")] TypeProcess typeProcess) { if (ModelState.IsValid) { db.Entry(typeProcess).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(typeProcess)); }
public ActionResult Create([Bind(Include = "IdTypeProcess,Name,Descriptionq,Active,UseType")] TypeProcess typeProcess) { if (ModelState.IsValid) { db.TypeProcess.Add(typeProcess); db.SaveChanges(); return(RedirectToAction("Index")); } return(View(typeProcess)); }
// GET: TypeProcesses/Delete/5 public ActionResult Delete(int?id) { if (id == null) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } TypeProcess typeProcess = db.TypeProcess.Find(id); if (typeProcess == null) { return(HttpNotFound()); } return(View(typeProcess)); }