File tree Expand file tree Collapse file tree 3 files changed +11
-13
lines changed
projects/igniteui-angular/src/lib/grids/summaries Expand file tree Collapse file tree 3 files changed +11
-13
lines changed Original file line number Diff line number Diff line change @@ -130,9 +130,7 @@ export class IgxGridSummaryService {
130
130
}
131
131
132
132
public resetSummaryHeight ( ) {
133
- if ( this . summaryHeight !== this . grid . summaryRowHeight ) {
134
- this . summaryHeight = 0 ;
135
- }
133
+ this . summaryHeight = 0 ;
136
134
this . grid . summaryPipeTrigger ++ ;
137
135
if ( this . grid . rootSummariesEnabled ) {
138
136
this . retriggerRootPipe ++ ;
Original file line number Diff line number Diff line change 35
35
${{val}}
36
36
</ ng-template >
37
37
< ng-template igxCustomSummaryCell let-summaryResults >
38
- < div style ="font-size: 0.75rem ">
39
- < span > Custom summary cell:</ span > < br >
40
- < span > Number of Summaries: {{ summaryResults.length }}</ span > < br >
41
- < span > First Summary - {{ summaryResults[0].label }}: {{ summaryResults[0].summaryResult }}</ span > < br >
42
- < span > Second Summary - {{ summaryResults[1].label }}: {{ summaryResults[1].summaryResult }}</ span > < br >
43
- < span > Third Summary - {{ summaryResults[2].label }}: {{ summaryResults[2].summaryResult }}</ span > < br >
44
- < span > Fourth Summary - {{ summaryResults[3].label }}: {{ summaryResults[3].summaryResult }}</ span > < br >
38
+ < div style ="font-size: 0.75rem ">
39
+ < span > Custom summary cell:</ span > < br >
40
+ < span > Number of Summaries: {{ summaryResults.length }}</ span > < br >
41
+ < span > First Summary - {{ summaryResults[0].label }}: {{ summaryResults[0].summaryResult }}</ span > < br >
42
+ < span > Second Summary - {{ summaryResults[1].label }}: {{ summaryResults[1].summaryResult }}</ span > < br >
43
+ < span > Third Summary - {{ summaryResults[2].label }}: {{ summaryResults[2].summaryResult }}</ span > < br >
44
+ < span > Fourth Summary - {{ summaryResults[3].label }}: {{ summaryResults[3].summaryResult }}</ span > < br >
45
45
</ div >
46
46
</ ng-template >
47
47
</ igx-column >
89
89
< igx-switch [(ngModel)] ="rowSelection "> Row Selection</ igx-switch >
90
90
91
91
< button (click) ="enableSummary() "> Enable Summary for column ReorderLevel</ button >
92
- < button (click) ="disableSummary () "> Disable Summary</ button >
92
+ < button (click) ="toggleSummary () "> Toggle Custom Summary</ button >
93
93
< button (click) ="updateData() "> Update Data</ button >
94
94
< button (click) ="addRow() "> Add Row</ button >
95
95
< button (click) ="deleteRow() "> Delete Row</ button >
Original file line number Diff line number Diff line change @@ -803,8 +803,8 @@ export class GridSummaryComponent implements OnInit {
803
803
}
804
804
}
805
805
806
- public disableSummary ( ) {
807
- this . grid1 . getColumnByName ( 'UnitsInStock' ) . hasSummary = false ;
806
+ public toggleSummary ( ) {
807
+ this . grid1 . getColumnByName ( 'UnitsInStock' ) . hasSummary = ! this . grid1 . getColumnByName ( 'UnitsInStock' ) . hasSummary ;
808
808
// this.grid1.recalculateSummaries();
809
809
}
810
810
You can’t perform that action at this time.
0 commit comments