feat(code): 代码生成新增 curd 页面模板和优化

This commit is contained in:
Ray.Hao
2025-08-21 18:09:07 +08:00
parent 2accc6a489
commit 9152ab654d
12 changed files with 227 additions and 79 deletions

View File

@@ -29,11 +29,11 @@ const ${entityName}API = {
*
* @param data ${businessName}表单数据
*/
add(data: ${entityName}Form) {
create(data: ${entityName}Form) {
return request({
url: `${${entityName.toUpperCase()}_BASE_URL}`,
method: "post",
data: data,
data,
});
},
@@ -43,11 +43,11 @@ const ${entityName}API = {
* @param id ${businessName}ID
* @param data ${businessName}表单数据
*/
update(id: number, data: ${entityName}Form) {
update(id: string, data: ${entityName}Form) {
return request({
url: `${${entityName.toUpperCase()}_BASE_URL}/${id}`,
method: "put",
data: data,
data,
});
},