mirror of
https://github.com/continew-org/continew-admin-ui.git
synced 2025-11-03 02:57:09 +08:00
feat: 角色管理增加授权用户功能 (#33)
This commit is contained in:
@@ -9,7 +9,10 @@ const BASE_URL = '/common'
|
||||
export function listDeptTree(query: { description: string }) {
|
||||
return http.get<TreeNodeData[]>(`${BASE_URL}/tree/dept`, query)
|
||||
}
|
||||
|
||||
/** @desc 查询部门用户树 */
|
||||
export function listDeptWithUsersTree(query: { description?: string, status: number }) {
|
||||
return http.get<TreeNodeData[]>(`${BASE_URL}/tree/deptWithUsers`, query)
|
||||
}
|
||||
/** @desc 查询菜单树 */
|
||||
export function listMenuTree(query: { description: string }) {
|
||||
return http.get<TreeNodeData[]>(`${BASE_URL}/tree/menu`, query)
|
||||
|
||||
@@ -29,3 +29,11 @@ export function updateRole(data: any, id: string) {
|
||||
export function deleteRole(ids: string | Array<string>) {
|
||||
return http.del(`${BASE_URL}/${ids}`)
|
||||
}
|
||||
/** @desc 获取角色绑定的用户列表 */
|
||||
export function listRoleUsers(id: string) {
|
||||
return http.get(`${BASE_URL}/listRoleUsers/${id}`)
|
||||
}
|
||||
|
||||
export function bindUsers(id: string, userIds : Array<string>) {
|
||||
return http.post(`${BASE_URL}/bindUsers/${id}`,userIds)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user