Merge branch 'dev'

This commit is contained in:
wangliwen 2022-10-20 15:16:13 +08:00
commit a39f5c84c3
7 changed files with 19 additions and 1 deletions

View File

@ -362,6 +362,7 @@ public class ActivitiNoticeAspect {
LOGGER.error("------------自动审批通过,不通知------------");
return;
}
Boolean allowEntrust = Boolean.valueOf(kv.get("allowEntrust") != null ? kv.get("allowEntrust").toString() : Boolean.FALSE.toString()); // 允许被委托他人(特殊通知)
String key = null;
if (kv.containsKey("id")) {
key = kv.getOrDefault("id", "").toString();
@ -440,7 +441,14 @@ public class ActivitiNoticeAspect {
try {
SysUserDTO owner = sysUserService.get(Long.valueOf(finalCreator));
String content = "【通知】" + owner.getRealName() + "发起的流程" + resourceName + activitiNoticeOperation.process() + " 已进入审核节点:" + activitiNoticeOperation.value() + ";当前审核人指派为您";
String content = "【通知】" + owner.getRealName() + "发起的流程" + resourceName + activitiNoticeOperation.process() +
" 已进入审核节点:" + activitiNoticeOperation.value() +
";当前审核人指派为您";
if (allowEntrust) {
content = "【通知】" + owner.getRealName() + "发起的流程" + resourceName + activitiNoticeOperation.process() +
" 已进入审核节点:" + activitiNoticeOperation.value() +
";因无法分配到审核人,故当前审核人指派为您";
}
Integer type = 10;
if ("能力申请流程".equals(activitiNoticeOperation.process())) {
type = 1;

View File

@ -47,4 +47,9 @@ public class AuditingBaseDTO implements Serializable {
*/
private String flowType = null;
/**
* 允许被委托他人(特殊通知)
*/
private Boolean allowEntrust = null;
}

View File

@ -129,6 +129,7 @@ public class ApplyDeptListener implements TaskListener, ExecutionListener, Activ
} else {
logger.error("未查到 {} 对应 " + roleName, deptDTO.getName());
taskService.setAssignee(delegateTask.getId(), defaultAssigneeRoleId);
taskService.setVariable(delegateTask.getId(), "allowEntrust", Boolean.TRUE); // 允许被委托
assignee = defaultAssigneeRoleId;
}

View File

@ -111,6 +111,7 @@ public class ApplyDistrictListener implements TaskListener, ExecutionListener, A
} else {
logger.error("未查到 {} 对应 " + roleName, deptDTO.getName());
taskService.setAssignee(delegateTask.getId(), defaultAssigneeRoleId);
taskService.setVariable(delegateTask.getId(), "allowEntrust", Boolean.TRUE); // 允许被委托
assignee = defaultAssigneeRoleId;
}
mpComplete(delegateTask, assignee);

View File

@ -112,6 +112,7 @@ public class CityListener implements TaskListener, ExecutionListener, ActivitiEv
} else {
logger.error("未查到 {} 对应 " + roleName, deptDTO.getName());
taskService.setAssignee(delegateTask.getId(), defaultAssigneeRoleId);
taskService.setVariable(delegateTask.getId(), "allowEntrust", Boolean.TRUE); // 允许被委托
assignee = defaultAssigneeRoleId;
}
mpComplete(delegateTask, assignee);

View File

@ -196,6 +196,7 @@ public class CorrectionListenerV3 implements TaskListener, ExecutionListener, Ac
} else {
logger.error("未查到该部门 {} 对应的 {}", deptId, roleName);
taskService.setAssignee(delegateTask.getId(), defaultAssigneeRoleId);
taskService.setVariable(delegateTask.getId(), "allowEntrust", Boolean.TRUE); // 允许被委托
assignee = defaultAssigneeRoleId;
}
if (kv.containsKey("tAbilityApplicationDTOList")) {

View File

@ -108,6 +108,7 @@ public class OwnerDistrictListener implements TaskListener, ExecutionListener, A
} else {
logger.error("未查到 {} 对应 " + roleName, deptDTO.getName());
taskService.setAssignee(delegateTask.getId(), defaultAssigneeRoleId);
taskService.setVariable(delegateTask.getId(), "allowEntrust", Boolean.TRUE); // 允许被委托
assignee = defaultAssigneeRoleId;
}
mpComplete(delegateTask, assignee);