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