public ActionResult DeleteConfirmed(int id)
        {
            DSNguyenVong dSNguyenVong = db.DSNguyenVongs.Find(id);

            db.DSNguyenVongs.Remove(dSNguyenVong);
            db.SaveChanges();
            return(RedirectToAction("Index"));
        }
 public ActionResult Edit([Bind(Include = "MaHoSo,ThuTuNV,MaToHop,MaNganh,MaTDH,TrangThaiNV")] DSNguyenVong dSNguyenVong)
 {
     if (ModelState.IsValid)
     {
         db.Entry(dSNguyenVong).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     ViewBag.MaHoSo  = new SelectList(db.HoSoXetTuyens, "MaHoSo", "CMDN", dSNguyenVong.MaHoSo);
     ViewBag.MaNganh = new SelectList(db.NganhTheoBos, "MaNganh", "TeNganh", dSNguyenVong.MaNganh);
     ViewBag.MaToHop = new SelectList(db.ToHopMons, "MaToHop", "Mon1", dSNguyenVong.MaToHop);
     return(View(dSNguyenVong));
 }
        // GET: Admin/DSNguyenVongs/Details/5
        public ActionResult Details(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            DSNguyenVong dSNguyenVong = db.DSNguyenVongs.Find(id);

            if (dSNguyenVong == null)
            {
                return(HttpNotFound());
            }
            return(View(dSNguyenVong));
        }
        // GET: Admin/DSNguyenVongs/Edit/5
        public ActionResult Edit(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            DSNguyenVong dSNguyenVong = db.DSNguyenVongs.Find(id);

            if (dSNguyenVong == null)
            {
                return(HttpNotFound());
            }
            ViewBag.MaHoSo  = new SelectList(db.HoSoXetTuyens, "MaHoSo", "CMDN", dSNguyenVong.MaHoSo);
            ViewBag.MaNganh = new SelectList(db.NganhTheoBos, "MaNganh", "TeNganh", dSNguyenVong.MaNganh);
            ViewBag.MaToHop = new SelectList(db.ToHopMons, "MaToHop", "Mon1", dSNguyenVong.MaToHop);
            return(View(dSNguyenVong));
        }