Commit 144f230f authored by hanfeng's avatar hanfeng

修改订单统计

parent 6c1d788d
...@@ -14,6 +14,8 @@ ...@@ -14,6 +14,8 @@
<result column="certification_status" property="certificationStatus"/> <result column="certification_status" property="certificationStatus"/>
<result column="is_member" property="isMember"/> <result column="is_member" property="isMember"/>
<result column="nickname" property="nickname"/> <result column="nickname" property="nickname"/>
<result column="wx_nickname" property="wxNickname"/>
<result column="qq_nickname" property="qqNickname"/>
<result column="realname" property="realname"/> <result column="realname" property="realname"/>
<result column="headimgurl" property="headimgurl"/> <result column="headimgurl" property="headimgurl"/>
<result column="birthday" property="birthday"/> <result column="birthday" property="birthday"/>
...@@ -80,7 +82,10 @@ ...@@ -80,7 +82,10 @@
m.recent_recharge as recentRecharge, m.recent_recharge as recentRecharge,
m.name as memberName, m.name as memberName,
ul.username as inviter, ul.username as inviter,
aup.name as `positionName` aup.name as `positionName`,
p.nameOfSuperior,
p.username AS superiorMobileNumber,
p.parent_id as parentId
from from
app_user_login l app_user_login l
inner join inner join
...@@ -121,6 +126,23 @@ ...@@ -121,6 +126,23 @@
left join left join
`app_user_position` as aup `app_user_position` as aup
on aup.id = d.position_id on aup.id = d.position_id
left join (
SELECT
r.user_id,
r.parent_id,
l.username,
IFNULL(d.realname,d.nickname) as nameOfSuperior
FROM
app_user_relation r
LEFT JOIN app_user_login l ON r.parent_id = l.id
LEFT JOIN app_user_detail d ON l.id = d.userid
WHERE
l.isdel = 0
AND
r.is_del = 0
) p
on
l.id=p.user_id
where l.isdel = 0 where l.isdel = 0
<if test="mobile !=null and mobile !='' "> <if test="mobile !=null and mobile !='' ">
and l.username like CONCAT('%',#{mobile},'%') and l.username like CONCAT('%',#{mobile},'%')
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment