From 15191eef4bbd422af3363ad2cb9cb1e891580d90 Mon Sep 17 00:00:00 2001 From: new_new_new <8454518+new-twice@user.noreply.gitee.com> Date: Tue, 9 Jun 2026 09:22:34 +0000 Subject: [PATCH] =?UTF-8?q?!38=20feat(inspectimprove):=20=E6=96=B0?= =?UTF-8?q?=E5=A2=9E=E8=8E=B7=E5=8F=96=E5=85=9A=E7=BE=A4=E9=A2=86=E5=AF=BC?= =?UTF-8?q?=E6=B5=81=E7=A8=8B=E8=A1=A8=E8=BE=BE=E5=BC=8F=E6=96=B9=E6=B3=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * feat(inspectimprove): 新增获取党群领导流程表达式方法 * feat(inspectimprove): 新增领导审批判断及审批用户流程表达式方法 --- .../jeecg/inspectimprove/InspectConstant.java | 2 ++ .../inspectimprove/InspectImproveFlow.java | 28 +++++++++++++++++++ 2 files changed, 30 insertions(+) diff --git a/jeecg-boot-module/jeecg-module-flow/src/main/java/org/jeecg/inspectimprove/InspectConstant.java b/jeecg-boot-module/jeecg-module-flow/src/main/java/org/jeecg/inspectimprove/InspectConstant.java index 1e1ea12..86afbd7 100644 --- a/jeecg-boot-module/jeecg-module-flow/src/main/java/org/jeecg/inspectimprove/InspectConstant.java +++ b/jeecg-boot-module/jeecg-module-flow/src/main/java/org/jeecg/inspectimprove/InspectConstant.java @@ -11,5 +11,7 @@ public class InspectConstant { public static final String SUB_APPROVE_USER_KEY = "sub_approve_user"; public static final String SLD_DEPT_ID = "2044677562460508161"; public static final String SDWSJ_ROLE_ID = "2062796937607499777"; + public static final String IS_NEED_LEADER_APPROVE_KEY = "is_need_leader_approve"; + public static final String LEADER_APPROVE_USER_KEY = "leader_approve_user"; public static final int ZERO_INDEX = 0; } diff --git a/jeecg-boot-module/jeecg-module-flow/src/main/java/org/jeecg/inspectimprove/InspectImproveFlow.java b/jeecg-boot-module/jeecg-module-flow/src/main/java/org/jeecg/inspectimprove/InspectImproveFlow.java index 97cd0a4..e188630 100644 --- a/jeecg-boot-module/jeecg-module-flow/src/main/java/org/jeecg/inspectimprove/InspectImproveFlow.java +++ b/jeecg-boot-module/jeecg-module-flow/src/main/java/org/jeecg/inspectimprove/InspectImproveFlow.java @@ -168,12 +168,26 @@ public class InspectImproveFlow { return this.getImplDeptLeaderList(execution).size(); } + // 流程表达式内用法:${inspectImproveFlow.getIsEnd(execution)} public String getIsEnd(DelegateExecution execution) { Object value = runtimeService.getVariable(execution.getProcessInstanceId(), InspectConstant.IS_END_KEY); return value != null ? value.toString() : null; } + // 流程表达式内用法:${inspectImproveFlow.getIsNeedLeaderApprove(execution)} + public String getIsNeedLeaderApprove(DelegateExecution execution) { + Object value = runtimeService.getVariable(execution.getProcessInstanceId(), InspectConstant.IS_NEED_LEADER_APPROVE_KEY); + return value != null ? value.toString() : null; + } + + // 流程表达式内用法:${inspectImproveFlow.getLeaderApproveUser(execution)} + public String getLeaderApproveUser(DelegateExecution execution) { + Object value = runtimeService.getVariable(execution.getProcessInstanceId(), InspectConstant.LEADER_APPROVE_USER_KEY); + return value != null ? value.toString() : null; + } + + // 流程表达式内用法:${inspectImproveFlow.getSubApproveUser(execution)} public String getSubApproveUser(DelegateExecution execution) { Object value = runtimeService.getVariable(execution.getProcessInstanceId(), InspectConstant.SUB_APPROVE_USER_KEY); @@ -207,6 +221,20 @@ public class InspectImproveFlow { return sldUserStr; } + // 流程表达式内用法:${inspectImproveFlow.getDqLeader(execution)} + public String getDqLeader(DelegateExecution execution) { + DqInspectTask tempDqInspectTask = this.getDqInspectTask(execution); + if (tempDqInspectTask == null) { + log.error("【巡视整改-流程表达式】未获取到巡视整改任务, businessKey: {}", execution.getProcessInstanceBusinessKey()); + return null; + } + String supDeptLeader = tempDqInspectTask.getSupDeptleaderid(); + if (StringUtils.isBlank(supDeptLeader)) { + log.error("【巡视整改-流程表达式】未获取到党群领导, businessKey: {}", execution.getProcessInstanceBusinessKey()); + return null; + } + return supDeptLeader; + } private DqInspectTask getDqInspectTask(DelegateExecution execution) {