示例#1
0
        public ActionResult Create(Room_status_info room_status_info)
        {
            if (ModelState.IsValid)
            {
                db.rstatus.Add(room_status_info);
                db.SaveChanges();
                return RedirectToAction("Index");
            }

            return View(room_status_info);
        }
示例#2
0
 public ActionResult Edit(Room_status_info room_status_info)
 {
     if (ModelState.IsValid)
     {
         db.Entry(room_status_info).State = EntityState.Modified;
         db.SaveChanges();
         return RedirectToAction("Index");
     }
     return View(room_status_info);
 }