From e94e6721a4aeb8c21e97878239ec3429fc76d1ad Mon Sep 17 00:00:00 2001 From: xiaoyong931011 <15274802129@163.com> Date: Mon, 08 May 2023 14:23:45 +0800 Subject: [PATCH] 创建订单之前的判断修改 --- src/main/resources/mapper/modules/MallAchieveRecordMapper.xml | 6 ++++++ 1 files changed, 6 insertions(+), 0 deletions(-) diff --git a/src/main/resources/mapper/modules/MallAchieveRecordMapper.xml b/src/main/resources/mapper/modules/MallAchieveRecordMapper.xml index 116720c..d123506 100644 --- a/src/main/resources/mapper/modules/MallAchieveRecordMapper.xml +++ b/src/main/resources/mapper/modules/MallAchieveRecordMapper.xml @@ -28,4 +28,10 @@ where date_format(achieve_time, '%Y-%m-%d') = date_format(#{date}, '%Y-%m-%d'); </select> + <select id="selectSumAchieveByMemberId" resultType="java.math.BigDecimal"> + select IFNULL(sum(IFNULL(amount,0)),0) + from mall_achieve_record + where member_id = #{memberId}; + </select> + </mapper> \ No newline at end of file -- Gitblit v1.9.1