sql
This commit is contained in:
parent
a0673be746
commit
eef3407dc1
|
|
@ -71,8 +71,12 @@ public class SysRole extends BaseEntity
|
|||
/**
|
||||
* 所属公司ID
|
||||
*/
|
||||
@JsonFormat(shape = JsonFormat.Shape.STRING)
|
||||
private Long companyId;
|
||||
|
||||
@JsonFormat(shape = JsonFormat.Shape.STRING)
|
||||
private Long areaId;
|
||||
|
||||
/** 角色菜单权限 */
|
||||
private Set<String> permissions;
|
||||
|
||||
|
|
@ -232,6 +236,14 @@ public class SysRole extends BaseEntity
|
|||
this.companyId = companyId;
|
||||
}
|
||||
|
||||
public Long getAreaId() {
|
||||
return areaId;
|
||||
}
|
||||
|
||||
public void setAreaId(Long areaId) {
|
||||
this.areaId = areaId;
|
||||
}
|
||||
|
||||
public Set<String> getPermissions()
|
||||
{
|
||||
return permissions;
|
||||
|
|
|
|||
|
|
@ -78,6 +78,7 @@ public class SysRoleServiceImpl implements ISysRoleService
|
|||
role.setRoleKey(str);
|
||||
}
|
||||
role.setCompanyId(SecurityUtils.getLoginUser().getSysUser().getCompanyId());
|
||||
role.setAreaId(SecurityUtils.getLoginUser().getSysUser().getAreaId());
|
||||
return roleMapper.selectRoleList(role);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -44,6 +44,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
<if test="companyId != null">
|
||||
AND r.company_id = #{companyId}
|
||||
</if>
|
||||
<if test="areaId != null">
|
||||
AND r.area_id = #{areaId}
|
||||
</if>
|
||||
<if test="status != null and status != ''">
|
||||
AND r.status = #{status}
|
||||
</if>
|
||||
|
|
|
|||
Loading…
Reference in New Issue