public ActionResult CLassroomAllocation(ClassAllocation aClassAllocation) { DepartmentManager aDepartmentManager = new DepartmentManager(); CourseManager aCourseManager = new CourseManager(); RoomManager aRoomManager = new RoomManager(); DayManager aDayManager = new DayManager(); ViewBag.departments = aDepartmentManager.GetAllDepartmentInfo(); ViewBag.courses = aCourseManager.GetAllCourse(); ViewBag.rooms = aRoomManager.GetAllRoom(); ViewBag.days = aDayManager.GetAllDay(); ClassAllocationManager aClassAllocationManager = new ClassAllocationManager(); List <ClassAllocation> alist = aClassAllocationManager.GetAllocatedClassInfo(); if (aClassAllocationManager.CLassroomAllocation(aClassAllocation) > 0) { ViewBag.message = "Classrooms are Successfully allocated"; } else { ViewBag.message = "Allocation Failed"; } return(View()); }
// // GET: /ClassAllocate/ public ActionResult CLassroomAllocation() { DepartmentManager aDepartmentManager = new DepartmentManager(); //CourseManager aCourseManager = new CourseManager(); RoomManager aRoomManager = new RoomManager(); DayManager aDayManager = new DayManager(); ViewBag.departments = aDepartmentManager.GetAllDepartmentInfo(); ViewBag.courses = aCourseManager.GetAllCourse(); ViewBag.rooms = aRoomManager.GetAllRoom(); ViewBag.days = aDayManager.GetAllDay(); return(View()); }
private List <Day> GetAllDay() { var dayList = dayManager.GetAllDay(); return(dayList); }