From d23181c2f673a6f911a61572099cebb84a84d2d8 Mon Sep 17 00:00:00 2001
From: 田源 <lastanimals@163.com>
Date: 星期五, 18 八月 2023 10:22:33 +0800
Subject: [PATCH] 用户管理 新增bug
---
Source/UBCS/ubcs-service/ubcs-system/src/main/java/com/vci/ubcs/system/service/impl/RoleServiceImpl.java | 13 +++++++++++--
1 files changed, 11 insertions(+), 2 deletions(-)
diff --git a/Source/UBCS/ubcs-service/ubcs-system/src/main/java/com/vci/ubcs/system/service/impl/RoleServiceImpl.java b/Source/UBCS/ubcs-service/ubcs-system/src/main/java/com/vci/ubcs/system/service/impl/RoleServiceImpl.java
index a7ef5c4..8ec1b9b 100644
--- a/Source/UBCS/ubcs-service/ubcs-system/src/main/java/com/vci/ubcs/system/service/impl/RoleServiceImpl.java
+++ b/Source/UBCS/ubcs-service/ubcs-system/src/main/java/com/vci/ubcs/system/service/impl/RoleServiceImpl.java
@@ -24,10 +24,12 @@
import com.vci.ubcs.system.service.IRoleMenuService;
import com.vci.ubcs.system.service.IRoleScopeService;
import com.vci.ubcs.system.service.IRoleService;
+import com.vci.ubcs.system.vo.DeptVO;
import com.vci.ubcs.system.wrapper.RoleWrapper;
import lombok.AllArgsConstructor;
-import com.vci.ubcs.core.log.exception.ServiceException;
+import org.springblade.core.log.exception.ServiceException;
import org.springblade.core.secure.utils.AuthUtil;
+import org.springblade.core.tool.api.R;
import org.springblade.core.tool.constant.BladeConstant;
import org.springblade.core.tool.constant.RoleConstant;
import org.springblade.core.tool.node.ForestNodeMerger;
@@ -79,6 +81,13 @@
}
@Override
+ public List<RoleVO> roleList(String tenantId) {
+ // 杩欓噷鍒ゆ柇鎴戜滑鑷繁閰嶇疆鐨勭鐞嗙粍绉熸埛锛屽彲浠ユ煡璇㈡墍鏈�
+ List<RoleVO> tree = baseMapper.roleList(tenantId.equals(tenantId) ? "":tenantId);
+ return tree;
+ }
+
+ @Override
@Transactional(rollbackFor = Exception.class)
public boolean grant(@NotEmpty List<Long> roleIds, List<Long> menuIds, List<Long> dataScopeIds, List<Long> apiScopeIds) {
return grantRoleMenu(roleIds, menuIds) && grantDataScope(roleIds, dataScopeIds) && grantApiScope(roleIds, apiScopeIds);
@@ -166,7 +175,7 @@
if (roleList != null && roleList.size() > 0) {
return roleList.stream().map(role -> Func.toStr(role.getId())).distinct().collect(Collectors.joining(","));
}
- return null;
+ return "";
}
@Override
--
Gitblit v1.10.0