@Service @DS(value="authority") @Transactional(rollbackFor=java.lang.Exception.class, propagation=REQUIRES_NEW) public class UserRoleServiceImpl extends ServiceImpl<UserRoleMapper,UserRole> implements IUserRoleService
构造器和说明 |
---|
UserRoleServiceImpl() |
限定符和类型 | 方法和说明 |
---|---|
int |
countUserByRole(Long roleId)
获取具备指定角色的用户数量
|
Set<Long> |
loadRoleByUser(Long userId)
获取用户对应的角色ID
|
Set<Long> |
loadUserByRole(Long roleId)
获取角色对应的用户ID集合
|
List<UserRoleBO> |
loadUserRole(Long userId)
获取用户角色关系信息
|
void |
recordUserRole(AuthorizationBO authorizationBO)
记录用户角色信息
|
void |
revokeRole(Long userId)
解除用户角色
|
alwaysUpdateSomeColumnById, deleteByIdWithFill, insertBatchSomeColumn, insertIgnoreBatchSomeColumn
closeSqlSession, currentMapperClass, executeBatch, executeBatch, executeBatch, getBaseMapper, getEntityClass, getMap, getObj, getOne, getSqlStatement, retBool, saveBatch, saveOrUpdate, saveOrUpdateBatch, sqlSessionBatch, sqlStatement, updateBatchById
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
alwaysUpdateSomeColumnById, deleteByIdWithFill, insertBatchSomeColumn, insertIgnoreBatchSomeColumn
selectJoinCount, selectJoinList, selectJoinListPage, selectJoinMap, selectJoinMaps, selectJoinMapsPage, selectJoinOne
currentModelClass, getByIdDeep, getByIdDeep, getByIdDeep, getMapDeep, getMapDeep, getMapDeep, getOneDeep, getOneDeep, getOneDeep, getOneDeep, getOneDeep, getOneDeep, listByIdsDeep, listByIdsDeep, listByIdsDeep, listByMapDeep, listByMapDeep, listByMapDeep, listDeep, listDeep, listDeep, listDeep, listDeep, listDeep, listMapsDeep, listMapsDeep, listMapsDeep, listMapsDeep, listMapsDeep, listMapsDeep, pageDeep, pageDeep, pageDeep, pageDeep, pageDeep, pageDeep, pageMapsDeep, pageMapsDeep, pageMapsDeep, pageMapsDeep, pageMapsDeep, pageMapsDeep
count, count, getBaseMapper, getById, getEntityClass, getMap, getObj, getOne, getOne, ktQuery, ktUpdate, lambdaQuery, lambdaUpdate, list, list, listByIds, listByMap, listMaps, listMaps, listObjs, listObjs, listObjs, listObjs, page, page, pageMaps, pageMaps, query, remove, removeById, removeByIds, removeByMap, save, saveBatch, saveBatch, saveOrUpdate, saveOrUpdate, saveOrUpdateBatch, saveOrUpdateBatch, update, update, update, updateBatchById, updateBatchById, updateById
public void recordUserRole(AuthorizationBO authorizationBO)
IUserRoleService
recordUserRole
在接口中 IUserRoleService
authorizationBO
- 授权信息public List<UserRoleBO> loadUserRole(Long userId)
IUserRoleService
loadUserRole
在接口中 IUserRoleService
userId
- 用户IDpublic Set<Long> loadRoleByUser(Long userId)
IUserRoleService
loadRoleByUser
在接口中 IUserRoleService
userId
- 用户IDpublic Set<Long> loadUserByRole(Long roleId)
IUserRoleService
loadUserByRole
在接口中 IUserRoleService
roleId
- 角色IDpublic int countUserByRole(Long roleId)
IUserRoleService
countUserByRole
在接口中 IUserRoleService
roleId
- 角色IDpublic void revokeRole(Long userId)
IUserRoleService
revokeRole
在接口中 IUserRoleService
userId
- 用户ID