From 342f27cfc85fa7b2b993dc1e6deeb2e1c3bfc62b Mon Sep 17 00:00:00 2001 From: mashuai Date: Wed, 6 Aug 2025 09:12:38 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/resources/mapper/material/common/SelectMapper.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bonus-modules/bonus-material/src/main/resources/mapper/material/common/SelectMapper.xml b/bonus-modules/bonus-material/src/main/resources/mapper/material/common/SelectMapper.xml index a038784e..c311fd1e 100644 --- a/bonus-modules/bonus-material/src/main/resources/mapper/material/common/SelectMapper.xml +++ b/bonus-modules/bonus-material/src/main/resources/mapper/material/common/SelectMapper.xml @@ -212,14 +212,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" mt.unit_name as unitName, mt.unit_value as unitValue, mt.manage_type as manageType, - SUM( CASE WHEN sai.agreement_id = #{agreementId} AND sai.STATUS = '0' THEN sai.num ELSE 0 END ) AS num, + SUM(sai.num) AS num, mt.LEVEL as level FROM ma_type mt LEFT JOIN slt_agreement_info sai ON mt.type_id = sai.type_id LEFT JOIN ma_type mt1 ON mt.parent_id = mt1.type_id and mt1.del_flag = '0' WHERE - sai.STATUS = '0' + sai.STATUS = '0' and sai.agreement_id = #{agreementId} GROUP BY mt.type_id HAVING num> 0