From 879ddcc0ced3996591b708972d841dba4c687be0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tu=C4=9F=C3=A7e=20K=C3=BC=C3=A7=C3=BCko=C4=9Flu?= Date: Fri, 14 Jul 2023 10:34:51 +0300 Subject: [PATCH] Fixed #4138 - TreeTable: Sorting does not work when clicking at the header title --- components/lib/treetable/HeaderCell.vue | 2 +- components/lib/treetable/TreeTable.vue | 7 ++++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/components/lib/treetable/HeaderCell.vue b/components/lib/treetable/HeaderCell.vue index 9f7e06c4f..f3c50c41d 100644 --- a/components/lib/treetable/HeaderCell.vue +++ b/components/lib/treetable/HeaderCell.vue @@ -17,7 +17,7 @@ {{ columnProp('header') }} - + {{ getMultiSortMetaIndex() + 1 }} diff --git a/components/lib/treetable/TreeTable.vue b/components/lib/treetable/TreeTable.vue index 155c77632..117a60930 100755 --- a/components/lib/treetable/TreeTable.vue +++ b/components/lib/treetable/TreeTable.vue @@ -354,9 +354,10 @@ export default { if ( DomHandler.getAttribute(targetNode, 'data-p-sortable-column') === true || - DomHandler.getAttribute(targetNode, 'data-pc-section') === 'headerTitle' || - DomHandler.getAttribute(targetNode, 'data-pc-section') === 'sortIcon' || - DomHandler.getAttribute(targetNode.parentElement, 'data-pc-section') === 'sortIcon' + DomHandler.getAttribute(targetNode, 'data-pc-section') === 'headertitle' || + DomHandler.getAttribute(targetNode, 'data-pc-section') === 'sorticon' || + DomHandler.getAttribute(targetNode.parentElement, 'data-pc-section') === 'sorticon' || + DomHandler.getAttribute(targetNode.parentElement.parentElement, 'data-pc-section') === 'sorticon' ) { DomHandler.clearSelection();