mirror of
https://gitee.com/huangge1199_admin/vue-pro.git
synced 2025-01-19 03:30:06 +08:00
【缺陷修复】BPM:流程重新发起时,禁用业务表单的情况,避免报错
This commit is contained in:
parent
2c429263d0
commit
e3bec2fa3b
@ -77,7 +77,6 @@ public class BpmProcessDefinitionController {
|
|||||||
@GetMapping ("/list")
|
@GetMapping ("/list")
|
||||||
@Operation(summary = "获得流程定义列表")
|
@Operation(summary = "获得流程定义列表")
|
||||||
@Parameter(name = "suspensionState", description = "挂起状态", required = true, example = "1") // 参见 Flowable SuspensionState 枚举
|
@Parameter(name = "suspensionState", description = "挂起状态", required = true, example = "1") // 参见 Flowable SuspensionState 枚举
|
||||||
@PreAuthorize("@ss.hasPermission('bpm:process-definition:query')")
|
|
||||||
public CommonResult<List<BpmProcessDefinitionRespVO>> getProcessDefinitionList(
|
public CommonResult<List<BpmProcessDefinitionRespVO>> getProcessDefinitionList(
|
||||||
@RequestParam("suspensionState") Integer suspensionState) {
|
@RequestParam("suspensionState") Integer suspensionState) {
|
||||||
List<ProcessDefinition> list = processDefinitionService.getProcessDefinitionListBySuspensionState(suspensionState);
|
List<ProcessDefinition> list = processDefinitionService.getProcessDefinitionListBySuspensionState(suspensionState);
|
||||||
@ -96,7 +95,6 @@ public class BpmProcessDefinitionController {
|
|||||||
@Operation(summary = "获得流程定义")
|
@Operation(summary = "获得流程定义")
|
||||||
@Parameter(name = "id", description = "流程编号", required = true, example = "1024")
|
@Parameter(name = "id", description = "流程编号", required = true, example = "1024")
|
||||||
@Parameter(name = "key", description = "流程定义标识", required = true, example = "1024")
|
@Parameter(name = "key", description = "流程定义标识", required = true, example = "1024")
|
||||||
@PreAuthorize("@ss.hasPermission('bpm:process-definition:query')")
|
|
||||||
public CommonResult<BpmProcessDefinitionRespVO> getProcessDefinition(
|
public CommonResult<BpmProcessDefinitionRespVO> getProcessDefinition(
|
||||||
@RequestParam(value = "id", required = false) String id,
|
@RequestParam(value = "id", required = false) String id,
|
||||||
@RequestParam(value = "key", required = false) String key) {
|
@RequestParam(value = "key", required = false) String key) {
|
||||||
@ -105,10 +103,11 @@ public class BpmProcessDefinitionController {
|
|||||||
if (processDefinition == null) {
|
if (processDefinition == null) {
|
||||||
return success(null);
|
return success(null);
|
||||||
}
|
}
|
||||||
|
BpmProcessDefinitionInfoDO processDefinitionInfo = processDefinitionService.getProcessDefinitionInfo(processDefinition.getId());
|
||||||
BpmnModel bpmnModel = processDefinitionService.getProcessDefinitionBpmnModel(processDefinition.getId());
|
BpmnModel bpmnModel = processDefinitionService.getProcessDefinitionBpmnModel(processDefinition.getId());
|
||||||
List<UserTask> userTaskList = BpmTaskCandidateStartUserSelectStrategy.getStartUserSelectUserTaskList(bpmnModel);
|
List<UserTask> userTaskList = BpmTaskCandidateStartUserSelectStrategy.getStartUserSelectUserTaskList(bpmnModel);
|
||||||
return success(BpmProcessDefinitionConvert.INSTANCE.buildProcessDefinition(
|
return success(BpmProcessDefinitionConvert.INSTANCE.buildProcessDefinition(
|
||||||
processDefinition, null, null, null, null, bpmnModel, userTaskList));
|
processDefinition, null, processDefinitionInfo, null, null, bpmnModel, userTaskList));
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -47,7 +47,8 @@ public interface BpmProcessInstanceConvert {
|
|||||||
BpmProcessInstanceRespVO respVO = vpPageResult.getList().get(i);
|
BpmProcessInstanceRespVO respVO = vpPageResult.getList().get(i);
|
||||||
respVO.setStatus(FlowableUtils.getProcessInstanceStatus(pageResult.getList().get(i)));
|
respVO.setStatus(FlowableUtils.getProcessInstanceStatus(pageResult.getList().get(i)));
|
||||||
MapUtils.findAndThen(processDefinitionMap, respVO.getProcessDefinitionId(),
|
MapUtils.findAndThen(processDefinitionMap, respVO.getProcessDefinitionId(),
|
||||||
processDefinition -> respVO.setCategory(processDefinition.getCategory()));
|
processDefinition -> respVO.setCategory(processDefinition.getCategory())
|
||||||
|
.setProcessDefinition(BeanUtils.toBean(processDefinition, BpmProcessDefinitionRespVO.class)));
|
||||||
MapUtils.findAndThen(categoryMap, respVO.getCategory(), category -> respVO.setCategoryName(category.getName()));
|
MapUtils.findAndThen(categoryMap, respVO.getCategory(), category -> respVO.setCategoryName(category.getName()));
|
||||||
respVO.setTasks(BeanUtils.toBean(taskMap.get(respVO.getId()), BpmProcessInstanceRespVO.Task.class));
|
respVO.setTasks(BeanUtils.toBean(taskMap.get(respVO.getId()), BpmProcessInstanceRespVO.Task.class));
|
||||||
// user
|
// user
|
||||||
|
Loading…
Reference in New Issue
Block a user