From c4957c48499e767280485216ef06f769e3ec7908 Mon Sep 17 00:00:00 2001
From: xiaoyong931011 <15274802129@163.com>
Date: Mon, 07 Aug 2023 18:15:38 +0800
Subject: [PATCH] 数据修改

---
 src/main/resources/mapper/dapp/DappMemberDao.xml |   71 ++++++++++++++++++++++++++++++++++-
 1 files changed, 69 insertions(+), 2 deletions(-)

diff --git a/src/main/resources/mapper/dapp/DappMemberDao.xml b/src/main/resources/mapper/dapp/DappMemberDao.xml
index 3bfd934..ae49129 100644
--- a/src/main/resources/mapper/dapp/DappMemberDao.xml
+++ b/src/main/resources/mapper/dapp/DappMemberDao.xml
@@ -237,8 +237,8 @@
     </select>
 
     <select id="selectAllAchieveByInviteId" resultType="java.math.BigDecimal">
-        select IFNULL(sum(IFNULL(a.achieve_amount, 0)),0)
-        from dapp_usdt_perk a
+        select IFNULL(sum(IFNULL(a.amount, 0)),0)
+        from mall_achieve_record a
         inner join dapp_member b on a.member_id = b.id
         where find_in_set(#{inviteId}, b.referer_ids) or b.invite_id = #{inviteId}
     </select>
@@ -258,4 +258,71 @@
             address
         from dapp_member where active_status  = 1
     </select>
+
+    <select id="selectMallGoodsListQueryInPage" resultType="cc.mrbird.febs.dapp.vo.MallGoodsListVo">
+        select
+        a.*
+        from mall_goods a
+        where a.is_sale = 1
+        group by a.id
+        order by a.sort_cnt asc
+    </select>
+
+    <select id="selectMallOrderListQueryInPage" resultType="cc.mrbird.febs.dapp.vo.MallOrderListVo">
+        select a.*
+        from mall_order_info a
+        <where>
+            a.member_id = #{record.memberId}
+            <if test="record != null">
+                <if test="record.status != null and record.status != ''">
+                    and a.status = #{record.status}
+                </if>
+            </if>
+        </where>
+        order by a.create_time desc
+    </select>
+
+    <select id="selectMallOrderListVoById" resultType="cc.mrbird.febs.dapp.vo.MallOrderListVo">
+        select a.*
+        from mall_order_info a
+        where id = #{orderId}
+        order by a.create_time desc
+    </select>
+
+    <select id="selectMallOrderItemVoByOrderId" resultType="cc.mrbird.febs.dapp.vo.MallOrderItemVo">
+        select a.*
+        from mall_order_item a
+        where orderId = #{orderId}
+    </select>
+
+    <select id="selectMallGoodsListVoById" resultType="cc.mrbird.febs.dapp.vo.MallGoodsListVo">
+        select
+            a.*
+        from mall_goods a
+        where a.id = #{goodsId}
+    </select>
+
+    <select id="selectInviteLeft" resultType="cc.mrbird.febs.dapp.entity.DappMemberEntity">
+        select * from dapp_member where invite_left = #{inviteId}
+    </select>
+
+    <select id="selectInviteRight" resultType="cc.mrbird.febs.dapp.entity.DappMemberEntity">
+        select * from dapp_member where invite_right = #{inviteId}
+    </select>
+
+    <select id="selectMemberByActiveStatus" resultType="cc.mrbird.febs.dapp.entity.DappMemberEntity">
+        select * from dapp_member where active_status = 1
+    </select>
+
+    <select id="selectAchieveRecordByInviteId" resultType="java.math.BigDecimal">
+        select IFNULL(sum(IFNULL(a.amount, 0)),0)
+        from mall_achieve_record a
+                 inner join dapp_member b on a.member_id = b.id
+        where find_in_set(#{inviteId}, b.referer_ids) or b.invite_id = #{inviteId}
+    </select>
+
+    <select id="selectChildAgentList" resultType="cc.mrbird.febs.dapp.entity.DappMemberEntity">
+        select * from dapp_member
+        where (find_in_set(#{inviteId}, referer_ids) or invite_id=#{inviteId}) and account_type=#{accountType}
+    </select>
 </mapper>
\ No newline at end of file

--
Gitblit v1.9.1