From ba5210dc8c6c537cacc59c18d58baa9744cd2b9d Mon Sep 17 00:00:00 2001
From: wuxw <928255095@qq.com>
Date: 星期二, 10 五月 2022 11:14:39 +0800
Subject: [PATCH] 优化报修单推送bug

---
 java110-db/src/main/resources/mapper/common/WorkflowServiceDaoImplMapper.xml |   24 ++++++++++++++++++++----
 1 files changed, 20 insertions(+), 4 deletions(-)

diff --git a/java110-db/src/main/resources/mapper/common/WorkflowServiceDaoImplMapper.xml b/java110-db/src/main/resources/mapper/common/WorkflowServiceDaoImplMapper.xml
old mode 100644
new mode 100755
index c99855c..44d7b63
--- a/java110-db/src/main/resources/mapper/common/WorkflowServiceDaoImplMapper.xml
+++ b/java110-db/src/main/resources/mapper/common/WorkflowServiceDaoImplMapper.xml
@@ -34,7 +34,7 @@
             and t.b_id= #{bId}
         </if>
         <if test="communityId !=null and communityId != ''">
-            and t.community_id= #{communityId}
+            and t.community_id in (#{communityId},'9999')
         </if>
         <if test="storeId !=null and storeId != ''">
             and t.store_id= #{storeId}
@@ -70,7 +70,7 @@
             and t.b_id= #{bId}
         </if>
         <if test="communityId !=null and communityId != ''">
-            and t.community_id= #{communityId}
+            and t.community_id in (#{communityId},'9999')
         </if>
         <if test="storeId !=null and storeId != ''">
             and t.store_id= #{storeId}
@@ -109,7 +109,7 @@
         <if test="bId !=null and bId != ''">
             and t.b_id= #{bId}
         </if>
-        <if test="communityId !=null and communityId != ''">
+        <if test="communityId != null and communityId != '' and operationType==null ">
             and t.community_id in (#{communityId},'9999')
         </if>
         <if test="storeId !=null and storeId != ''">
@@ -123,6 +123,12 @@
         </if>
         <if test="flowType !=null and flowType != ''">
             and t.flow_type= #{flowType}
+        </if>
+        <if test="flowTypes !=null">
+            and t.flow_type in
+            <foreach collection="flowTypes" item="item" open="(" close=")" separator=",">
+                #{item}
+            </foreach>
         </if>
         order by t.create_time desc
         <if test="page != -1 and page != null ">
@@ -156,8 +162,11 @@
         <if test="flowType !=null and flowType != ''">
             , t.flow_type= #{flowType}
         </if>
-        <if test="processDefinitionKey !=null and processDefinitionKey != ''">
+        <if test="processDefinitionKey !=null and processDefinitionKey != '' and processDefinitionKey != '-1'">
             , t.process_definition_key= #{processDefinitionKey}
+        </if>
+        <if test="processDefinitionKey !=null and processDefinitionKey == '-1'">
+            , t.process_definition_key= ''
         </if>
         where 1=1
         <if test="bId !=null and bId != ''">
@@ -202,6 +211,13 @@
             and t.flow_type= #{flowType}
         </if>
 
+        <if test="flowTypes !=null">
+            and t.flow_type in
+            <foreach collection="flowTypes" item="item" open="(" close=")" separator=",">
+                #{item}
+            </foreach>
+        </if>
+
 
     </select>
 

--
Gitblit v1.8.0