tags:
- name: Menu
description: '管理中心菜单'
+ - name: Permission
+ description: '云平台权限'
paths:
'/menus/accountName/{accountName}/menus':
$ref: '#/components/responses/DefaultErrorResponse'
+ '/permissions/accountName/{accountName}/permissions':
+ get:
+ summary: 获取用户帐号拥有的权限
+ description: 获取用户帐号拥有的权限
+ operationId: loadAccountPermissions
+ tags:
+ - Permission
+ security:
+ - oauth2:
+ - "admincenter:v1:readAdminCenterPermission"
+ parameters:
+ - name: accountName
+ in: path
+ required: true
+ description: 用户名
+ schema:
+ type: string
+ - name: applicationId
+ in: query
+ required: false
+ description: 应用标识
+ schema:
+ type: string
+ responses:
+ '200':
+ description: 权限(菜单、操作、资源)列表
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/GrantedPermissionsResponse'
+ default:
+ $ref: '#/components/responses/DefaultErrorResponse'
+
+
+ '/permissions/accountName/{accountName}/menus':
+ get:
+ summary: 获取用户帐号拥有的菜单
+ description: 获取用户帐号拥有的菜单
+ operationId: loadAccountPermissionMenus
+ tags:
+ - Permission
+ security:
+ - oauth2:
+ - "admincenter:v1:readAdminCenterPermission"
+ parameters:
+ - name: accountName
+ in: path
+ required: true
+ description: 用户名
+ schema:
+ type: string
+ - name: applicationId
+ in: query
+ required: false
+ description: 应用标识
+ schema:
+ type: string
+ responses:
+ '200':
+ description: 权限(菜单)列表
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/GrantedMenusResponse'
+ default:
+ $ref: '#/components/responses/DefaultErrorResponse'
+
+ '/permissions/accountName/{accountName}/operations':
+ get:
+ summary: 获取用户帐号拥有的操作
+ description: 获取用户帐号拥有的操作
+ operationId: loadAccountPermissionOperations
+ tags:
+ - Permission
+ security:
+ - oauth2:
+ - "admincenter:v1:readAdminCenterPermission"
+ parameters:
+ - name: accountName
+ in: path
+ required: true
+ description: 用户名
+ schema:
+ type: string
+ - name: applicationId
+ in: query
+ required: false
+ description: 应用标识
+ schema:
+ type: string
+ responses:
+ '200':
+ description: 权限(操作)列表
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/GrantedOperationsResponse'
+ default:
+ $ref: '#/components/responses/DefaultErrorResponse'
+
+ '/permissions/accountName/{accountName}/resources':
+ get:
+ summary: 获取用户帐号拥有的资源
+ description: 获取用户帐号拥有的资源
+ operationId: loadAccountPermissionResources
+ tags:
+ - Permission
+ security:
+ - oauth2:
+ - "admincenter:v1:readAdminCenterPermission"
+ parameters:
+ - name: accountName
+ in: path
+ required: true
+ description: 用户名
+ schema:
+ type: string
+ - name: applicationId
+ in: query
+ required: false
+ description: 应用标识
+ schema:
+ type: string
+ responses:
+ '200':
+ description: 菜单列表
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/GrantedResourcesResponse'
+ default:
+ $ref: '#/components/responses/DefaultErrorResponse'
+
+
components:
# Security Schemes
tokenUrl: ${POA_SERVER_URL}/oauth2/token
scopes:
"admincenter:v1:readMenu": "读取后台菜单"
+ "admincenter:v1:readAdminCenterPermission": "读取权限"
responses:
'ErrorResponse400':
status:
title: 状态(1 启用,0 停用)
type: string
+ applicationId:
+ title: 系统ID
+ type: string
+ parentId:
+ title: 父级ID
+ type: string
icon:
title: 菜单图标
type: string
url:
title: URL地址
type: string
+ order:
+ title: 排序
+ type: integer
+ format: int32
+
+ GrantedOperation:
+ title: DTO - 操作数据
+ type: object
+ properties:
+ id:
+ title: ID
+ type: string
+ code:
+ title: 代码
+ type: string
+ name:
+ title: 名称
+ type: string
+ memo:
+ title: 备注
+ type: string
+ status:
+ title: 状态(1 启用,0 停用)
+ type: string
applicationId:
title: 系统ID
type: string
type: string
order:
title: 排序
+ type: integer
+ format: int32
+
+ GrantedResource:
+ title: DTO - 资源数据
+ type: object
+ properties:
+ id:
+ title: ID
+ type: string
+ code:
+ title: 代码
+ type: string
+ name:
+ title: 名称
+ type: string
+ memo:
+ title: 备注
+ type: string
+ status:
+ title: 状态(1 启用,0 停用)
+ type: string
+ applicationId:
+ title: 系统ID
+ type: string
+ origin:
+ title: 来源系统
+ type: string
+ method:
+ title: 请求方式(GET、POST、PUT、DELETE 等)
+ type: string
+ path:
+ title: 请求路径
+ type: string
+ access:
+ title: 访问规则(匿名访问anonymous、认证访问authenticate、授权访问authorize、允许所有permitAll、拒绝所有denyAll)
type: string
items:
$ref: '#/components/schemas/GrantedMenu'
+ GrantedOperationsResponseData:
+ title: 响应数据 - 操作列表
+ type: object
+ properties:
+ operations:
+ title: 操作列表
+ type: array
+ items:
+ $ref: '#/components/schemas/GrantedOperation'
+
+ GrantedResourcesResponseData:
+ title: 响应数据 - 资源列表
+ type: object
+ properties:
+ resource:
+ title: 资源列表
+ type: array
+ items:
+ $ref: '#/components/schemas/GrantedResource'
+
+ GrantedPermissionsResponseData:
+ title: 响应数据 - 权限列表
+ type: object
+ properties:
+ menus:
+ title: 菜单列表
+ type: array
+ items:
+ $ref: '#/components/schemas/GrantedMenu'
+ operations:
+ title: 操作列表
+ type: array
+ items:
+ $ref: '#/components/schemas/GrantedOperation'
+ resource:
+ title: 资源列表
+ type: array
+ items:
+ $ref: '#/components/schemas/GrantedResource'
+
# Response VO
data:
allOf:
- $ref: '#/components/schemas/GrantedMenusResponseData'
+
+ GrantedOperationsResponse:
+ allOf:
+ - $ref: '#/components/schemas/DefaultApiDataResponse'
+ - type: object
+ title: 响应
+ properties:
+ data:
+ allOf:
+ - $ref: '#/components/schemas/GrantedOperationsResponseData'
+
+ GrantedResourcesResponse:
+ allOf:
+ - $ref: '#/components/schemas/DefaultApiDataResponse'
+ - type: object
+ title: 响应
+ properties:
+ data:
+ allOf:
+ - $ref: '#/components/schemas/GrantedResourcesResponseData'
+
+ GrantedPermissionsResponse:
+ allOf:
+ - $ref: '#/components/schemas/DefaultApiDataResponse'
+ - type: object
+ title: 响应
+ properties:
+ data:
+ allOf:
+ - $ref: '#/components/schemas/GrantedPermissionsResponseData'