From f7ed73841b806f36bd5f058e1a01386e66437076 Mon Sep 17 00:00:00 2001 From: wzy <wzy19931122ai@163.com> Date: Wed, 08 Jun 2022 22:46:45 +0800 Subject: [PATCH] fix --- src/main/resources/mapper/dapp/DappFundFlowDao.xml | 11 +++++++++++ 1 files changed, 11 insertions(+), 0 deletions(-) diff --git a/src/main/resources/mapper/dapp/DappFundFlowDao.xml b/src/main/resources/mapper/dapp/DappFundFlowDao.xml index b29ced5..a8f1abd 100644 --- a/src/main/resources/mapper/dapp/DappFundFlowDao.xml +++ b/src/main/resources/mapper/dapp/DappFundFlowDao.xml @@ -49,4 +49,15 @@ and a.status=#{status} </if> </select> + + <select id="selectAmountTotalByType" resultType="java.util.HashMap"> + select + case when type=1 then amount end buy, + case when type=2 then amount end sale, + case when type=3 then amount end mine, + case when type=4 then amount end teamReward + from (select type, sum(amount) amount from dapp_fund_flow + where member_id=#{memberId} + ) a + </select> </mapper> \ No newline at end of file -- Gitblit v1.9.1