Esempio n. 1
0
        public ActionResult DelegateEmployee(string DeptID)
        {
            List <Users> DeptEmployees = Data_Users.GetAllDeptStaffByDeptID((string)Session["DeptID"]);

            SelectList list = new SelectList(DeptEmployees, "UserID", "Username");

            ViewBag.DepartmentEmps = list;

            return(View());
        }
        public HttpResponseMessage Assginrepresentative(string DeptID)
        {
            Users DepRepInfo = Data_Users.GetDepRepInfo(DeptID);
            var   model1     = DepRepInfo.Username;

            List <Users> DeptStaff = Data_Users.GetAllDeptStaffByDeptID(DeptID);

            var model2 = DeptStaff;

            return(ControllerContext.Request.CreateResponse(HttpStatusCode.OK, (model1, model2)));
        }
Esempio n. 3
0
        public ActionResult Assginrepresentative()
        {
            Users DepRepInfo = Data_Users.GetDepRepInfo((string)Session["DeptID"]);

            ViewBag.DepRepName = DepRepInfo.Username;

            List <Users> DeptSatff = Data_Users.GetAllDeptStaffByDeptID((string)Session["DeptID"]);

            SelectList list = new SelectList(DeptSatff, "UserID", "Username");

            ViewBag.DeptStaff = list;

            return(View());
        }
        public HttpResponseMessage DelegateEmployee(string DeptID)
        {
            List <Users> DeptEmployees = Data_Users.GetAllDeptStaffByDeptID(DeptID);

            return(ControllerContext.Request.CreateResponse(HttpStatusCode.OK, new { DepStaff = DeptEmployees }));
        }