public ActionResult Create(Evtable evtable) { if (ModelState.IsValid) { db.Evtables.Add(evtable); db.SaveChanges(); return RedirectToAction("Index"); } return View(evtable); }
public ActionResult Edit(Evtable evtable) { if (ModelState.IsValid) { db.Entry(evtable).State = EntityState.Modified; db.SaveChanges(); return RedirectToAction("Index"); } return View(evtable); }