Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
amos-boot-biz
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
项目统一框架
amos-boot-biz
Commits
238eb5ea
Commit
238eb5ea
authored
Apr 11, 2023
by
zhangyingbin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ugp修改获取当前登陆人角色接口逻辑
parent
7baf3beb
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
0 deletions
+7
-0
PipeController.java
...n/amos/boot/module/ugp/biz/controller/PipeController.java
+7
-0
No files found.
amos-boot-system-ugp/amos-boot-module-ugp-biz/src/main/java/com/yeejoin/amos/boot/module/ugp/biz/controller/PipeController.java
View file @
238eb5ea
...
...
@@ -18,6 +18,7 @@ import com.yeejoin.amos.component.feign.model.FeignClientResult;
import
com.yeejoin.amos.feign.privilege.Privilege
;
import
com.yeejoin.amos.feign.privilege.model.AgencyUserModel
;
import
com.yeejoin.amos.feign.privilege.model.CompanyModel
;
import
com.yeejoin.amos.feign.privilege.model.DepartmentModel
;
import
com.yeejoin.amos.feign.privilege.model.RoleModel
;
import
com.yeejoin.amos.feign.systemctl.Systemctl
;
import
com.yeejoin.amos.feign.systemctl.model.DictionarieValueModel
;
...
...
@@ -28,6 +29,7 @@ import org.springframework.util.ObjectUtils;
import
org.springframework.web.bind.annotation.*
;
import
org.typroject.tyboot.core.foundation.context.RequestContext
;
import
org.typroject.tyboot.core.foundation.enumeration.UserType
;
import
org.typroject.tyboot.core.foundation.utils.ValidationUtil
;
import
org.typroject.tyboot.core.restful.doc.TycloudOperation
;
import
org.typroject.tyboot.core.restful.utils.ResponseHelper
;
import
org.typroject.tyboot.core.restful.utils.ResponseModel
;
...
...
@@ -116,6 +118,11 @@ public class PipeController extends BaseController {
FeignClientResult
<
AgencyUserModel
>
agencyUserModelFeignClientResult
=
Privilege
.
agencyUserClient
.
queryByUserId
(
exeUserId
);
if
(!
ObjectUtils
.
isEmpty
(
agencyUserModelFeignClientResult
)
&&
!
ObjectUtils
.
isEmpty
(
agencyUserModelFeignClientResult
.
getResult
())
&&
!
ObjectUtils
.
isEmpty
(
agencyUserModelFeignClientResult
.
getResult
().
getOrgRoles
()))
{
Map
<
Long
,
List
<
RoleModel
>>
orgRoles
=
agencyUserModelFeignClientResult
.
getResult
().
getOrgRoles
();
Map
<
Long
,
List
<
DepartmentModel
>>
departmentModelList
=
agencyUserModelFeignClientResult
.
getResult
().
getCompanyDepartments
();
if
(!
ValidationUtil
.
isEmpty
(
departmentModelList
)
&&
!
ValidationUtil
.
isEmpty
(
departmentModelList
.
get
(
companyId
))){
List
<
DepartmentModel
>
departmentModels
=
departmentModelList
.
get
(
companyId
);
companyId
=
departmentModels
.
iterator
().
next
().
getSequenceNbr
();
}
if
(!
ObjectUtils
.
isEmpty
(
orgRoles
))
{
List
<
RoleModel
>
roleModels
=
orgRoles
.
get
(
companyId
);
return
ResponseHelper
.
buildResponse
(
roleModels
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment