| | |
| | | return success(permissionService.getRoleMenuListByRoleId(roleId)); |
| | | } |
| | | |
| | | @Operation(summary = "获得角色拥有的菜单编号") |
| | | @Parameter(name = "roleId", description = "角色编号", required = true) |
| | | @GetMapping("/list-role-app-menus") |
| | | @PreAuthorize("@ss.hasPermission('system:permission:assign-role-menu')") |
| | | public CommonResult<Set<Long>> getRoleAppMenuList(Long roleId) { |
| | | return success(permissionService.getRoleAppMenuListByRoleId(roleId)); |
| | | } |
| | | |
| | | @PostMapping("/assign-role-menu") |
| | | @Operation(summary = "赋予角色菜单") |
| | | @PreAuthorize("@ss.hasPermission('system:permission:assign-role-menu')") |
| | |
| | | return success(true); |
| | | } |
| | | |
| | | // @PostMapping("/assign-role-app-menu") |
| | | // @Operation(summary = "赋予角色菜单") |
| | | // @PreAuthorize("@ss.hasPermission('system:permission:assign-role-menu')") |
| | | // public CommonResult<Boolean> assignRoleAppMenu(@Validated @RequestBody PermissionAssignRoleMenuReqVO reqVO) { |
| | | // // 执行菜单的分配 |
| | | // permissionService.assignRoleAppMenu(reqVO.getRoleId(), reqVO.getMenuIds()); |
| | | // return success(true); |
| | | // } |
| | | |
| | | @PostMapping("/assign-role-data-scope") |
| | | @Operation(summary = "赋予角色数据权限") |
| | | @PreAuthorize("@ss.hasPermission('system:permission:assign-role-data-scope')") |