Helius
2022-06-09 8f090c91e2e2b0536d0900b935948e77a5f0979d
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="cc.mrbird.febs.dapp.mapper.DappAgentReturnFlowDao">
 
    <select id="selectTotalAmountByMemberId" resultType="java.math.BigDecimal">
        select IFNULL(sum(amount),0)
        from dapp_agent_return_flow
        where agent_member_id=#{memberId}
        <if test="isReturn!=null">
            and is_return=#{isReturn}
        </if>
    </select>
 
    <update id="updateIsReturnByMemberId">
        update dapp_agent_return_flow
        set is_return=#{isReturn}
        where member_id=#{memberId}
    </update>
</mapper>