This commit is contained in:
61
apps/web-antd/src/api/system/funList/index.ts
Normal file
61
apps/web-antd/src/api/system/funList/index.ts
Normal file
@@ -0,0 +1,61 @@
|
||||
import type { FunListVO, FunListForm, FunListQuery } from './model';
|
||||
|
||||
import type { ID, IDS } from '#/api/common';
|
||||
import type { PageResult } from '#/api/common';
|
||||
|
||||
import { commonExport } from '#/api/helper';
|
||||
import { requestClient } from '#/api/request';
|
||||
|
||||
/**
|
||||
* 查询APP功能列表列表
|
||||
* @param params
|
||||
* @returns APP功能列表列表
|
||||
*/
|
||||
export function funListList(params?: FunListQuery) {
|
||||
return requestClient.get<PageResult<FunListVO>>('/system/funList/list', { params });
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出APP功能列表列表
|
||||
* @param params
|
||||
* @returns APP功能列表列表
|
||||
*/
|
||||
export function funListExport(params?: FunListQuery) {
|
||||
return commonExport('/system/funList/export', params ?? {});
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询APP功能列表详情
|
||||
* @param id id
|
||||
* @returns APP功能列表详情
|
||||
*/
|
||||
export function funListInfo(id: ID) {
|
||||
return requestClient.get<FunListVO>(`/system/funList/${id}`);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增APP功能列表
|
||||
* @param data
|
||||
* @returns void
|
||||
*/
|
||||
export function funListAdd(data: FunListForm) {
|
||||
return requestClient.postWithMsg<void>('/system/funList', data);
|
||||
}
|
||||
|
||||
/**
|
||||
* 更新APP功能列表
|
||||
* @param data
|
||||
* @returns void
|
||||
*/
|
||||
export function funListUpdate(data: FunListForm) {
|
||||
return requestClient.putWithMsg<void>('/system/funList', data);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除APP功能列表
|
||||
* @param id id
|
||||
* @returns void
|
||||
*/
|
||||
export function funListRemove(id: ID | IDS) {
|
||||
return requestClient.deleteWithMsg<void>(`/system/funList/${id}`);
|
||||
}
|
84
apps/web-antd/src/api/system/funList/model.d.ts
vendored
Normal file
84
apps/web-antd/src/api/system/funList/model.d.ts
vendored
Normal file
@@ -0,0 +1,84 @@
|
||||
import type { PageQuery, BaseEntity } from '#/api/common';
|
||||
|
||||
export interface FunListVO {
|
||||
/**
|
||||
* 主键
|
||||
*/
|
||||
id: string | number;
|
||||
|
||||
/**
|
||||
* 角色id
|
||||
*/
|
||||
roleid: string | number;
|
||||
|
||||
/**
|
||||
* 名称
|
||||
*/
|
||||
name: string;
|
||||
|
||||
/**
|
||||
* icon
|
||||
*/
|
||||
icon: string;
|
||||
|
||||
/**
|
||||
* url
|
||||
*/
|
||||
url: string;
|
||||
|
||||
}
|
||||
|
||||
export interface FunListForm extends BaseEntity {
|
||||
/**
|
||||
* 主键
|
||||
*/
|
||||
id?: string | number;
|
||||
|
||||
/**
|
||||
* 角色id
|
||||
*/
|
||||
roleid?: string | number;
|
||||
|
||||
/**
|
||||
* 名称
|
||||
*/
|
||||
name?: string;
|
||||
|
||||
/**
|
||||
* icon
|
||||
*/
|
||||
icon?: string;
|
||||
|
||||
/**
|
||||
* url
|
||||
*/
|
||||
url?: string;
|
||||
|
||||
}
|
||||
|
||||
export interface FunListQuery extends PageQuery {
|
||||
/**
|
||||
* 角色id
|
||||
*/
|
||||
roleid?: string | number;
|
||||
|
||||
/**
|
||||
* 名称
|
||||
*/
|
||||
name?: string;
|
||||
|
||||
/**
|
||||
* icon
|
||||
*/
|
||||
icon?: string;
|
||||
|
||||
/**
|
||||
* url
|
||||
*/
|
||||
url?: string;
|
||||
|
||||
/**
|
||||
* 日期范围参数
|
||||
*/
|
||||
params?: any;
|
||||
}
|
Reference in New Issue
Block a user