| | |
| | | order by create_time desc |
| | | </select> |
| | | |
| | | <select id="selectStudent" resultType="com.mindskip.xzs.domain.vo.UserVO" parameterType="com.mindskip.xzs.domain.vo.UserVO"> |
| | | SELECT |
| | | a.id, a.real_name |
| | | FROM |
| | | t_user a |
| | | left join t_user_tag b on a.id = b.user_id |
| | | left join t_user_department c on a.id = c.user_id |
| | | where |
| | | user_name != 'admin' |
| | | <if test="tagId != null and tagId != ''"> |
| | | and b.tag_id = #{tagId} |
| | | </if> |
| | | <if test="deptId != null and deptId != ''"> |
| | | and c.department_id = #{deptId} |
| | | </if> |
| | | group by a.id, a.real_name |
| | | order by a.id |
| | | </select> |
| | | |
| | | </mapper> |