From 664184af3e070dee665ee736caffa0297804975f Mon Sep 17 00:00:00 2001 From: KKSU <15274802129@163.com> Date: Tue, 18 Mar 2025 11:46:02 +0800 Subject: [PATCH] perf(mall): 移除会员利润计算中的异步执行 --- src/main/resources/mapper/modules/MallMemberMapper.xml | 16 +++++++++++++++- 1 files changed, 15 insertions(+), 1 deletions(-) diff --git a/src/main/resources/mapper/modules/MallMemberMapper.xml b/src/main/resources/mapper/modules/MallMemberMapper.xml index d43669e..1d64ead 100644 --- a/src/main/resources/mapper/modules/MallMemberMapper.xml +++ b/src/main/resources/mapper/modules/MallMemberMapper.xml @@ -8,6 +8,7 @@ a.phone referrerName, IFNULL(c.balance,0) balance, IFNULL(c.score,0) score, + IFNULL(c.commission,0) commission, vipConfig.vip_name levelName FROM mall_member m left join mall_member a on m.referrer_id = a.invite_id @@ -26,13 +27,20 @@ <if test="record.accountStatus!=null"> and m.account_status = #{record.accountStatus} </if> + <if test="record.inviteId!=null and record.inviteId!=''"> + and m.referrer_id = #{record.inviteId} + </if> + <if test="record.director!=null"> + and m.director = #{record.director} + </if> <if test="record.level!=null and record.level!=''"> and m.level=#{record.level} </if> </if> </where> GROUP BY - m.id, a.phone, c.balance, c.score,vipConfig.vip_name + m.id, a.phone, c.balance, c.score, + c.commission,vipConfig.vip_name order by m.CREATED_TIME desc </select> @@ -458,6 +466,12 @@ where id = #{id} </update> + <update id="updateLevel"> + update mall_member + set level = #{level} + where id = #{id} + </update> + <update id="updateNameAndAvatar"> update mall_member set avatar = #{photo}, -- Gitblit v1.9.1