Beispiel #1
0
        public ActionResult Create(Series series)
        {
            if (ModelState.IsValid)
            {
                db.Series.Add(series);
                db.SaveChanges();
                return RedirectToAction("Index");
            }

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