|
@ -19,11 +19,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
<result property="updateBy" column="update_by" /> |
|
|
<result property="updateBy" column="update_by" /> |
|
|
<result property="updateTime" column="update_time" /> |
|
|
<result property="updateTime" column="update_time" /> |
|
|
<result property="remark" column="remark" /> |
|
|
<result property="remark" column="remark" /> |
|
|
|
|
|
<result property="clientType" column="client_type" /> |
|
|
</resultMap> |
|
|
</resultMap> |
|
|
|
|
|
|
|
|
<sql id="selectRoleVo"> |
|
|
<sql id="selectRoleVo"> |
|
|
select distinct r.role_id, r.role_name, r.role_key, r.role_sort, r.data_scope, r.menu_check_strictly, r.dept_check_strictly, |
|
|
select distinct r.role_id, r.role_name, r.role_key, r.role_sort, r.data_scope, r.menu_check_strictly, r.dept_check_strictly, |
|
|
r.status, r.del_flag, r.create_time, r.remark |
|
|
r.status, r.del_flag, r.create_time, r.remark , r.client_type |
|
|
from sys_role r |
|
|
from sys_role r |
|
|
left join sys_user_role ur on ur.role_id = r.role_id |
|
|
left join sys_user_role ur on ur.role_id = r.role_id |
|
|
left join sys_user u on u.user_id = ur.user_id |
|
|
left join sys_user u on u.user_id = ur.user_id |
|
@ -51,6 +52,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
<if test="params.endTime != null and params.endTime != ''"><!-- 结束时间检索 --> |
|
|
<if test="params.endTime != null and params.endTime != ''"><!-- 结束时间检索 --> |
|
|
and date_format(r.create_time,'%Y%m%d') <= date_format(#{params.endTime},'%Y%m%d') |
|
|
and date_format(r.create_time,'%Y%m%d') <= date_format(#{params.endTime},'%Y%m%d') |
|
|
</if> |
|
|
</if> |
|
|
|
|
|
<if test="clientType != null"> |
|
|
|
|
|
AND r.client_type = #{clientType} |
|
|
|
|
|
</if> |
|
|
<!-- 数据范围过滤 --> |
|
|
<!-- 数据范围过滤 --> |
|
|
${params.dataScope} |
|
|
${params.dataScope} |
|
|
order by r.role_sort |
|
|
order by r.role_sort |
|
@ -105,6 +109,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
<if test="status != null and status != ''">status,</if> |
|
|
<if test="status != null and status != ''">status,</if> |
|
|
<if test="remark != null and remark != ''">remark,</if> |
|
|
<if test="remark != null and remark != ''">remark,</if> |
|
|
<if test="createBy != null and createBy != ''">create_by,</if> |
|
|
<if test="createBy != null and createBy != ''">create_by,</if> |
|
|
|
|
|
<if test="clientType != null">client_type,</if> |
|
|
create_time |
|
|
create_time |
|
|
)values( |
|
|
)values( |
|
|
<if test="roleId != null and roleId != 0">#{roleId},</if> |
|
|
<if test="roleId != null and roleId != 0">#{roleId},</if> |
|
@ -117,6 +122,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
<if test="status != null and status != ''">#{status},</if> |
|
|
<if test="status != null and status != ''">#{status},</if> |
|
|
<if test="remark != null and remark != ''">#{remark},</if> |
|
|
<if test="remark != null and remark != ''">#{remark},</if> |
|
|
<if test="createBy != null and createBy != ''">#{createBy},</if> |
|
|
<if test="createBy != null and createBy != ''">#{createBy},</if> |
|
|
|
|
|
<if test="clientType != null">#{clientType},</if> |
|
|
sysdate() |
|
|
sysdate() |
|
|
) |
|
|
) |
|
|
</insert> |
|
|
</insert> |
|
@ -133,6 +139,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
<if test="status != null and status != ''">status = #{status},</if> |
|
|
<if test="status != null and status != ''">status = #{status},</if> |
|
|
<if test="remark != null">remark = #{remark},</if> |
|
|
<if test="remark != null">remark = #{remark},</if> |
|
|
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if> |
|
|
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if> |
|
|
|
|
|
<if test="clientType != null">client_type = #{clientType},</if> |
|
|
update_time = sysdate() |
|
|
update_time = sysdate() |
|
|
</set> |
|
|
</set> |
|
|
where role_id = #{roleId} |
|
|
where role_id = #{roleId} |
|
|