Exemple #1
0
        public ActionResult Create(SOL sol)
        {
            if (ModelState.IsValid)
            {
                db.SOLs.Add(sol);
                db.SaveChanges();
                return RedirectToAction("Index");
            }

            return View(sol);
        }
Exemple #2
0
 public ActionResult Edit(SOL sol)
 {
     if (ModelState.IsValid)
     {
         db.Entry(sol).State = EntityState.Modified;
         db.SaveChanges();
         return RedirectToAction("Index");
     }
     return View(sol);
 }