|
|
@ -33,7 +33,7 @@ |
|
|
|
common_push_concern_fan cf JOIN sys_user u |
|
|
|
common_push_concern_fan cf JOIN sys_user u |
|
|
|
ON |
|
|
|
ON |
|
|
|
<choose> |
|
|
|
<choose> |
|
|
|
<when test="map.onType == 1"> |
|
|
|
<when test="map.dynamicJoinType == 1"> |
|
|
|
cf.concern_user_id = u.id |
|
|
|
cf.concern_user_id = u.id |
|
|
|
</when> |
|
|
|
</when> |
|
|
|
<otherwise> |
|
|
|
<otherwise> |
|
|
@ -89,7 +89,7 @@ |
|
|
|
common_push_concern_fan cf JOIN sys_user u |
|
|
|
common_push_concern_fan cf JOIN sys_user u |
|
|
|
ON |
|
|
|
ON |
|
|
|
<choose> |
|
|
|
<choose> |
|
|
|
<when test="onType == 1"> |
|
|
|
<when test="dynamicJoinType == 1"> |
|
|
|
cf.concern_user_id = u.id |
|
|
|
cf.concern_user_id = u.id |
|
|
|
</when> |
|
|
|
</when> |
|
|
|
<otherwise> |
|
|
|
<otherwise> |
|
|
@ -103,7 +103,6 @@ |
|
|
|
</where> |
|
|
|
</where> |
|
|
|
</select> |
|
|
|
</select> |
|
|
|
|
|
|
|
|
|
|
|
<!-- todo: 多条 common_push_concern_fan 相同跟 sys_user 关联可能会出现问题 --> |
|
|
|
|
|
|
|
<select id="selectPushFriendList" resultType="Map"> |
|
|
|
<select id="selectPushFriendList" resultType="Map"> |
|
|
|
SELECT |
|
|
|
SELECT |
|
|
|
cf.`status` cf_status, |
|
|
|
cf.`status` cf_status, |
|
|
@ -112,12 +111,22 @@ |
|
|
|
u.* |
|
|
|
u.* |
|
|
|
FROM |
|
|
|
FROM |
|
|
|
sys_user u |
|
|
|
sys_user u |
|
|
|
LEFT JOIN (select * FROM common_push_concern_fan |
|
|
|
LEFT JOIN (select * FROM common_push_concern_fan WHERE del_flag = 0 |
|
|
|
WHERE del_flag = 0 |
|
|
|
<choose> |
|
|
|
|
|
|
|
<!--企业用户进行粉丝查询连表--> |
|
|
|
|
|
|
|
<when test="map.dynamicJoinType == 1"> |
|
|
|
|
|
|
|
AND concern_user_id = ${@com.cloud.kicc.common.security.util.SecurityUtils@getUser().id}) cf |
|
|
|
|
|
|
|
ON u.id = cf.fan_user_id |
|
|
|
|
|
|
|
LEFT JOIN common_push_blacklist b |
|
|
|
|
|
|
|
ON u.id = b.fan_user_id |
|
|
|
|
|
|
|
</when> |
|
|
|
|
|
|
|
<otherwise> |
|
|
|
AND fan_user_id = ${@com.cloud.kicc.common.security.util.SecurityUtils@getUser().id}) cf |
|
|
|
AND fan_user_id = ${@com.cloud.kicc.common.security.util.SecurityUtils@getUser().id}) cf |
|
|
|
ON u.id = cf.concern_user_id |
|
|
|
ON u.id = cf.concern_user_id |
|
|
|
LEFT JOIN common_push_blacklist b |
|
|
|
LEFT JOIN common_push_blacklist b |
|
|
|
ON u.id = b.concern_user_id |
|
|
|
ON u.id = b.concern_user_id |
|
|
|
|
|
|
|
</otherwise> |
|
|
|
|
|
|
|
</choose> |
|
|
|
<where> |
|
|
|
<where> |
|
|
|
u.del_flag = 0 |
|
|
|
u.del_flag = 0 |
|
|
|
AND u.status = 0 |
|
|
|
AND u.status = 0 |
|
|
@ -129,6 +138,7 @@ |
|
|
|
<if test="map.nickName != null and map.nickName != ''"> |
|
|
|
<if test="map.nickName != null and map.nickName != ''"> |
|
|
|
AND u.nick_name = #{map.nickName} |
|
|
|
AND u.nick_name = #{map.nickName} |
|
|
|
</if> |
|
|
|
</if> |
|
|
|
|
|
|
|
ORDER BY u.create_time ASC |
|
|
|
</where> |
|
|
|
</where> |
|
|
|
</select> |
|
|
|
</select> |
|
|
|
|
|
|
|
|
|
|
|