From eee00fd63f558cfa0caf737c868de8fc0c652fcd Mon Sep 17 00:00:00 2001
From: yeg <1347747024@qq.com>
Date: 星期一, 07 九月 2026 10:39:30 +0800
Subject: [PATCH] 修复对比字段模板结构与权限边界
---
battery-business/src/main/resources/mapper/battery/TBatteryGroupFieldMapper.xml | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/battery-business/src/main/resources/mapper/battery/TBatteryGroupFieldMapper.xml b/battery-business/src/main/resources/mapper/battery/TBatteryGroupFieldMapper.xml
index 8d77e46..56007ea 100644
--- a/battery-business/src/main/resources/mapper/battery/TBatteryGroupFieldMapper.xml
+++ b/battery-business/src/main/resources/mapper/battery/TBatteryGroupFieldMapper.xml
@@ -102,5 +102,7 @@
where field_id = #{fieldId} and del_flag = 0)
+ (select count(1) from t_battery_group_relation_field
where battery_group_field_id = #{fieldId} and del_flag = '0')
+ + (select count(1) from t_compare_report_field_template
+ where template_type = 'compare' and JSON_CONTAINS(fields_json, JSON_OBJECT('fieldDefinitionId', #{fieldId})))
</select>
</mapper>
--
Gitblit v1.7.1