From 1da98c8a8207dd062e433242e1567b6418c6ed81 Mon Sep 17 00:00:00 2001
From: gssong <1742057357@qq.com>
Date: 星期六, 06 四月 2024 11:20:29 +0800
Subject: [PATCH] update 优化表单绑定逻辑,移除流程定义配置表单

---
 ruoyi-modules/ruoyi-workflow/src/main/resources/mapper/workflow/ActTaskMapper.xml |   21 ++++++++++++++-------
 1 files changed, 14 insertions(+), 7 deletions(-)

diff --git a/ruoyi-modules/ruoyi-workflow/src/main/resources/mapper/workflow/ActTaskMapper.xml b/ruoyi-modules/ruoyi-workflow/src/main/resources/mapper/workflow/ActTaskMapper.xml
index 342ce09..d1508ab 100644
--- a/ruoyi-modules/ruoyi-workflow/src/main/resources/mapper/workflow/ActTaskMapper.xml
+++ b/ruoyi-modules/ruoyi-workflow/src/main/resources/mapper/workflow/ActTaskMapper.xml
@@ -19,22 +19,25 @@
         <result property="endTime" column="END_TIME_"/>
         <result property="taskDefinitionKey" column="TASK_DEF_KEY_"/>
         <result property="dueDate" column="DUE_DATE_"/>
-        <result property="processDefinitionKey" column="key_"/>
         <result property="category" column="CATEGORY_"/>
         <result property="parentTaskId" column="PARENT_TASK_ID_"/>
         <result property="tenantId" column="TENANT_ID_"/>
         <result property="claimTime" column="CLAIM_TIME"/>
         <result property="businessStatus" column="BUSINESS_STATUS_"/>
         <result property="processDefinitionName" column="processDefinitionName"/>
-        <result property="processDefinitionKey" column="processDefinitionName"/>
+        <result property="processDefinitionKey" column="processDefinitionKey"/>
+        <result property="processDefinitionVersion" column="processDefinitionVersion"/>
+        <result property="businessKey" column="BUSINESS_KEY_"/>
 
     </resultMap>
     <select id="getTaskWaitByPage" resultMap="TaskVoResult">
         select *
         from (SELECT RES.*,
                      AHP.BUSINESS_STATUS_,
+                     AHP.BUSINESS_KEY_,
                      ARP.NAME_ AS processDefinitionName,
-                     ARP.KEY_  AS processDefinitionKey
+                     ARP.KEY_  AS processDefinitionKey,
+                     ARP.VERSION_  AS processDefinitionVersion
               FROM ACT_RU_TASK RES
                        INNER JOIN ACT_HI_PROCINST AHP ON RES.PROC_INST_ID_ = AHP.PROC_INST_ID_
                        INNER JOIN ACT_RE_PROCDEF ARP ON ARP.ID_ = RES.PROC_DEF_ID_
@@ -46,12 +49,14 @@
         select *
         from (SELECT HTI.*,
                      AHP.BUSINESS_STATUS_,
+                     AHP.BUSINESS_KEY_,
                      ARP.NAME_ AS processDefinitionName,
-                     ARP.KEY_  AS processDefinitionKey
+                     ARP.KEY_  AS processDefinitionKey,
+                     ARP.VERSION_  AS processDefinitionVersion
               FROM ACT_HI_TASKINST HTI
                        INNER JOIN ACT_HI_PROCINST AHP ON HTI.PROC_INST_ID_ = AHP.PROC_INST_ID_
                        INNER JOIN ACT_RE_PROCDEF ARP ON ARP.ID_ = HTI.PROC_DEF_ID_
-              WHERE HTI.PARENT_TASK_ID_ IS NULL
+              WHERE HTI.PARENT_TASK_ID_ IS NULL AND HTI.END_TIME_ IS NOT NULL
               ORDER BY HTI.START_TIME_ DESC) t ${ew.getCustomSqlSegment}
     </select>
 
@@ -59,12 +64,14 @@
         select *
         from (SELECT AHT.*,
                      AHP.BUSINESS_STATUS_,
+                     AHP.BUSINESS_KEY_,
                      ARP.NAME_ as processDefinitionName,
-                     ARP.KEY_  as processDefinitionKey
+                     ARP.KEY_  as processDefinitionKey,
+                     ARP.VERSION_  AS processDefinitionVersion
               FROM ACT_HI_TASKINST AHT
                        INNER JOIN ACT_HI_PROCINST AHP ON AHT.PROC_INST_ID_ = AHP.PROC_INST_ID_
                        INNER JOIN ACT_RE_PROCDEF ARP ON ARP.ID_ = AHT.PROC_DEF_ID_
-              WHERE AHT.PARENT_TASK_ID_ is not null
+              WHERE AHT.PARENT_TASK_ID_ IS NOT NULL
                 and AHT.scope_type_ = 'copy'
               ORDER BY AHT.START_TIME_ DESC) t ${ew.getCustomSqlSegment}
     </select>

--
Gitblit v1.9.3