From c5f6f451fcd2a5257315590c5a256766fa68e433 Mon Sep 17 00:00:00 2001
From: ke <893754509@qq.com>
Date: Mon, 19 Aug 2024 14:02:25 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/jtdev' into jtdev

---
 skjcmanager/skjcmanager-service/skjcmanager-sm/src/main/java/cn/gistack/sm/sg/mapper/SgProgressReportMapper.xml |   16 ++++++++--------
 1 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/skjcmanager/skjcmanager-service/skjcmanager-sm/src/main/java/cn/gistack/sm/sg/mapper/SgProgressReportMapper.xml b/skjcmanager/skjcmanager-service/skjcmanager-sm/src/main/java/cn/gistack/sm/sg/mapper/SgProgressReportMapper.xml
index 615ac00..eade863 100644
--- a/skjcmanager/skjcmanager-service/skjcmanager-sm/src/main/java/cn/gistack/sm/sg/mapper/SgProgressReportMapper.xml
+++ b/skjcmanager/skjcmanager-service/skjcmanager-sm/src/main/java/cn/gistack/sm/sg/mapper/SgProgressReportMapper.xml
@@ -96,16 +96,16 @@
             and de.device_name like CONCAT(CONCAT('%', #{dto.deviceName}), '%')
         </if>
         <if test="dto.userId != null and dto.userId != ''">
-            and userR.user_id = #{dto.userId}
+            and userR.user_id = #{dto.userId} and userR.approval_order != 0
         </if>
-        <if test="dto.approvalStatus != null and dto.approvalStatus != 3">
         <if test="dto.approvalStatus != null and dto.approvalStatus ==0">
-            and userR.approval_status = 0
+            and userR.approval_status = 0 and report.audit_person = #{dto.userId} and (report."STATUS" = 0 or report."STATUS" = 1)
         </if>
         <if test="dto.approvalStatus != null and dto.approvalStatus ==1">
-           and userR.approval_status != 0
+           and userR.approval_status = 1
         </if>
-            AND userR.approval_order != 0
+        <if test="dto.approvalStatus != null and dto.approvalStatus ==2">
+            AND userR.approval_order = 2
         </if>
         <if test="dto.startTime != null and dto.startTime !='' ">
             and report.report_time &gt;= #{dto.startTime}
@@ -113,17 +113,17 @@
         <if test="dto.endTime != null and dto.endTime !='' ">
             and report.report_time &lt;= #{dto.endTime}
         </if>
-        <choose >
+        <!--<choose >
             <when test="dto.approvalStatus != null and dto.approvalStatus == 0">
                 and report.audit_person = #{dto.userId} and (report."STATUS" = 0 or report."STATUS" = 1)
             </when>
             <when test="dto.approvalStatus != null and dto.approvalStatus == 1">
-               and report."STATUS" != 0
+               and report."STATUS" != 1
             </when>
             <when test="dto.approvalStatus != null and dto.approvalStatus == 3">
                 and report.report_user = #{dto.userId}
             </when>
-        </choose>
+        </choose>-->
     </select>
     <select id="countList" resultType="java.lang.Long">
         select count(1) from  ywxt.SG_PROGRESS_REPORT report

--
Gitblit v1.9.3