|
|
@ -108,7 +108,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
AND u.create_time <= #{params.endTime}
|
|
|
|
AND u.create_time <= #{params.endTime}
|
|
|
|
</if>
|
|
|
|
</if>
|
|
|
|
<if test="deptId != null and deptId != 0">
|
|
|
|
<if test="deptId != null and deptId != 0">
|
|
|
|
AND (u.dept_id = #{deptId} OR u.dept_id IN ( SELECT t.dept_id FROM sys_dept t WHERE FIND_IN_SET (#{deptId},ancestors) ))
|
|
|
|
AND (u.dept_id = #{deptId} OR u.dept_id IN ( SELECT t.dept_id FROM sys_dept t WHERE CAST(#{deptId} AS text) = ANY(string_to_array(ancestors, ','))))
|
|
|
|
</if>
|
|
|
|
</if>
|
|
|
|
<!-- 数据范围过滤 -->
|
|
|
|
<!-- 数据范围过滤 -->
|
|
|
|
${params.dataScope}
|
|
|
|
${params.dataScope}
|
|
|
|