From a1543bccf6b616d2db9d44b762826d58887172a6 Mon Sep 17 00:00:00 2001 From: baoshiwei <baoshiwei@shlanbao.cn> Date: 星期二, 10 六月 2025 18:57:57 +0800 Subject: [PATCH] refactor(zhitan-system):优化获取节点ID列表的逻辑- 移除了过滤条件中的 parentNode 节点 ID 比较逻辑 - 现在只根据父节点 ID 是否非空来筛选 modelNodeList --- zhitan-system/src/main/resources/mapper/comprehensivestatistics/DailyComprehensiveMapper.xml | 8 +++++--- 1 files changed, 5 insertions(+), 3 deletions(-) diff --git a/zhitan-system/src/main/resources/mapper/comprehensivestatistics/DailyComprehensiveMapper.xml b/zhitan-system/src/main/resources/mapper/comprehensivestatistics/DailyComprehensiveMapper.xml index 0380045..329e365 100644 --- a/zhitan-system/src/main/resources/mapper/comprehensivestatistics/DailyComprehensiveMapper.xml +++ b/zhitan-system/src/main/resources/mapper/comprehensivestatistics/DailyComprehensiveMapper.xml @@ -35,10 +35,11 @@ <result column="value0" property="value0"/> </resultMap> <!--鍏ㄥ巶鑳借�楃粺璁�--> - <select id="getdailyComprehensiveList" resultMap="dataItemMap"> + <select id="getDailyComprehensiveList" resultType="com.zhitan.comprehensivestatistics.domain.DailyComprehensive"> SELECT aa.index_id, aa.index_name, + aa.unit_id, <foreach item="item" index="index" collection="dataList"> COALESCE ( MAX ( CASE WHEN data_time = #{item.dataTime} THEN "value" END ), null ) AS ${item.value}, </foreach> @@ -49,6 +50,7 @@ SELECT ni.index_id, ei."name" AS "index_name", + ei.unit_id, di."value", di.data_time, di.time_type, @@ -68,11 +70,11 @@ </if> ) aa GROUP BY - aa.index_id, aa.index_name, aa.time_type, aa.order_num + aa.index_id, aa.index_name, aa.unit_id, aa.time_type, aa.order_num ORDER BY aa.order_num ASC </select> - <select id="getListChart" resultMap="dataItemMap"> + <select id="getListChart" resultType="com.zhitan.comprehensivestatistics.domain.DailyComprehensive"> SELECT di.index_id, ci.name AS "index_name", -- Gitblit v1.9.3