mirror of
https://github.com/vbenjs/vue-vben-admin.git
synced 2025-08-26 08:36:19 +08:00
wip: system management sample page
This commit is contained in:
@@ -4,12 +4,21 @@ export type AccountParams = BasicPageParams & {
|
||||
account?: string;
|
||||
nickname?: string;
|
||||
};
|
||||
export type RoleParams = BasicPageParams & {
|
||||
roleName?: string;
|
||||
status?: string;
|
||||
};
|
||||
|
||||
export type DeptParams = {
|
||||
deptName?: string;
|
||||
status?: string;
|
||||
};
|
||||
|
||||
export type MenuParams = {
|
||||
menuName?: string;
|
||||
status?: string;
|
||||
};
|
||||
|
||||
export interface AccountListItem {
|
||||
id: string;
|
||||
account: string;
|
||||
@@ -29,9 +38,32 @@ export interface DeptListItem {
|
||||
status: number;
|
||||
}
|
||||
|
||||
export interface MenuListItem {
|
||||
id: string;
|
||||
orderNo: string;
|
||||
createTime: string;
|
||||
status: number;
|
||||
icon: string;
|
||||
component: string;
|
||||
permission: string;
|
||||
}
|
||||
|
||||
export interface RoleListItem {
|
||||
id: string;
|
||||
roleName: string;
|
||||
roleValue: string;
|
||||
status: number;
|
||||
orderNo: string;
|
||||
createTime: string;
|
||||
}
|
||||
|
||||
/**
|
||||
* @description: Request list return value
|
||||
*/
|
||||
export type AccountListGetResultModel = BasicFetchResult<AccountListItem>;
|
||||
|
||||
export type DeptListGetResultModel = BasicFetchResult<DeptListItem>;
|
||||
|
||||
export type MenuListGetResultModel = BasicFetchResult<MenuListItem>;
|
||||
|
||||
export type RoleListGetResultModel = BasicFetchResult<RoleListItem>;
|
||||
|
@@ -1,15 +1,20 @@
|
||||
import {
|
||||
AccountParams,
|
||||
DeptListItem,
|
||||
MenuParams,
|
||||
RoleParams,
|
||||
MenuListGetResultModel,
|
||||
DeptListGetResultModel,
|
||||
AccountListGetResultModel,
|
||||
RoleListGetResultModel,
|
||||
} from './model/systemModel';
|
||||
import { defHttp } from '/@/utils/http/axios';
|
||||
|
||||
enum Api {
|
||||
// The address does not exist
|
||||
AccountList = '/system/getAccountList',
|
||||
DeptList = '/system/getDeptList',
|
||||
MenuList = '/system/getMenuList',
|
||||
RoleList = '/system/getRoleList',
|
||||
}
|
||||
|
||||
export const getAccountList = (params: AccountParams) =>
|
||||
@@ -17,3 +22,9 @@ export const getAccountList = (params: AccountParams) =>
|
||||
|
||||
export const getDeptList = (params?: DeptListItem) =>
|
||||
defHttp.get<DeptListGetResultModel>({ url: Api.DeptList, params });
|
||||
|
||||
export const getMenuList = (params?: MenuParams) =>
|
||||
defHttp.get<MenuListGetResultModel>({ url: Api.MenuList, params });
|
||||
|
||||
export const getRoleList = (params?: RoleParams) =>
|
||||
defHttp.get<RoleListGetResultModel>({ url: Api.RoleList, params });
|
||||
|
Reference in New Issue
Block a user