|
|
@@ -4,7 +4,13 @@
|
|
|
|
|
|
<select id="selectVOByKeyword" resultType="com.platform.dao.vo.SysUserVO"
|
|
|
parameterType="com.platform.dao.dto.upms.SysUserDTO">
|
|
|
- select u.* from t_sys_user u
|
|
|
+ select u.*, dept.deptName from t_sys_user u
|
|
|
+ left join (
|
|
|
+ select ud.user_id, GROUP_CONCAT(d.name ORDER BY d.dept_id SEPARATOR ', ') as deptName
|
|
|
+ from t_sys_user_dept ud
|
|
|
+ left join t_sys_dept d on ud.dept_id = d.dept_id
|
|
|
+ group by ud.user_id
|
|
|
+ ) dept on u.user_id = dept.user_id
|
|
|
where 1=1
|
|
|
<if test="keyword !=null and keyword !=''">
|
|
|
and (u.username like CONCAT('%',#{keyword},'%')
|