Example #1
0
 /**
  * 定时任务修改方法
  *
  * @return
  */
 public String save() {
   try {
     HessianResult result = this.qrtzTriggersService.save(job);
     if (!result.getCode().equals("0")) {
       throw new ServiceException(result.getMessage());
     }
   } catch (Exception e) {
     validateInfo.setSuccess(false);
     validateInfo.setMsg(e.getLocalizedMessage());
     e.printStackTrace();
   }
   return "reload";
 }
Example #2
0
 public String removeTrigger() {
   try {
     String jobName = ServletActionContext.getRequest().getParameter("jobName");
     String jobGroup = ServletActionContext.getRequest().getParameter("jobGroup");
     HessianResult result = this.qrtzTriggersService.removeTrigger(jobName, jobGroup);
     if (!result.getCode().equals("0")) {
       throw new ServiceException(result.getMessage());
     }
   } catch (Exception e) {
     validateInfo.setSuccess(false);
     validateInfo.setMsg(e.getLocalizedMessage());
     e.printStackTrace();
   }
   return "reload";
 }