File tree 3 files changed +14
-24
lines changed
projects/igniteui-angular/src/lib/grids
3 files changed +14
-24
lines changed Original file line number Diff line number Diff line change @@ -5956,7 +5956,7 @@ export class IgxGridBaseDirective extends DisplayDensityBase implements
5956
5956
5957
5957
while ( searchIndex !== - 1 ) {
5958
5958
this . lastSearchInfo . matchInfoCache . push ( {
5959
- row : data ,
5959
+ row : dataRowRec ,
5960
5960
column : c . field ,
5961
5961
index : occurenceIndex ++ ,
5962
5962
} ) ;
Original file line number Diff line number Diff line change @@ -365,28 +365,6 @@ export class IgxTreeGridComponent extends IgxGridBaseDirective implements GridTy
365
365
super . ngAfterContentInit ( ) ;
366
366
}
367
367
368
- /**
369
- * @hidden @internal
370
- */
371
- public setFilteredSortedData ( data , pinned : boolean ) {
372
- super . setFilteredSortedData ( data , pinned ) ;
373
- const flatFilteredSortedData = [ ] ;
374
- this . flattenTreeGridRecords ( this . filteredSortedData , flatFilteredSortedData ) ;
375
- this . filteredSortedData = flatFilteredSortedData ;
376
- }
377
-
378
- /**
379
- * @hidden @internal
380
- */
381
- private flattenTreeGridRecords ( records : any [ ] , flatData : any [ ] ) {
382
- if ( records && records . length ) {
383
- for ( const record of records ) {
384
- ( this . isGhostRecord ( record ) ) ? flatData . push ( record . data . recordData ) : flatData . push ( record . data ) ;
385
- this . flattenTreeGridRecords ( record . children , flatData ) ;
386
- }
387
- }
388
- }
389
-
390
368
private loadChildrenOnRowExpansion ( args : IRowToggleEventArgs ) {
391
369
if ( this . loadChildrenOnDemand ) {
392
370
const parentID = args . rowID ;
Original file line number Diff line number Diff line change @@ -212,10 +212,22 @@ export class IgxTreeGridSortingPipe implements PipeTransform {
212
212
} else {
213
213
result = DataUtil . treeGridSort ( hierarchicalData , expressions , sorting ) ;
214
214
}
215
- grid . setFilteredSortedData ( result , pinned ) ;
215
+
216
+ const filteredSortedData = [ ] ;
217
+ this . flattenTreeGridRecords ( result , filteredSortedData ) ;
218
+ grid . setFilteredSortedData ( filteredSortedData , pinned ) ;
216
219
217
220
return result ;
218
221
}
222
+
223
+ private flattenTreeGridRecords ( records : ITreeGridRecord [ ] , flatData : any [ ] ) {
224
+ if ( records && records . length ) {
225
+ for ( const record of records ) {
226
+ this . gridAPI . grid . isGhostRecord ( record ) ? flatData . push ( record . data . recordData ) : flatData . push ( record . data ) ;
227
+ this . flattenTreeGridRecords ( record . children , flatData ) ;
228
+ }
229
+ }
230
+ }
219
231
}
220
232
221
233
/** @hidden */
You can’t perform that action at this time.
0 commit comments