File tree Expand file tree Collapse file tree 1 file changed +7
-0
lines changed
projects/igniteui-angular/src/lib/grids/pivot-grid Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Original file line number Diff line number Diff line change @@ -203,6 +203,13 @@ export class IgxPivotGridComponent extends IgxGridBaseDirective implements OnIni
203203 const fieldColumn = parentCols . filter ( x => x . header === col . header && ! x . columnGroup ) [ 0 ] ;
204204 const groupColumn = parentCols . filter ( x => x . header === col . header && x . columnGroup ) [ 0 ] ;
205205 groupColumn . hidden = newState ;
206+ if ( ! groupColumn . hidden ) {
207+ // column group when shown displays all children, we want to show only groups
208+ const fieldChildren = groupColumn . children . filter ( x => ! x . columnGroup ) ;
209+ fieldChildren . forEach ( fieldChild => {
210+ fieldChild . hidden = true ;
211+ } ) ;
212+ }
206213 fieldColumn . hidden = ! newState ;
207214 if ( newState ) {
208215 fieldColumn . headerTemplate = this . headerTemplate ;
You can’t perform that action at this time.
0 commit comments