From 6657bbc9f11f22cbfb04a57f5629bc810575496e Mon Sep 17 00:00:00 2001 From: kailong321200875 <321200875@qq.com> Date: Thu, 20 Jun 2024 15:02:19 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E5=A4=8D=E8=A1=A8=E6=A0=BCdefa?= =?UTF-8?q?ult-expand-all=E5=B1=9E=E6=80=A7=E6=97=A0=E6=95=88BUG?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/Table/src/Table.vue | 11 +++++------ src/views/Components/Table/UseTableDemo.vue | 2 ++ 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/src/components/Table/src/Table.vue b/src/components/Table/src/Table.vue index 911cf48..9d496f0 100644 --- a/src/components/Table/src/Table.vue +++ b/src/components/Table/src/Table.vue @@ -89,7 +89,7 @@ export default defineComponent({ type: [Function, Object] as PropType< (row: Recordable, rowIndex: number) => Recordable | CSSProperties >, - default: () => undefined + default: undefined }, cellClassName: { type: [Function, String] as PropType< @@ -101,7 +101,7 @@ export default defineComponent({ type: [Function, Object] as PropType< (row: Recordable, column: any, rowIndex: number) => Recordable | CSSProperties >, - default: () => undefined + default: undefined }, headerRowClassName: { type: [Function, String] as PropType<(row: Recordable, rowIndex: number) => string | string>, @@ -111,7 +111,7 @@ export default defineComponent({ type: [Function, Object] as PropType< (row: Recordable, rowIndex: number) => Recordable | CSSProperties >, - default: () => undefined + default: undefined }, headerCellClassName: { type: [Function, String] as PropType< @@ -123,14 +123,14 @@ export default defineComponent({ type: [Function, Object] as PropType< (row: Recordable, column: any, rowIndex: number) => Recordable | CSSProperties >, - default: () => undefined + default: undefined }, rowKey: propTypes.string.def('id'), emptyText: propTypes.string.def('No Data'), defaultExpandAll: propTypes.bool.def(false), expandRowKeys: { type: Array as PropType, - default: () => [] + default: undefined }, defaultSort: { type: Object as PropType<{ prop: string; order: string }>, @@ -490,7 +490,6 @@ export default defineComponent({ if (props?.slots?.header) { slots['header'] = (...args: any[]) => props.slots.header(...args) } - return ( { v-model:currentPage="currentPage" showAction showSummary + default-expand-all :columns="columns" + row-key="id" :data="dataList" :loading="loading" :pagination="