| | |
| | | } |
| | | |
| | | /** |
| | | * 保存用户角色关联关系 |
| | | * 成员管理分配角色调用,保存用户角色关联关系 |
| | | * @param userOids |
| | | * @param roleIds |
| | | * @return |
| | |
| | | public boolean saveRights(String[] userOids, String[] roleIds) throws PLException { |
| | | VciBaseUtil.alertNotNull(userOids,"用户主键"); |
| | | //roleIds允许为空,为空时清空当前用户的权限 |
| | | return platformClientUtil.getFrameworkService().saveRights(roleIds,userOids,new UserEntityInfo()); |
| | | UserEntityInfo userEntityInfo = new UserEntityInfo(WebThreadLocalUtil.getCurrentUserSessionInfoInThread().getUserId(),null); |
| | | return platformClientUtil.getFrameworkService().saveRights(roleIds,userOids,userEntityInfo); |
| | | } |
| | | |
| | | /** |
| | | * 角色管理分配成员接口调用 |
| | | * @param userOids |
| | | * @param roleId |
| | | * @return |
| | | * @throws PLException |
| | | */ |
| | | @Override |
| | | public boolean saveRight(String[] userOids, String roleId) throws PLException { |
| | | VciBaseUtil.alertNotNull(roleId,"角色主键"); |
| | | //roleIds允许为空,为空时清空当前用户的权限 |
| | | UserEntityInfo userEntityInfo = new UserEntityInfo(WebThreadLocalUtil.getCurrentUserSessionInfoInThread().getUserId(),null); |
| | | return platformClientUtil.getFrameworkService().saveRight(roleId,userOids,userEntityInfo); |
| | | } |
| | | |
| | | /** |
| | |
| | | smRoleDTO.getName(),"角色名"); |
| | | //查询数据库中的,根据角色名查 |
| | | Map<String, String> conditionMap = new HashMap<>(); |
| | | conditionMap.put("pluid",smRoleDTO.getOid()); |
| | | conditionMap.put("plname",smRoleDTO.getName()); |
| | | SmRoleVO dbSmRoleVO = getRoleByConditionMap(conditionMap); |
| | | //根据主键没查询到了用户 |
| | | if(Func.isEmpty(dbSmRoleVO) || Func.isBlank(dbSmRoleVO.getOid())){ |