| | |
| | | <result column="deptid" property="deptid" /> |
| | | <result column="tips" property="tips" /> |
| | | <result column="version" property="version" /> |
| | | <result column="headName" property="headName" /> |
| | | <result column="headPhone" property="headPhone" /> |
| | | </resultMap> |
| | | |
| | | <sql id="Base_Column_List"> |
| | |
| | | <select id="selectRoles" resultType="map"> |
| | | select rr.*,(SELECT COUNT(id) from sys_user where FIND_IN_SET(rr.id,roleid)) as userCount |
| | | from sys_role as rr |
| | | <if test="condition != null"> |
| | | where rr.name like CONCAT('%',#{condition},'%') |
| | | </if> |
| | | <where> |
| | | <if test="condition != null and condition != ''"> |
| | | and rr.name like CONCAT('%',#{condition},'%') |
| | | </if> |
| | | <if test="headName != null and headName != ''"> |
| | | and rr.headName like CONCAT('%',#{headName},'%') |
| | | </if> |
| | | <if test="headPhone != null and headPhone != ''"> |
| | | and rr.headPhone like CONCAT('%',#{headPhone},'%') |
| | | </if> |
| | | </where> |
| | | ORDER BY rr.num |
| | | </select> |
| | | |
| | | <delete id="deleteRolesById"> |