Skip to content

Commit 03f5287

Browse files
committed
add flow user list permission to developer
1 parent fcf5adf commit 03f5287

File tree

2 files changed

+1
-7
lines changed

2 files changed

+1
-7
lines changed

core/src/main/java/com/flowci/core/auth/config/AuthConfig.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ public PermissionMap actionMap() {
5555

5656
// developer
5757
permissionMap.add(User.Role.Developer,
58-
FlowAction.GET, FlowAction.LIST, FlowAction.LIST_BRANCH, FlowAction.GET, FlowAction.GET_YML);
58+
FlowAction.GET, FlowAction.LIST, FlowAction.LIST_BRANCH, FlowAction.GET, FlowAction.GET_YML, FlowAction.LIST_USER);
5959
permissionMap.add(User.Role.Developer, JobAction.ALL);
6060
permissionMap.add(User.Role.Developer, SecretActions.LIST_NAME);
6161
permissionMap.add(User.Role.Developer, AgentAction.GET, AgentAction.LIST);

core/src/main/java/com/flowci/core/user/UserController.java

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -64,12 +64,6 @@ public void createDefaultAdmin(@Validated @RequestBody CreateUser body) {
6464
userService.createDefaultAdmin(body.getEmail(), body.getPasswordOnMd5());
6565
}
6666

67-
@GetMapping("/actions")
68-
public Collection<String> actions() {
69-
User user = sessionManager.get();
70-
return authService.getActions(user.getRole());
71-
}
72-
7367
@GetMapping
7468
@Action(UserAction.LIST_ALL)
7569
public Page<User> listAll(@RequestParam(required = false, defaultValue = DefaultPage) int page,

0 commit comments

Comments
 (0)