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