| | |
| | | sum(hold_amount) holdAmount, |
| | | sum(reward_amount) rewardAmount |
| | | from contract_order where order_type in (3,4) and order_status=1 group by member_id) d on a.id=d.member_id |
| | | where find_in_set(#{record.refererId}, a.referer_ids) |
| | | where find_in_set(#{record.refererIds}, a.referer_ids) |
| | | <if test="record.account!=null and record.account!=''"> |
| | | and (a.phone=#{record.account} or a.email=#{record.account} or a.invite_id=#{record.account}) |
| | | </if> |
| | | <if test="record.refererId!=null and record.refererId!=''"> |
| | | and a.referer_id=#{record.refererId} |
| | | </if> |
| | | group by a.create_time,a.phone, a.email |
| | | order by a.create_time desc |
| | | </select> |
| | |
| | | b.total_balance contractTotal, |
| | | c.total_balance coinTotal, |
| | | d.total_balance agentTotal |
| | | from kss_framework.member a |
| | | from member a |
| | | left join member_wallet_contract b on a.id=b.member_id |
| | | left join member_wallet_coin c on a.id=c.member_id and c.wallet_code='USDT' |
| | | left join member_wallet_agent d on a.id=d.member_id |
| | | left join member_authentication e on a.id=e.member_id |
| | | where find_in_set(#{record.refererId}, a.referer_ids) |
| | | where find_in_set(#{record.refererIds}, a.referer_ids) |
| | | <if test="record.account!=null and record.account!=''"> |
| | | and (a.phone=#{record.account} or a.email=#{record.account} or a.invite_id=#{record.account}) |
| | | </if> |
| | | <if test="record.refererId!=null and record.refererId!=''"> |
| | | and a.referer_id=#{record.refererId} |
| | | </if> |
| | | order by a.create_time desc |
| | | </select> |
| | | </mapper> |