예제 #1
0
 @RequestMapping(value = "edit", method = RequestMethod.GET)
 public ModelAndView edit(
     @ModelAttribute(value = "Schedule") Schedule schedule, @Context HttpServletRequest request) {
   ModelAndView mv = null;
   int id = Integer.parseInt(request.getParameter("id"));
   Schedule sch = scheduleService.getByScheduleId(id);
   if (sch != null) {
     mv = new ModelAndView("adminSchedule/edit");
     mv.addObject("schedule", sch);
     mv.addObject("applicant", applicantService.getByApplicantId(sch.getApplicantId()));
     mv.addObject("applicants", applicantService.getAll());
     mv.addObject("role", roleService.getByRoleId(sch.getInterviewer()));
     mv.addObject("roles", roleService.getAll());
   }
   return mv;
 }
예제 #2
0
 @RequestMapping(value = "detail/{id}", method = RequestMethod.GET)
 public ModelAndView detail(@PathVariable(value = "id") int id) {
   ModelAndView mv = new ModelAndView("adminSchedule/detail");
   mv.addObject("sch", scheduleService.getByScheduleId(id));
   return mv;
 }