Commit f0640d27434d1d76b7e4fc5f55bf9f270ad72d95
1 parent
c1002ac3a3
Exists in
master
and in
1 other branch
bug fix
Showing 1 changed file with 5 additions and 3 deletions
platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/UsersController.java
View file @
f0640d2
... | ... | @@ -380,15 +380,17 @@ |
380 | 380 | |
381 | 381 | List<Organization> organizations = new ArrayList<>(); |
382 | 382 | if(null != users.getOrgId() && UserTypeEnum.NORMAL_USER.getId().equals(users.getType())) { //普通用户 |
383 | - organizations.add(organizationService.getOrganization(users.getOrgId())); | |
384 | - } else if(UserTypeEnum.PLATFORM_ADMIN.getId().equals(users.getType())) { //管理员 | |
383 | + Organization organization = organizationService.getOrganization(users.getOrgId()); | |
384 | + organizations.add(organization); | |
385 | + users.setOrganization(organization); | |
386 | + } else if (UserTypeEnum.PLATFORM_ADMIN.getId().equals(users.getType())) { //管理员 | |
385 | 387 | List<Organization> list2 =accessPermissionFacade.findAccessPerminssionByUserId(users.getId()); |
386 | 388 | if(CollectionUtils.isNotEmpty(list2)){ |
387 | 389 | for(Organization organization:list2){ |
388 | 390 | organizations.add(organization); |
389 | 391 | } |
390 | 392 | } |
391 | - } else if(UserTypeEnum.SUPPER_ADMIN.getId().equals(users.getType())) {//超级管理员 | |
393 | + } else if (UserTypeEnum.SUPPER_ADMIN.getId().equals(users.getType())) {//超级管理员 | |
392 | 394 | OrganizationQuery organizationQuery = new OrganizationQuery(); |
393 | 395 | organizationQuery.setYn(YnEnums.YES.getId()); |
394 | 396 | organizations = organizationService.queryOrganization(organizationQuery); |