@ResponseBody @RequestMapping( value = "/getAllTeachersForSelect", method = {RequestMethod.GET, RequestMethod.POST}) public List<TeacherListModel> getAllTeachersForSelect(HttpServletRequest request) { return studentWillService.findTeachersForList(); }
@ResponseBody @RequestMapping( value = "/showOneTeacherDetail", method = {RequestMethod.GET}) public TeacherDetail showOneTeacherDetail(String teacherId) { return studentWillService.findOneTeacherDetailByTeacherIdInTeacherDetail( Integer.parseInt(teacherId)); }
@ResponseBody @RequestMapping( value = "/getPreviousSelection", method = {RequestMethod.GET}) public HashMap<String, String> getPreviousSelection(HttpServletRequest request) { int studentId = ((User) (request.getSession().getAttribute("USER"))).getId(); HashMap<String, String> returnMap = studentWillService.findPreviousWillsInHashMap(studentId); return CollectionUtils.isEmpty(returnMap) ? new HashMap<String, String>() : returnMap; }
@ResponseBody @RequestMapping( value = "/getTeachersInDatagrid", method = {RequestMethod.GET, RequestMethod.POST}) public GenericDataGrid<TeacherListModel> getTeachersInDatagrid(HttpServletRequest request) { PaginationAndSortModel pam = new PaginationAndSortModel(request); GenericDataGrid<TeacherListModel> s = studentWillService.findTeachersForPagingInGenericDataGrid(pam); return s; }
@ResponseBody @RequestMapping( value = "/saveSelection", method = {RequestMethod.POST}) public BasicJson saveSelection(@ModelAttribute WillModel willModel, HttpServletRequest request) { User student = ((User) (request.getSession().getAttribute("USER"))); willModel.setStudentAccount(student.getAccount()); willModel.setStudentId(student.getId() + ""); willModel.setStudentName(student.getName()); studentWillService.updateSelection(willModel); return new BasicJson(true, "已经更新您的志愿", null); }
@ResponseBody @RequestMapping( value = "/getTeacherActionEventsInDatagrid", method = {RequestMethod.GET, RequestMethod.POST}) public GenericDataGrid<ActionEventListModel> getTeacherActionEventsInDatagrid( String teacherId, HttpServletRequest request) { PaginationAndSortModel pam = new PaginationAndSortModel(request); GenericDataGrid<ActionEventListModel> s = studentWillService.findTeachersActionEventsForPagingInGenericDataGrid( Integer.parseInt(teacherId), ((User) request.getSession().getAttribute("USER")).getId(), pam); return s; }