|
|
@ -11,19 +11,19 @@
|
|
|
|
<if test="org_id!=null">and m.org_id=#{org_id}</if>
|
|
|
|
<if test="org_id!=null">and m.org_id=#{org_id}</if>
|
|
|
|
</select>
|
|
|
|
</select>
|
|
|
|
<select id="listAvailable" resultType="com.alibaba.fastjson.JSONObject">
|
|
|
|
<select id="listAvailable" resultType="com.alibaba.fastjson.JSONObject">
|
|
|
|
SELECT manager_id,
|
|
|
|
SELECT m.manager_id,
|
|
|
|
m.org_id,
|
|
|
|
m.org_id,
|
|
|
|
display_name,
|
|
|
|
m.display_name,
|
|
|
|
username,role,m.is_valid,m.create_time,last_login,o.name org_name,
|
|
|
|
m.username,m.role,m.is_valid,m.create_time,m.last_login,o.name org_name,
|
|
|
|
email,phone,wechat,
|
|
|
|
m.email,m.phone,m.wechat,
|
|
|
|
o.headimg,
|
|
|
|
co.headimg,
|
|
|
|
o.nickname,
|
|
|
|
co.nickname,
|
|
|
|
o.parent_org_id
|
|
|
|
o.parent_org_id
|
|
|
|
FROM
|
|
|
|
FROM
|
|
|
|
sys_managers m
|
|
|
|
sys_managers m
|
|
|
|
LEFT JOIN sys_org o ON o.org_id=m.org_id
|
|
|
|
LEFT JOIN sys_org o ON o.org_id=m.org_id
|
|
|
|
LEFT JOIN sys_customer_relation o
|
|
|
|
LEFT JOIN sys_customer_relation co
|
|
|
|
ON m.wx_openid = o.wechat_openid
|
|
|
|
ON m.wx_openid = co.wechat_openid
|
|
|
|
<where>
|
|
|
|
<where>
|
|
|
|
<if test="username!=null">
|
|
|
|
<if test="username!=null">
|
|
|
|
<bind name="username_pattern" value="'%'+username+'%'"/>
|
|
|
|
<bind name="username_pattern" value="'%'+username+'%'"/>
|
|
|
|