Пример #1
0
        public ActionResult DeleteConfirmed(int id)
        {
            HOLD_PRODUCTS hOLD_PRODUCTS = db.HOLD_PRODUCTS.Find(id);

            db.HOLD_PRODUCTS.Remove(hOLD_PRODUCTS);
            db.SaveChanges();
            return(RedirectToAction("Index"));
        }
Пример #2
0
 public ActionResult Edit([Bind(Include = "ID_GIU_HANG,MA_HANG_HT,NGAY_GIU,TONG_SO_GIU,SL_GIU_DA_XUAT,SL_GIU_CHUA_XU_LY,TRANG_THAI,MA_KHO")] HOLD_PRODUCTS hOLD_PRODUCTS)
 {
     if (ModelState.IsValid)
     {
         db.Entry(hOLD_PRODUCTS).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     ViewBag.MA_HANG_HT = new SelectList(db.PRODUCTS, "MA_HANG_HT", "MA_HANG_NHAP", hOLD_PRODUCTS.MA_HANG_HT);
     ViewBag.MA_KHO     = new SelectList(db.WAREHOUSES, "MA_KHO", "TEN_KHO", hOLD_PRODUCTS.MA_KHO);
     return(View(hOLD_PRODUCTS));
 }
Пример #3
0
        // GET: HopLong/HOLD_PRODUCTS/Details/5
        public ActionResult Details(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            HOLD_PRODUCTS hOLD_PRODUCTS = db.HOLD_PRODUCTS.Find(id);

            if (hOLD_PRODUCTS == null)
            {
                return(HttpNotFound());
            }
            return(View(hOLD_PRODUCTS));
        }
Пример #4
0
        // GET: HopLong/HOLD_PRODUCTS/Edit/5
        public ActionResult Edit(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            HOLD_PRODUCTS hOLD_PRODUCTS = db.HOLD_PRODUCTS.Find(id);

            if (hOLD_PRODUCTS == null)
            {
                return(HttpNotFound());
            }
            ViewBag.MA_HANG_HT = new SelectList(db.PRODUCTS, "MA_HANG_HT", "MA_HANG_NHAP", hOLD_PRODUCTS.MA_HANG_HT);
            ViewBag.MA_KHO     = new SelectList(db.WAREHOUSES, "MA_KHO", "TEN_KHO", hOLD_PRODUCTS.MA_KHO);
            return(View(hOLD_PRODUCTS));
        }