From 6c5d7fa4635b06d30840c39f96bd381b65cb56e7 Mon Sep 17 00:00:00 2001
From: xiangpei <xiangpei@timesnew.cn>
Date: 星期二, 03 九月 2024 19:43:59 +0800
Subject: [PATCH] 数据中心优化

---
 ycl-server/src/main/resources/mapper/zgyw/CheckScoreMapper.xml |    8 ++++++--
 1 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/ycl-server/src/main/resources/mapper/zgyw/CheckScoreMapper.xml b/ycl-server/src/main/resources/mapper/zgyw/CheckScoreMapper.xml
index 8eeb9a8..de53afb 100644
--- a/ycl-server/src/main/resources/mapper/zgyw/CheckScoreMapper.xml
+++ b/ycl-server/src/main/resources/mapper/zgyw/CheckScoreMapper.xml
@@ -35,7 +35,7 @@
             <if test="deptId != null "> and tcs.dept_id = #{deptId}</if>
             ${params.dataScope}
         </where>
-        order by create_time desc;
+        order by create_time desc
     </select>
 
     <select id="selectCheckScoreById" parameterType="Long" resultMap="CheckScoreResult">
@@ -107,6 +107,9 @@
         select t.* from ${tableName} t
         left join sys_dept d on t.dept_id = d.dept_id
         where t.dept_id = #{deptId}
+        <if test="examineTag != null">
+            and examine_tag = #{examineTag}
+        </if>
         <if test="date != null">
             and date_format(t.create_time,'%Y-%m') = #{date}
         </if>
@@ -135,7 +138,8 @@
         WHERE
             examine_tag = #{examineTag}
           AND DATE_FORMAT(tcs.create_time, '%Y-%m') BETWEEN DATE_FORMAT(#{startDate}, '%Y-%m') AND DATE_FORMAT(#{endDate}, '%Y-%m')
-    </select>
+        GROUP BY tcs.dept_id, examine_category,examine_tag
+</select>
 
     <select id="home" resultType="java.util.Map">
         <![CDATA[

--
Gitblit v1.8.0