refactor: ♻️ 方法和接口名优化

This commit is contained in:
ray
2024-08-02 08:04:12 +08:00
parent fe35745f7f
commit 0883a500c1

View File

@@ -52,9 +52,9 @@ class GeneratorAPI {
* @param url * @param url
* @param fileName * @param fileName
*/ */
static downloadZip(tableName: string, fileName?: string) { static download(tableName: string, fileName?: string) {
return request({ return request({
url: `${GENERATOR_BASE_URL}/${tableName}/downloadZip`, url: `${GENERATOR_BASE_URL}/${tableName}/download`,
method: "get", method: "get",
responseType: "blob", responseType: "blob",
}).then((res) => { }).then((res) => {
@@ -131,15 +131,12 @@ export interface GenConfigForm {
/** 上级菜单 */ /** 上级菜单 */
parentMenuId?: number; parentMenuId?: number;
/** 字段排序 */
fieldSort?: number;
/** 字段配置列表 */ /** 字段配置列表 */
fieldConfigs?: FieldConfig[]; fieldConfigs?: FieldConfig[];
} }
/** 字段配置 */ /** 字段配置 */
interface FieldConfig { export interface FieldConfig {
/** 主键 */ /** 主键 */
id?: number; id?: number;
@@ -178,4 +175,7 @@ interface FieldConfig {
/** 字段长度 */ /** 字段长度 */
maxLength?: number; maxLength?: number;
/** 字段排序 */
fieldSort?: number;
} }