public ActionResult Alterar(Igreja model) { if (ModelState.IsValid) { db.Entry(model).State = EntityState.Modified; db.SaveChanges(); } return RedirectToAction("Pesquisar/" + model.ID_GRUPOCONGREGACIONAL); }
public ActionResult Incluir(Igreja model) { if (ModelState.IsValid) { db.Igrejas.Add(model); db.SaveChanges(); return RedirectToAction("Pesquisar/" + model.ID_GRUPOCONGREGACIONAL); } return View(model); }