| | |
| | | private XxlJobGroupDao xxlJobGroupDao; |
| | | @Resource |
| | | private XxlJobService xxlJobService; |
| | | |
| | | |
| | | @RequestMapping |
| | | public String index(HttpServletRequest request, Model model, @RequestParam(required = false, defaultValue = "-1") int jobGroup) { |
| | | |
| | |
| | | throw new RuntimeException(I18nUtil.getString("system_permission_limit") + "[username="+ loginUser.getUsername() +"]"); |
| | | } |
| | | } |
| | | |
| | | |
| | | @RequestMapping("/pageList") |
| | | @ResponseBody |
| | | public Map<String, Object> pageList(@RequestParam(required = false, defaultValue = "0") int start, |
| | | public Map<String, Object> pageList(@RequestParam(required = false, defaultValue = "0") int start, |
| | | @RequestParam(required = false, defaultValue = "10") int length, |
| | | int jobGroup, int triggerStatus, String jobDesc, String executorHandler, String author) { |
| | | |
| | | |
| | | return xxlJobService.pageList(start, length, jobGroup, triggerStatus, jobDesc, executorHandler, author); |
| | | } |
| | | |
| | | |
| | | @RequestMapping("/add") |
| | | @ResponseBody |
| | | public ReturnT<String> add(XxlJobInfo jobInfo) { |
| | | return xxlJobService.add(jobInfo); |
| | | } |
| | | |
| | | |
| | | @RequestMapping("/update") |
| | | @ResponseBody |
| | | public ReturnT<String> update(XxlJobInfo jobInfo) { |
| | | return xxlJobService.update(jobInfo); |
| | | } |
| | | |
| | | |
| | | @RequestMapping("/remove") |
| | | @ResponseBody |
| | | public ReturnT<String> remove(int id) { |
| | | return xxlJobService.remove(id); |
| | | } |
| | | |
| | | |
| | | @RequestMapping("/stop") |
| | | @ResponseBody |
| | | public ReturnT<String> pause(int id) { |
| | | return xxlJobService.stop(id); |
| | | } |
| | | |
| | | |
| | | @RequestMapping("/start") |
| | | @ResponseBody |
| | | public ReturnT<String> start(int id) { |
| | | return xxlJobService.start(id); |
| | | } |
| | | |
| | | |
| | | @RequestMapping("/trigger") |
| | | @ResponseBody |
| | | //@PermissionLimit(limit = false) |
| | |
| | | } |
| | | return new ReturnT<List<String>>(result); |
| | | } |
| | | |
| | | |
| | | } |