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