public ActionResult Edit(UserAcount account)
 {
     if (ModelState.IsValid)
     {
         using (CCV_Tables_Context db = new CCV_Tables_Context())
         {
             db.Entry(account).State = EntityState.Modified;
             db.SaveChanges();
             return(RedirectToAction("Index"));
         }
     }
     return(View());
 }
Example #2
0
        public ActionResult Edit(Rack rack)
        {
            using (CCV_Tables_Context db = new CCV_Tables_Context())
            {
                if (ModelState.IsValid)
                {
                    rack.StoreHouseRefId = (int)HttpContext.Session["StoreHouseID"];
                    db.Entry(rack).State = EntityState.Modified;
                    db.SaveChanges();
                    return(RedirectToAction("Index", new{ iD = Session["StoreHouseID"] }));
                }

                return(View());
            }
        }
Example #3
0
        public ActionResult Edit(Shelf shelf)
        {
            using (CCV_Tables_Context db = new CCV_Tables_Context())
            {
                if (ModelState.IsValid)
                {
                    shelf.RackId          = (int)HttpContext.Session["RackID"];
                    db.Entry(shelf).State = EntityState.Modified;
                    db.SaveChanges();
                    return(RedirectToAction("Index", new { iD = Session["RackID"] }));
                }

                return(View());
            }
        }