//[HttpPost] //public ActionResult ViewInformation(int departmentId) //{ // ViewStatisticsManager aViewStatisticsManager=new ViewStatisticsManager(); // List<CourseStatisticsViewModel> aCourseStatisticsViewModels= aViewStatisticsManager.GetAllInformation(); // ViewBag.Information = aCourseStatisticsViewModels; // return View(); //} public JsonResult GetAllInformation(int departmentId) { ViewStatisticsManager aViewStatisticsManager = new ViewStatisticsManager(); List <CourseStatisticsViewModel> aCourseStatisticsViewModels = aViewStatisticsManager.GetAllInformation(departmentId); return(Json(aCourseStatisticsViewModels)); }
public ActionResult ViewInformation(CourseStatisticsViewModel aCourseStatisticsViewModel) { ViewStatisticsManager aViewStatisticsManager = new ViewStatisticsManager(); ViewBag.Departments = aViewStatisticsManager.GetAllDepartments(); return(View()); }