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