perf(form): improve the form function

This commit is contained in:
vben
2020-12-27 22:25:35 +08:00
parent 4ff1c408dc
commit ac1a369502
23 changed files with 344 additions and 100 deletions

View File

@@ -0,0 +1,11 @@
import { BasicFetchResult } from '/@/api/model/baseModel';
export interface DemoOptionsItem {
label: string;
value: string;
}
/**
* @description: Request list return value
*/
export type DemoOptionsGetResultModel = BasicFetchResult<DemoOptionsItem[]>;

16
src/api/demo/select.ts Normal file
View File

@@ -0,0 +1,16 @@
import { defHttp } from '/@/utils/http/axios';
import { DemoOptionsGetResultModel } from './model/optionsModel';
enum Api {
OPTIONS_LIST = '/select/getDemoOptions',
}
/**
* @description: Get sample options value
*/
export function optionsListApi() {
return defHttp.request<DemoOptionsGetResultModel>({
url: Api.OPTIONS_LIST,
method: 'GET',
});
}