update 优化激活/挂起取反逻辑
This commit is contained in:
parent
c1a22ed0cd
commit
189845dc4a
@ -178,7 +178,7 @@ public class FlwDefinitionController extends BaseController {
|
|||||||
*/
|
*/
|
||||||
@PutMapping("/active/{id}")
|
@PutMapping("/active/{id}")
|
||||||
public R<Boolean> active(@PathVariable Long id, @RequestParam boolean active) {
|
public R<Boolean> active(@PathVariable Long id, @RequestParam boolean active) {
|
||||||
return R.ok(active ? defService.unActive(id) : defService.active(id));
|
return R.ok(active ? defService.active(id) : defService.unActive(id));
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -31,7 +31,6 @@ import java.util.Map;
|
|||||||
@RestController
|
@RestController
|
||||||
@RequestMapping("/workflow/instance")
|
@RequestMapping("/workflow/instance")
|
||||||
public class FlwInstanceController extends BaseController {
|
public class FlwInstanceController extends BaseController {
|
||||||
|
|
||||||
private final IFlwInstanceService flwInstanceService;
|
private final IFlwInstanceService flwInstanceService;
|
||||||
private final InsService insService;
|
private final InsService insService;
|
||||||
|
|
||||||
@ -88,20 +87,15 @@ public class FlwInstanceController extends BaseController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 激活/挂起流程定义
|
* 激活/挂起流程实例
|
||||||
*
|
*
|
||||||
* @param id 流程定义id
|
* @param id 流程实例id
|
||||||
* @param active 激活/挂起
|
* @param active 激活/挂起
|
||||||
*/
|
*/
|
||||||
@PutMapping("/active/{id}")
|
@PutMapping("/active/{id}")
|
||||||
public R<Boolean> active(@PathVariable Long id, @RequestParam boolean active) {
|
public R<Boolean> active(@PathVariable Long id, @RequestParam boolean active) {
|
||||||
if (active) {
|
return R.ok(active ? insService.active(id) : insService.unActive(id));
|
||||||
return R.ok(insService.unActive(id));
|
|
||||||
} else {
|
|
||||||
return R.ok(insService.active(id));
|
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 获取当前登陆人发起的流程实例
|
* 获取当前登陆人发起的流程实例
|
||||||
@ -114,7 +108,6 @@ public class FlwInstanceController extends BaseController {
|
|||||||
return flwInstanceService.pageByCurrent(flowInstanceBo, pageQuery);
|
return flwInstanceService.pageByCurrent(flowInstanceBo, pageQuery);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 获取流程图,流程记录
|
* 获取流程图,流程记录
|
||||||
*
|
*
|
||||||
|
Loading…
x
Reference in New Issue
Block a user