Ver Fonte

修改bug:
解决订单审核-任务中心,待审核和疑问订单因为sql导致的数据互斥问题

jiakai há 3 meses atrás
pai
commit
c43c9e9273

+ 11 - 3
tenant/insurance/quotation-summary/src/main/resources/mapper/InsFeeAuditMapper.xml

@@ -215,9 +215,17 @@
         LEFT JOIN ins_orders_external_policy ioep on ioep.order_no = io.id AND ioep.is_delete=0
         <where>
             and ifa.is_delete=0
-            <if test="param.receiveUser != null and param.receiveUser != ''">
-                and ifa.receive_user = #{param.receiveUser}
-            </if>
+            <choose>
+                <when test="param.receiveUser != null and param.receiveUser != ''">
+                    and ifa.receive_user = #{param.receiveUser}
+                </when>
+                <when test="param.isProblem != null and param.isProblem == 1">
+                    and ifa.receive_user is NOT NULL
+                </when>
+                <otherwise>
+                    and ifa.receive_user is NULL
+                </otherwise>
+            </choose>
             <if test="param.auditType != null">
                 and ifa.audit_type = #{param.auditType}
             </if>