Пример #1
0
        public ActionResult Create(Technology technologie)
        {
            if (ModelState.IsValid)
            {
                db.Technologies.Add(technologie);
                db.SaveChanges();
                return RedirectToAction("Index");
            }

            CreateFrame(title);
            return View(technologie);
        }
Пример #2
0
 public ActionResult Edit(Technology technologie)
 {
     if (ModelState.IsValid)
     {
         db.Entry(technologie).State = EntityState.Modified;
         db.SaveChanges();
         return RedirectToAction("Index");
     }
     return View(technologie);
 }