feat(REQ-4100) - 支撑业务节点操作回退
This commit is contained in:
parent
7d6e64f337
commit
2b83b07774
@ -109,7 +109,7 @@ public class BpmnProcessTaskController extends BasicPopulateAvatarController imp
|
|||||||
if (!StringUtils.hasText(dto.getProcessInstanceId()) && !StringUtils.hasText(dto.getTaskId())) {
|
if (!StringUtils.hasText(dto.getProcessInstanceId()) && !StringUtils.hasText(dto.getTaskId())) {
|
||||||
throw new WorkflowEngineException(TASK_OPERATION_PARAM_INVALID);
|
throw new WorkflowEngineException(TASK_OPERATION_PARAM_INVALID);
|
||||||
}
|
}
|
||||||
if(!StringUtils.hasText(dto.getTaskId())) {
|
if (!StringUtils.hasText(dto.getTaskId())) {
|
||||||
dto.setTaskId(bpmnProcessTaskService.findTaskIdByInstanceIdAndPersonId(dto.getProcessInstanceId(), dto.getApprover().getPersonId()));
|
dto.setTaskId(bpmnProcessTaskService.findTaskIdByInstanceIdAndPersonId(dto.getProcessInstanceId(), dto.getApprover().getPersonId()));
|
||||||
}
|
}
|
||||||
List<AttachmentDTO> tempAttachments = ListUtils.defaultIfNull(dto.getAttachmentList(), new ArrayList<>());
|
List<AttachmentDTO> tempAttachments = ListUtils.defaultIfNull(dto.getAttachmentList(), new ArrayList<>());
|
||||||
@ -135,7 +135,7 @@ public class BpmnProcessTaskController extends BasicPopulateAvatarController imp
|
|||||||
if (!StringUtils.hasText(dto.getProcessInstanceId()) && !StringUtils.hasText(dto.getTaskId())) {
|
if (!StringUtils.hasText(dto.getProcessInstanceId()) && !StringUtils.hasText(dto.getTaskId())) {
|
||||||
throw new WorkflowEngineException(TASK_OPERATION_PARAM_INVALID);
|
throw new WorkflowEngineException(TASK_OPERATION_PARAM_INVALID);
|
||||||
}
|
}
|
||||||
if(!StringUtils.hasText(dto.getTaskId())) {
|
if (!StringUtils.hasText(dto.getTaskId())) {
|
||||||
dto.setTaskId(bpmnProcessTaskService.findTaskIdByInstanceIdAndPersonId(dto.getProcessInstanceId(), dto.getApprover().getPersonId()));
|
dto.setTaskId(bpmnProcessTaskService.findTaskIdByInstanceIdAndPersonId(dto.getProcessInstanceId(), dto.getApprover().getPersonId()));
|
||||||
}
|
}
|
||||||
List<AttachmentDTO> tempAttachments = ListUtils.defaultIfNull(dto.getAttachmentList(), new ArrayList<>());
|
List<AttachmentDTO> tempAttachments = ListUtils.defaultIfNull(dto.getAttachmentList(), new ArrayList<>());
|
||||||
@ -196,7 +196,7 @@ public class BpmnProcessTaskController extends BasicPopulateAvatarController imp
|
|||||||
if (!StringUtils.hasText(dto.getProcessInstanceId()) && !StringUtils.hasText(dto.getTaskId())) {
|
if (!StringUtils.hasText(dto.getProcessInstanceId()) && !StringUtils.hasText(dto.getTaskId())) {
|
||||||
throw new WorkflowEngineException(TASK_OPERATION_PARAM_INVALID);
|
throw new WorkflowEngineException(TASK_OPERATION_PARAM_INVALID);
|
||||||
}
|
}
|
||||||
if(!StringUtils.hasText(dto.getTaskId())) {
|
if (!StringUtils.hasText(dto.getTaskId()) && StringUtils.hasText(dto.getApprover().getPersonId())) {
|
||||||
dto.setTaskId(bpmnProcessTaskService.findTaskIdByInstanceIdAndPersonId(dto.getProcessInstanceId(), dto.getApprover().getPersonId()));
|
dto.setTaskId(bpmnProcessTaskService.findTaskIdByInstanceIdAndPersonId(dto.getProcessInstanceId(), dto.getApprover().getPersonId()));
|
||||||
}
|
}
|
||||||
populateUsersAvatar(dto.getApprover());
|
populateUsersAvatar(dto.getApprover());
|
||||||
@ -229,7 +229,7 @@ public class BpmnProcessTaskController extends BasicPopulateAvatarController imp
|
|||||||
if (!StringUtils.hasText(dto.getProcessInstanceId()) && !StringUtils.hasText(dto.getTaskId())) {
|
if (!StringUtils.hasText(dto.getProcessInstanceId()) && !StringUtils.hasText(dto.getTaskId())) {
|
||||||
throw new WorkflowEngineException(TASK_OPERATION_PARAM_INVALID);
|
throw new WorkflowEngineException(TASK_OPERATION_PARAM_INVALID);
|
||||||
}
|
}
|
||||||
if(!StringUtils.hasText(dto.getTaskId())) {
|
if (!StringUtils.hasText(dto.getTaskId())) {
|
||||||
dto.setTaskId(bpmnProcessTaskService.findTaskIdByInstanceIdAndPersonId(dto.getProcessInstanceId(), dto.getApprover().getPersonId()));
|
dto.setTaskId(bpmnProcessTaskService.findTaskIdByInstanceIdAndPersonId(dto.getProcessInstanceId(), dto.getApprover().getPersonId()));
|
||||||
}
|
}
|
||||||
populateUsersAvatar(dto.getApprover());
|
populateUsersAvatar(dto.getApprover());
|
||||||
@ -263,7 +263,7 @@ public class BpmnProcessTaskController extends BasicPopulateAvatarController imp
|
|||||||
if (!StringUtils.hasText(dto.getProcessInstanceId()) && !StringUtils.hasText(dto.getTaskId())) {
|
if (!StringUtils.hasText(dto.getProcessInstanceId()) && !StringUtils.hasText(dto.getTaskId())) {
|
||||||
throw new WorkflowEngineException(TASK_OPERATION_PARAM_INVALID);
|
throw new WorkflowEngineException(TASK_OPERATION_PARAM_INVALID);
|
||||||
}
|
}
|
||||||
if(!StringUtils.hasText(dto.getTaskId())) {
|
if (!StringUtils.hasText(dto.getTaskId())) {
|
||||||
dto.setTaskId(bpmnProcessTaskService.findTaskIdByInstanceIdAndPersonId(dto.getProcessInstanceId(), dto.getOriginAssigner().getPersonId()));
|
dto.setTaskId(bpmnProcessTaskService.findTaskIdByInstanceIdAndPersonId(dto.getProcessInstanceId(), dto.getOriginAssigner().getPersonId()));
|
||||||
}
|
}
|
||||||
// 填充头像
|
// 填充头像
|
||||||
@ -310,7 +310,7 @@ public class BpmnProcessTaskController extends BasicPopulateAvatarController imp
|
|||||||
if (!StringUtils.hasText(dto.getProcessInstanceId()) && !StringUtils.hasText(dto.getTaskId())) {
|
if (!StringUtils.hasText(dto.getProcessInstanceId()) && !StringUtils.hasText(dto.getTaskId())) {
|
||||||
throw new WorkflowEngineException(TASK_OPERATION_PARAM_INVALID);
|
throw new WorkflowEngineException(TASK_OPERATION_PARAM_INVALID);
|
||||||
}
|
}
|
||||||
if(!StringUtils.hasText(dto.getTaskId())) {
|
if (!StringUtils.hasText(dto.getTaskId())) {
|
||||||
dto.setTaskId(bpmnProcessTaskService.findTaskIdByInstanceIdAndPersonId(dto.getProcessInstanceId(), dto.getOriginAssigner().getPersonId()));
|
dto.setTaskId(bpmnProcessTaskService.findTaskIdByInstanceIdAndPersonId(dto.getProcessInstanceId(), dto.getOriginAssigner().getPersonId()));
|
||||||
}
|
}
|
||||||
// 填充头像
|
// 填充头像
|
||||||
@ -334,7 +334,7 @@ public class BpmnProcessTaskController extends BasicPopulateAvatarController imp
|
|||||||
if (!StringUtils.hasText(dto.getProcessInstanceId()) && !StringUtils.hasText(dto.getTaskId())) {
|
if (!StringUtils.hasText(dto.getProcessInstanceId()) && !StringUtils.hasText(dto.getTaskId())) {
|
||||||
throw new WorkflowEngineException(TASK_OPERATION_PARAM_INVALID);
|
throw new WorkflowEngineException(TASK_OPERATION_PARAM_INVALID);
|
||||||
}
|
}
|
||||||
if(!StringUtils.hasText(dto.getTaskId())) {
|
if (!StringUtils.hasText(dto.getTaskId())) {
|
||||||
dto.setTaskId(bpmnProcessTaskService.findTaskIdByInstanceIdAndPersonId(dto.getProcessInstanceId(), dto.getOriginAssigner().getPersonId()));
|
dto.setTaskId(bpmnProcessTaskService.findTaskIdByInstanceIdAndPersonId(dto.getProcessInstanceId(), dto.getOriginAssigner().getPersonId()));
|
||||||
}
|
}
|
||||||
populateUsersAvatar(dto.getOriginAssigner());
|
populateUsersAvatar(dto.getOriginAssigner());
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user