Exemplo n.º 1
0
        public ActionResult Edit_Consultants(TBL_CONSULTANT objConslt)
        {
            ViewBag.departments = new SelectList(db.TBL_R_DEPT, "DEPT_ID", "DEPT_NAME");

            db.Entry(objConslt).State = System.Data.Entity.EntityState.Modified;
            db.SaveChanges();
            return(RedirectToAction("Consultants"));
        }
Exemplo n.º 2
0
        public ActionResult Add_Consultants(TBL_CONSULTANT objConslt)
        {
            ViewBag.departments = new SelectList(db.TBL_R_DEPT, "DEPT_ID", "DEPT_NAME");

            db.TBL_CONSULTANT.Add(objConslt);
            db.SaveChanges();
            return(RedirectToAction("Consultants"));
        }