|
@@ -731,11 +731,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
LEFT JOIN company_user ON company_user.user_id = fs_user_company_user.company_user_id
|
|
LEFT JOIN company_user ON company_user.user_id = fs_user_company_user.company_user_id
|
|
|
WHERE fs_user.is_del = 0 and fs_user_company_user.is_repeat_fans is not null
|
|
WHERE fs_user.is_del = 0 and fs_user_company_user.is_repeat_fans is not null
|
|
|
<if test="userId != null and userId != 0 ">
|
|
<if test="userId != null and userId != 0 ">
|
|
|
- and (fs_user_company_user.company_user_id = #{userId} OR company_user.parent_id = #{userId} )
|
|
|
|
|
- </if>
|
|
|
|
|
- <if test="companyId != null ">
|
|
|
|
|
- and fs_user_company_user.company_id = #{companyId}
|
|
|
|
|
|
|
+-- and (fs_user_company_user.company_user_id = #{userId} OR company_user.parent_id = #{userId} )
|
|
|
|
|
+ and fs_user_company_user.company_user_id = #{userId}
|
|
|
</if>
|
|
</if>
|
|
|
|
|
+ AND fs_user_company_user.company_id =
|
|
|
|
|
+ CASE
|
|
|
|
|
+ WHEN #{companyId} IS NOT NULL THEN #{companyId}
|
|
|
|
|
+ ELSE fs_user_company_user.company_id
|
|
|
|
|
+ END
|
|
|
GROUP BY
|
|
GROUP BY
|
|
|
fs_user_company_user.`status`,fs_user_company_user.project_id
|
|
fs_user_company_user.`status`,fs_user_company_user.project_id
|
|
|
</select>
|
|
</select>
|