|
|
@@ -653,21 +653,21 @@
|
|
|
and transfer_time between #{startTime,jdbcType=VARCHAR} and #{endTime,jdbcType=VARCHAR}
|
|
|
</if>
|
|
|
group by aid) d on a.id=d.aid
|
|
|
- left join (select x.aid,count(uid) completeCount from (select aid,uid from user_business a where follow_situation=5
|
|
|
+ left join (select x.aid,count(uid) completeCount from (select a.aid,a.uid from user_business a left join `user` b on a.uid=b.id where a.follow_situation=5
|
|
|
<if test="startTime != null and endTime != null">
|
|
|
- and update_time between #{startTime,jdbcType=VARCHAR} and #{endTime,jdbcType=VARCHAR}
|
|
|
+ and a.update_time between #{startTime,jdbcType=VARCHAR} and #{endTime,jdbcType=VARCHAR}
|
|
|
</if>
|
|
|
- group by aid,uid)x group by aid)e on a.id=e.aid
|
|
|
- left join (select x.aid,count(uid)interviewCount from (select aid,uid from user_business a where follow_situation=1
|
|
|
+ and b.`type`=1 group by aid,uid)x group by aid)e on a.id=e.aid
|
|
|
+ left join (select x.aid,count(uid) interviewCount from (select a.aid,a.uid from user_business a left join `user` b on a.uid=b.id where a.follow_situation=1
|
|
|
<if test="startTime != null and endTime != null">
|
|
|
- and update_time between #{startTime,jdbcType=VARCHAR} and #{endTime,jdbcType=VARCHAR}
|
|
|
+ and a.update_time between #{startTime,jdbcType=VARCHAR} and #{endTime,jdbcType=VARCHAR}
|
|
|
</if>
|
|
|
- group by aid,uid)x group by aid)f on a.id=f.aid
|
|
|
+ and b.`type`=1 group by aid,uid)x group by aid)f on a.id=f.aid
|
|
|
left join department d on a.department_id=d.id
|
|
|
left join user_role e on a.id=e.uid
|
|
|
left join `role` f on e.rid=f.id
|
|
|
where f.role_name in ('营销员','营销经理')
|
|
|
- and a.status='正常' and a.type=1
|
|
|
+ and a.status='正常'
|
|
|
<if test="depName !=null">
|
|
|
and d.name= #{depName}
|
|
|
</if>
|