diff --git a/src/components/core/draggable-modal/index.vue b/src/components/core/draggable-modal/index.vue index 5e0b7ba74..ce47f8901 100644 --- a/src/components/core/draggable-modal/index.vue +++ b/src/components/core/draggable-modal/index.vue @@ -4,7 +4,7 @@
diff --git a/src/components/core/schema-form/src/types/form.ts b/src/components/core/schema-form/src/types/form.ts index 931f175f5..63879042c 100644 --- a/src/components/core/schema-form/src/types/form.ts +++ b/src/components/core/schema-form/src/types/form.ts @@ -64,20 +64,12 @@ type ComponentSchema = /** 表单组件属性 */ componentProps?: | ComponentProps - | { - (opt: RenderCallbackParams>): ComponentProps; - requestResult: ComponentProps['requestResult']; - }; + | ((opt: RenderCallbackParams>) => ComponentProps); }; }[ComponentType] | { component: CustomRenderFn | ((opt: RenderCallbackParams) => Component); - componentProps?: - | ComponentProps - | { - (opt: RenderCallbackParams): ComponentProps; - requestResult: ComponentProps['requestResult']; - }; + componentProps?: ComponentProps | ((opt: RenderCallbackParams) => ComponentProps); }; /** 表单项 */ diff --git a/src/router/routes/modules/demos.ts b/src/router/routes/modules/demos.ts index 9978de69c..dcc5298b9 100644 --- a/src/router/routes/modules/demos.ts +++ b/src/router/routes/modules/demos.ts @@ -161,7 +161,7 @@ const routes: Array = [ meta: { title: '英雄详情', icon: 'ant-design:desktop-outlined', - hideInMenu: false, + hideInMenu: true, keepAlive: false, activeMenu: `${moduleName}-table-lol`, }, diff --git a/src/views/demos/tables/edit-row-table/columns.tsx b/src/views/demos/tables/edit-row-table/columns.tsx index 4dabc8890..9f38bf8df 100644 --- a/src/views/demos/tables/edit-row-table/columns.tsx +++ b/src/views/demos/tables/edit-row-table/columns.tsx @@ -17,7 +17,6 @@ export type ListItemType = (typeof tableData)[number]; export const columns: TableColumn[] = [ { title: '姓名', - dataIndex: 'name', sorter: true, /** 默认开启编辑, 仅`editableType`为`cell`时有效 */ @@ -38,7 +37,6 @@ export const columns: TableColumn[] = [ }, { title: '性别', - dataIndex: 'gender', /** 搜索表单配置 */ formItemProps: { @@ -75,8 +73,6 @@ export const columns: TableColumn[] = [ rules: [{ required: true, type: 'number', message: '请选择性别' }], componentProps: ({ formInstance, formModel, tableRowKey }) => ({ onChange() { - console.log('formModel', formModel); - // 根据当前选择的性别,更新衣服可选项 formInstance?.updateSchema({ field: `${tableRowKey}.clothes`, @@ -92,7 +88,6 @@ export const columns: TableColumn[] = [ }, { title: '衣服', - dataIndex: 'clothes', formItemProps: { component: 'Select', @@ -136,7 +131,6 @@ export const columns: TableColumn[] = [ }, { title: '价格', - dataIndex: 'price', editFormItemProps: { component: 'InputNumber', @@ -146,7 +140,6 @@ export const columns: TableColumn[] = [ }, { title: '状态', - dataIndex: 'status', formItemProps: { component: 'Select', diff --git a/src/views/system/role/index.vue b/src/views/system/role/index.vue index 8ecdaac4f..3faae3114 100644 --- a/src/views/system/role/index.vue +++ b/src/views/system/role/index.vue @@ -113,7 +113,9 @@ perm: 'system:role:update', effect: 'disable', }, - onClick: () => openMenuModal(record), + onClick: () => { + openMenuModal(record); + }, }, { label: '删除',