public ActionResult DeleteConfirmed(int id) { FlysScreenType flysScreenType = db.FlysScreenTypes.Find(id); db.FlysScreenTypes.Remove(flysScreenType); db.SaveChanges(); return(RedirectToAction("Index")); }
public ActionResult Edit([Bind(Include = "FlyScreenTypeID,FlyScreenName")] FlysScreenType flysScreenType) { if (ModelState.IsValid) { db.Entry(flysScreenType).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(flysScreenType)); }
public ActionResult Create([Bind(Include = "FlyScreenTypeID,FlyScreenName")] FlysScreenType flysScreenType) { if (ModelState.IsValid) { db.FlysScreenTypes.Add(flysScreenType); db.SaveChanges(); return(RedirectToAction("Index")); } return(View(flysScreenType)); }
// GET: FlysScreenTypes/Delete/5 public ActionResult Delete(int?id) { if (id == null) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } FlysScreenType flysScreenType = db.FlysScreenTypes.Find(id); if (flysScreenType == null) { return(HttpNotFound()); } return(View(flysScreenType)); }