Merge branch 'master' into docker_package
This commit is contained in:
commit
419d5aa258
|
@ -209,13 +209,14 @@ public class CorrectionListenerV3 implements TaskListener, ExecutionListener, Ac
|
|||
|
||||
private void mpComplete(List<TAbilityApplicationDTO> abilityApplicationDTO, DelegateTask delegateTask, final String assignee) { // 处理免批或申请人为资源提供方部门审批人
|
||||
Optional<TAbilityApplicationDTO> abilityApplicationDTOOptional = abilityApplicationDTO.stream().findAny();
|
||||
abilityApplicationDTOOptional.ifPresent(index -> {
|
||||
if (abilityApplicationDTOOptional.isPresent()) {
|
||||
if (abilityApplicationDTOOptional.get().getUserId().equals(delegateTask.getAssignee())) {
|
||||
taskService.addComment(delegateTask.getId(), delegateTask.getProcessInstanceId(), "申请人为资源提供方部门审批人,默认通过");
|
||||
taskService.complete(delegateTask.getId(), delegateTask.getVariables());
|
||||
return;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
if (StringUtils.isNotEmpty(assignee)
|
||||
&& StringUtils.isNotEmpty(delegateTask.getVariable("creator", String.class))
|
||||
&& delegateTask.getVariable("creator", String.class).equals(assignee)) {
|
||||
|
@ -227,9 +228,9 @@ public class CorrectionListenerV3 implements TaskListener, ExecutionListener, Ac
|
|||
return;
|
||||
}
|
||||
|
||||
List<HistoricActivityInstance> historicActivityInstanceList=historyService.createHistoricActivityInstanceQuery().processInstanceId(delegateTask.getProcessInstanceId())
|
||||
List<HistoricActivityInstance> historicActivityInstanceList = historyService.createHistoricActivityInstanceQuery().processInstanceId(delegateTask.getProcessInstanceId())
|
||||
.activityType("userTask").unfinished().orderByHistoricActivityInstanceEndTime().desc().list();
|
||||
if(!historicActivityInstanceList.isEmpty() && historicActivityInstanceList.get(0).getAssignee().equals(assignee)){
|
||||
if (!historicActivityInstanceList.isEmpty() && historicActivityInstanceList.get(0).getAssignee().equals(assignee)) {
|
||||
taskService.addComment(delegateTask.getId(), delegateTask.getProcessInstanceId(), "审批人重复,默认通过");
|
||||
taskService.setVariable(delegateTask.getId(), ActTaskService.Task_HANDLE_STATE, ActTaskService.Task_HANDLE_STATE_AGREE);
|
||||
taskService.setVariable(delegateTask.getId(), "backToFirst", Boolean.FALSE);
|
||||
|
|
Loading…
Reference in New Issue