| | |
| | | AND (u.dept_id = #{deptId} OR u.dept_id IN ( SELECT t.dept_id FROM sys_dept t WHERE find_in_set(#{deptId}, |
| | | ancestors) )) |
| | | </if> |
| | | <if test="hospInfoCodeList != null and hospInfoCodeList.size() > 0"> |
| | | <!-- 科室多 Code 任一匹配:D001,D003 等价于 D001 或 D003,顺序无关 --> |
| | | AND ( |
| | | <foreach collection="hospInfoCodeList" item="code" separator=" OR "> |
| | | u.hosp_info LIKE concat('%"', #{code}, '"%') |
| | | </foreach> |
| | | ) |
| | | </if> |
| | | <if test="deptInfoCodeList != null and deptInfoCodeList.size() > 0"> |
| | | <!-- 病区多 Code 任一匹配:W001,W003 等价于 W001 或 W003,顺序无关 --> |
| | | AND ( |
| | | <foreach collection="deptInfoCodeList" item="code" separator=" OR "> |
| | | u.dept_info LIKE concat('%"', #{code}, '"%') |
| | | </foreach> |
| | | ) |
| | | </if> |
| | | <!-- 数据范围过滤 --> |
| | | ${params.dataScope} |
| | | </select> |
| | |
| | | AND (u.dept_id = #{deptId} OR u.dept_id IN ( SELECT t.dept_id FROM sys_dept t WHERE find_in_set(#{deptId}, |
| | | ancestors) )) |
| | | </if> |
| | | <if test="hospInfoCodeList != null and hospInfoCodeList.size() > 0"> |
| | | <!-- 科室多 Code 任一匹配:D001,D003 等价于 D001 或 D003,顺序无关 --> |
| | | AND ( |
| | | <foreach collection="hospInfoCodeList" item="code" separator=" OR "> |
| | | u.hosp_info LIKE concat('%"', #{code}, '"%') |
| | | </foreach> |
| | | ) |
| | | </if> |
| | | <if test="deptInfoCodeList != null and deptInfoCodeList.size() > 0"> |
| | | <!-- 病区多 Code 任一匹配:W001,W003 等价于 W001 或 W003,顺序无关 --> |
| | | AND ( |
| | | <foreach collection="deptInfoCodeList" item="code" separator=" OR "> |
| | | u.dept_info LIKE concat('%"', #{code}, '"%') |
| | | </foreach> |
| | | ) |
| | | </if> |
| | | <if test="pageSize != null and pageNum != null">limit ${pageSize} OFFSET ${pageNum}</if> |
| | | </select> |
| | | |