Commit 2fe27ea4 by guo_minglei@163.com

修改返回参数

parent 43b2890d
......@@ -40,72 +40,72 @@ public class ApiFlowController {
@PostMapping("delete")
@ApiOperation("删除工作流,若当前工作流被依赖则删除失败,只允许删除不被依赖的工作流,当前工作流依赖其他工作流不影响")
public String deleteFlow(String param){
public ResponseResult deleteFlow(String param){
apiFlowService.deleteFlow(param);
return "SUCCESS";
return ResponseResult.ok("SUCCESS");
}
@PostMapping("start")
@ApiOperation("开始工作流的调度,将工作流启用调度")
public String start(String param) throws ParseException {
public ResponseResult start(String param) throws ParseException {
apiFlowService.start(param);
return "SUCCESS";
return ResponseResult.ok("SUCCESS");
}
@PostMapping("repealSchedule")
@ApiOperation("撤销工作流调度,只可以撤销总工作流,若为内嵌工作流不允许撤销")
public String repealSchedule(String param) throws ParseException {
public ResponseResult repealSchedule(String param) throws ParseException {
apiFlowService.repealSchedule(param);
return "SUCCESS";
return ResponseResult.ok("SUCCESS");
}
@PostMapping("killJob")
@ApiOperation("杀死节点")
public Boolean killJob(String param) throws InterruptedException {
public ResponseResult killJob(String param) throws InterruptedException {
Boolean result = flowService.killJob(param);
return result;
return ResponseResult.ok(result);
}
@PostMapping("killFlow")
@ApiOperation("杀死工作流")
public Boolean killFlow(String runId) throws InterruptedException {
public ResponseResult killFlow(String runId) throws InterruptedException {
Boolean result = flowService.killFlow(runId);
return result;
return ResponseResult.ok(result);
}
@PostMapping("stopSchedule")
@ApiOperation("暂停本次调度")
public String stopSchedule(String param){
return apiFlowService.stopSchedule(param);
public ResponseResult stopSchedule(String param){
return ResponseResult.ok(apiFlowService.stopSchedule(param));
}
@PostMapping("reStartSchedule")
@ApiOperation("重新开始某次调度")
public String reStartSchedule(String runIds){
public ResponseResult reStartSchedule(String runIds){
apiFlowService.reStartSchedule(runIds);
return "SUCCESS";
return ResponseResult.ok("SUCCESS");
}
@PostMapping("reRunJob")
@ApiOperation("重跑节点")
public String reRunJob(String param){
public ResponseResult reRunJob(String param){
apiFlowService.reRunJob(param);
return "SUCCESS";
return ResponseResult.ok("SUCCESS");
}
@PostMapping("reRunFlow")
@ApiOperation("重跑工作流")
public String reRunFlow(String param){
public ResponseResult reRunFlow(String param){
apiFlowService.reRunFlow(param);
return "SUCCESS";
return ResponseResult.ok("SUCCESS");
}
@PostMapping("madeSuccess")
@ApiOperation("手动置为成功")
public String madeSuccess(String param){
public ResponseResult madeSuccess(String param){
apiFlowService.madeSuccess(param);
return "SUCCESS";
return ResponseResult.ok("SUCCESS");
}
/**
......@@ -118,9 +118,9 @@ public class ApiFlowController {
*/
@PostMapping("loadScheduleResult")
@ApiOperation("加载运行记录")
public List<RunRecording> loadScheduleResult(String param){
public ResponseResult loadScheduleResult(String param){
List<RunRecording> result = apiFlowService.loadScheduleResult(param);
return result;
return ResponseResult.ok(result);
}
/**
......@@ -130,9 +130,9 @@ public class ApiFlowController {
*/
@PostMapping("loadScheduleLog")
@ApiOperation("加载运行日志")
public RunRecordingVo loadScheduleLog(String param){
public ResponseResult loadScheduleLog(String param){
RunRecordingVo result = apiFlowService.loadScheduleLog(param);
return result;
return ResponseResult.ok(result);
}
......@@ -143,9 +143,9 @@ public class ApiFlowController {
*/
@PostMapping("/repairJob")
@ApiOperation("补批")
public String repairJob(String param){
public ResponseResult repairJob(String param){
apiFlowService.repairJob(param);
return "SUCCESS";
return ResponseResult.ok("SUCCESS");
}
/**
......@@ -155,9 +155,9 @@ public class ApiFlowController {
*/
@PostMapping("/repairFlow")
@ApiOperation("补批工作流")
public String repairFlow(String param){
public ResponseResult repairFlow(String param){
apiFlowService.repairFlow(param);
return "SUCCESS";
return ResponseResult.ok("SUCCESS");
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment