Skip to content

Commit e774b28

Browse files
committed
fix(igxTreeGrid): Fixes data selection when a row is pinned #6640
1 parent f9ec7e5 commit e774b28

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

projects/igniteui-angular/src/lib/grids/tree-grid/tree-grid.component.ts

+2-1
Original file line numberDiff line numberDiff line change
@@ -645,7 +645,7 @@ export class IgxTreeGridComponent extends IgxGridBaseDirective implements GridTy
645645
* @inheritdoc
646646
*/
647647
getSelectedData(formatters = false, headers = false): any[] {
648-
const source = [];
648+
let source = [];
649649

650650
const process = (record) => {
651651
if (record.summaries) {
@@ -656,6 +656,7 @@ export class IgxTreeGridComponent extends IgxGridBaseDirective implements GridTy
656656
};
657657

658658
this.dataView.forEach(process);
659+
source = this.isRowPinningToTop ? [...this.pinnedDataView, ...source] : [...source, ...this.pinnedDataView];
659660
return this.extractDataFromSelection(source, formatters, headers);
660661
}
661662

0 commit comments

Comments
 (0)