🔱: [client] sync upgrade with 2 commits [trident-sync]

perf: 新增editable-select组件
pull/349/head
GitHub Actions Bot 2025-04-23 19:25:19 +00:00
parent ec01f47b98
commit c7a3bc9eac
3 changed files with 28 additions and 0 deletions

View File

@ -250,6 +250,26 @@ export default async function ({ crudExpose }: CreateCrudOptionsProps): Promise<
}
}
}
},
editable: {
title: "可编辑选择",
search: { show: true },
type: "editable-select",
dict: dict({
value: "id",
label: "name",
async getData() {
return await textTableApi.GetAll();
}
}),
form: {
component: {
tableSelect: {
createCrudOptions: createCrudOptionsText,
crudOptionsOverride
}
}
}
}
}
}

View File

@ -48,3 +48,10 @@ export function GetByIds(ids: any) {
data: { ids }
});
}
export function GetAll() {
return request({
url: apiPrefix + "/all",
method: "get"
});
}

View File

@ -45,5 +45,6 @@ const list = [
}
];
options.list = list;
options.copyTimes = 5;
const mock = mockUtil.buildMock(options);
export default mock;