public ActionResult Create(StepType steptype) { if (ModelState.IsValid) { steptype.ID = Guid.NewGuid(); db.StepTypes.Add(steptype); db.SaveChanges(); return RedirectToAction("Index"); } return View(steptype); }
public ActionResult Edit(StepType steptype) { if (ModelState.IsValid) { db.Entry(steptype).State = EntityState.Modified; db.SaveChanges(); return RedirectToAction("Index"); } return View(steptype); }