Skip to content

Commit

Permalink
feat:用户个人视角 权限管理优化 #11138
Browse files Browse the repository at this point in the history
  • Loading branch information
fcfang123 committed Dec 5, 2024
1 parent 43d760f commit 0cd7240
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,9 @@ interface UserAuthResourceGroupResource {
@Parameter(description = "项目ID", required = true)
@PathParam("projectId")
projectId: String,
@Parameter(description = "资源类型", required = true)
@PathParam("resourceType")
resourceType: String,
@Parameter(description = "用户组Id")
@PathParam("groupId")
groupId: Int,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,7 @@ class UserAuthResourceGroupResourceImpl @Autowired constructor(
override fun getMemberGroupDetails(
userId: String,
projectId: String,
resourceType: String,
groupId: Int,
memberId: String
): Result<GroupDetailsInfoVo> {
Expand All @@ -129,8 +130,9 @@ class UserAuthResourceGroupResourceImpl @Autowired constructor(
permissionManageFacadeService.getMemberGroupsDetails(
projectId = projectId,
memberId = memberId,
resourceType = resourceType,
iamGroupIds = listOf(groupId)
).records.first { it.groupId == groupId || it.joinedType == JoinedType.DIRECT }
).records.first { it.groupId == groupId || it.joinedType == JoinedType.DIRECT }
)
}

Expand Down

0 comments on commit 0cd7240

Please sign in to comment.