| | |
| | | </if> |
| | | limit #{page.offset}, #{page.size} |
| | | </select> |
| | | |
| | | <!-- 根据部门和角色查询 --> |
| | | <select id="listUserByDeptRoleList" resultMap="dataResult"> |
| | | SELECT t1.id, t1.true_name, t1.dept_id |
| | | FROM dyh_ct_user t1 LEFT JOIN dyh_ct_userole t2 ON t1.id = t2.user_id |
| | | WHERE |
| | | t1.delete_status = '0' |
| | | AND t2.role_code = #{roleCode} |
| | | AND t1.status = '1' |
| | | <if test="deptIdList != null and deptIdList != ''"> |
| | | and t1.dept_id in |
| | | <foreach collection="deptIdList" item="deptIdList" index="index" open="(" separator="," close=")"> |
| | | #{deptIdList} |
| | | </foreach> |
| | | </if> |
| | | </select> |
| | | </mapper> |