From 5c0e0bf95df48c03c094400918b864aae795c6d3 Mon Sep 17 00:00:00 2001 From: Cagatay Civici Date: Thu, 4 Feb 2021 16:09:00 +0300 Subject: [PATCH] Fixed #939 - Optional chaining not working for TreeTable in version 3.2.1 --- src/components/treetable/TreeTable.vue | 10 +++++----- src/components/treetable/TreeTableRow.vue | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/components/treetable/TreeTable.vue b/src/components/treetable/TreeTable.vue index 0b3ed2e5d..13a8d0843 100755 --- a/src/components/treetable/TreeTable.vue +++ b/src/components/treetable/TreeTable.vue @@ -24,7 +24,7 @@ - + {{columnProp(col, 'header')}} {{getMultiSortMetaIndex(col) + 1}} @@ -32,14 +32,14 @@ - + - + {{columnProp(col, 'footer')}} @@ -773,7 +773,7 @@ export default { hasColumnFilter() { if (this.columns) { for (let col of this.columns) { - if (col.children?.filter) { + if (col.children && col.children.filter) { return true; } } @@ -858,7 +858,7 @@ export default { let hasFooter = false; for (let col of this.columns) { - if (this.columnProp(col, 'footer')|| col.children?.footer) { + if (this.columnProp(col, 'footer')|| (col.children && col.children.footer)) { hasFooter = true; break; } diff --git a/src/components/treetable/TreeTableRow.vue b/src/components/treetable/TreeTableRow.vue index 896f78bef..a04bbd464 100755 --- a/src/components/treetable/TreeTableRow.vue +++ b/src/components/treetable/TreeTableRow.vue @@ -12,7 +12,7 @@ - +