Ejemplo n.º 1
0
 public ActionResult Edit(int id, ShiftModel shift)
 {
     if (ModelState.IsValid)
     {
         if (id != shift.ShiftID)
         {
             return RedirectToAction("Message", "Error", new { Error = "シフト在しません。" });
         }
     }
     WFMDBDataContext db = new WFMDBDataContext();
     db.uspWFMUpdateShift(id, shift.ShiftName, shift.StartTime, shift.EndTime);
     return RedirectToAction("Index");
 }
Ejemplo n.º 2
0
        public ActionResult Edit(int id, ShiftModel shift)
        {
            if (ModelState.IsValid)
            {
                if (id != shift.ShiftID)
                {
                    return(RedirectToAction("Message", "Error", new { Error = "シフト在しません。" }));
                }
            }
            WFMDBDataContext db = new WFMDBDataContext();

            db.uspWFMUpdateShift(id, shift.ShiftName, shift.StartTime, shift.EndTime);
            return(RedirectToAction("Index"));
        }