Skip to content

Commit cbf4a1c

Browse files
MKirovaMKirova
authored andcommitted
chore(*): Update merge indexes when in a paged grid context.
1 parent 9cc56b6 commit cbf4a1c

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

projects/igniteui-angular/src/lib/grids/grid-base.directive.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7985,7 +7985,12 @@ export abstract class IgxGridBaseDirective implements GridType,
79857985
const searchText = caseSensitive ? this._lastSearchInfo.searchText : this._lastSearchInfo.searchText.toLowerCase();
79867986
let data = this.filteredSortedData;
79877987
if (this.hasCellsToMerge) {
7988-
data = DataUtil.merge(cloneArray(this.filteredSortedData), this.columnsToMerge, this.mergeStrategy, this.activeRowIndexes, this);
7988+
let indexes = this.activeRowIndexes;
7989+
if (this.page > 0) {
7990+
indexes = indexes.map(x => this.perPage * this.page + x );
7991+
}
7992+
7993+
data = DataUtil.merge(cloneArray(this.filteredSortedData), this.columnsToMerge, this.mergeStrategy, indexes, this);
79897994
}
79907995
const columnItems = this.visibleColumns.filter((c) => !c.columnGroup).sort((c1, c2) => c1.visibleIndex - c2.visibleIndex);
79917996
const columnsPathParts = columnItems.map(col => columnFieldPath(col.field));

0 commit comments

Comments
 (0)