From bd95effa76daa6e0937b9f6c6dbf4c75311209ff Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=A2=81=E7=81=8F?= Date: Fri, 18 Sep 2020 11:40:10 +0800 Subject: [PATCH] fix #675 --- src/components/table/table.vue | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/components/table/table.vue b/src/components/table/table.vue index 31886d75..e9145899 100644 --- a/src/components/table/table.vue +++ b/src/components/table/table.vue @@ -274,6 +274,11 @@ loadData: { type: Function }, + // 4.4.0 + updateShowChildren: { + type: Boolean, + default: false + }, // 4.1.0 contextMenu: { type: Boolean, @@ -851,7 +856,8 @@ data._isShowChildren = !data._isShowChildren; // 由于 updateDataStatus 是基于原数据修改,导致单选、多选等状态重置,所以暂不处理 _showChildren 状态,而是通过事件 @on-expand-tree - // this.updateDataStatus(rowKey, '_showChildren', data._isShowChildren); + // #675,增加 updateShowChildren + if (this.updateShowChildren) this.updateDataStatus(rowKey, '_showChildren', data._isShowChildren); this.$emit('on-expand-tree', rowKey, data._isShowChildren); }, /**