Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
constructor() {
this.data = INVOICE_DATA;
this.expr = [
{ dir: SortingDirection.Asc, fieldName: "ShipCountry", ignoreCase: false,
strategy: DefaultSortingStrategy.instance() }
];
this.summaryPositions = [
{
label: GridSummaryPosition.top,
selected: this.summaryPosition === GridSummaryPosition.top,
togglable: true
},
{
label: GridSummaryPosition.bottom,
selected: this.summaryPosition === GridSummaryPosition.bottom,
togglable: true
}
];
this.summaryCalcModes = [
{
label: "Root Level Only",
selected: this.summaryCalculationMode === GridSummaryCalculationMode.rootLevelOnly,
togglable: true,
value: GridSummaryCalculationMode.rootLevelOnly
},
{
label: "Child Levels Only",
selected: this.summaryCalculationMode === GridSummaryCalculationMode.childLevelsOnly,
togglable: true,
@Component({
selector: "app-tree-grid-summary2-sample",
styleUrls: ["./tree-grid-summary2-sample.component.scss"],
templateUrl: "./tree-grid-summary2-sample.component.html"
})
export class TreeGridSummary2SampleComponent implements OnInit {
@ViewChild("treegrid1", { read: IgxTreeGridComponent, static: true })
public grid1: IgxTreeGridComponent;
public data;
public expr: ISortingExpression[];
public avgSummary = AvgSummary;
public summaryPositions;
public summaryPosition = GridSummaryPosition.bottom;
public summaryCalcModes;
public summaryCalculationMode = GridSummaryCalculationMode.rootAndChildLevels;
constructor() {
this.data = FOODS_DATA();
this.expr = [
{
dir: SortingDirection.Asc,
fieldName: "ShipCountry",
ignoreCase: false,
strategy: DefaultSortingStrategy.instance()
}
];
this.summaryPositions = [
{
}
@Component({
selector: "app-grid-groupby-summary-sample",
styleUrls: ["./grid-groupby-summary-sample.component.scss"],
templateUrl: "./grid-groupby-summary-sample.component.html"
})
export class GridGroupBySummarySampleComponent {
@ViewChild("grid1", { read: IgxGridComponent })
public grid1: IgxGridComponent;
public data;
public expr: ISortingExpression[];
public avgSummary = AvgSummary;
public sumSummary = SumSummary;
public summaryPositions;
public summaryPosition = GridSummaryPosition.bottom;
public summaryCalcModes;
public summaryCalculationMode = GridSummaryCalculationMode.rootAndChildLevels;
constructor() {
this.data = LOCAL_DATA;
this.expr = [
{ dir: SortingDirection.Asc, fieldName: "ShipCountry", ignoreCase: false,
strategy: DefaultSortingStrategy.instance() }
];
this.summaryPositions = [
{
label: GridSummaryPosition.top,
selected: this.summaryPosition === GridSummaryPosition.top,
togglable: true
},
}
}
@Component({
selector: "app-grid-groupby-summary-sample",
styleUrls: ["./grid-groupby-summary-styling-sample.component.scss"],
templateUrl: "./grid-groupby-summary-styling-sample.component.html"
})
export class GridGroupBySummaryStylingSampleComponent {
@ViewChild("grid1", { read: IgxGridComponent, static: true })
public grid1: IgxGridComponent;
public data;
public expr: ISortingExpression[];
public customSummary = CustomSummary;
public summaryPositions;
public summaryPosition = GridSummaryPosition.bottom;
public summaryCalcModes;
public summaryCalculationMode = GridSummaryCalculationMode.rootAndChildLevels;
constructor() {
this.data = INVOICE_DATA;
this.expr = [
{ dir: SortingDirection.Asc, fieldName: "ShipCountry", ignoreCase: false,
strategy: DefaultSortingStrategy.instance() }
];
this.summaryPositions = [
{
label: GridSummaryPosition.top,
selected: this.summaryPosition === GridSummaryPosition.top,
togglable: true
},
dir: SortingDirection.Asc,
fieldName: "ShipCountry",
ignoreCase: false,
strategy: DefaultSortingStrategy.instance()
}
];
this.summaryPositions = [
{
label: GridSummaryPosition.top,
selected: this.summaryPosition === GridSummaryPosition.top,
togglable: true
},
{
label: GridSummaryPosition.bottom,
selected: this.summaryPosition === GridSummaryPosition.bottom,
togglable: true
}
];
this.summaryCalcModes = [
{
label: "Root Level Only",
selected: this.summaryCalculationMode === GridSummaryCalculationMode.rootLevelOnly,
togglable: true,
value: GridSummaryCalculationMode.rootLevelOnly
},
{
label: "Child Levels Only",
selected: this.summaryCalculationMode === GridSummaryCalculationMode.childLevelsOnly,
togglable: true,
value: GridSummaryCalculationMode.childLevelsOnly
constructor() {
this.data = INVOICE_DATA;
this.expr = [
{ dir: SortingDirection.Asc, fieldName: "ShipCountry", ignoreCase: false,
strategy: DefaultSortingStrategy.instance() }
];
this.summaryPositions = [
{
label: GridSummaryPosition.top,
selected: this.summaryPosition === GridSummaryPosition.top,
togglable: true
},
{
label: GridSummaryPosition.bottom,
selected: this.summaryPosition === GridSummaryPosition.bottom,
togglable: true
}
];
this.summaryCalcModes = [
{
label: "Root Level Only",
selected: this.summaryCalculationMode === GridSummaryCalculationMode.rootLevelOnly,
togglable: true,
value: GridSummaryCalculationMode.rootLevelOnly
},
{
label: "Child Levels Only",
selected: this.summaryCalculationMode === GridSummaryCalculationMode.childLevelsOnly,
togglable: true,
value: GridSummaryCalculationMode.childLevelsOnly
constructor() {
this.data = LOCAL_DATA;
this.expr = [
{ dir: SortingDirection.Asc, fieldName: "ShipCountry", ignoreCase: false,
strategy: DefaultSortingStrategy.instance() }
];
this.summaryPositions = [
{
label: GridSummaryPosition.top,
selected: this.summaryPosition === GridSummaryPosition.top,
togglable: true
},
{
label: GridSummaryPosition.bottom,
selected: this.summaryPosition === GridSummaryPosition.bottom,
togglable: true
}
];
this.summaryCalcModes = [
{
label: "Root Level Only",
selected: this.summaryCalculationMode === GridSummaryCalculationMode.rootLevelOnly,
togglable: true,
value: GridSummaryCalculationMode.rootLevelOnly
},
{
label: "Child Levels Only",
selected: this.summaryCalculationMode === GridSummaryCalculationMode.childLevelsOnly,
togglable: true,
{
dir: SortingDirection.Asc,
fieldName: "ShipCountry",
ignoreCase: false,
strategy: DefaultSortingStrategy.instance()
}
];
this.summaryPositions = [
{
label: GridSummaryPosition.top,
selected: this.summaryPosition === GridSummaryPosition.top,
togglable: true
},
{
label: GridSummaryPosition.bottom,
selected: this.summaryPosition === GridSummaryPosition.bottom,
togglable: true
}
];
this.summaryCalcModes = [
{
label: "Root Level Only",
selected: this.summaryCalculationMode === GridSummaryCalculationMode.rootLevelOnly,
togglable: true,
value: GridSummaryCalculationMode.rootLevelOnly
},
{
label: "Child Levels Only",
selected: this.summaryCalculationMode === GridSummaryCalculationMode.childLevelsOnly,
togglable: true,
constructor() {
this.data = LOCAL_DATA;
this.expr = [
{ dir: SortingDirection.Asc, fieldName: "ShipCountry", ignoreCase: false,
strategy: DefaultSortingStrategy.instance() }
];
this.summaryPositions = [
{
label: GridSummaryPosition.top,
selected: this.summaryPosition === GridSummaryPosition.top,
togglable: true
},
{
label: GridSummaryPosition.bottom,
selected: this.summaryPosition === GridSummaryPosition.bottom,
togglable: true
}
];
this.summaryCalcModes = [
{
label: "Root Level Only",
selected: this.summaryCalculationMode === GridSummaryCalculationMode.rootLevelOnly,
togglable: true,
value: GridSummaryCalculationMode.rootLevelOnly
},
{
label: "Child Levels Only",
selected: this.summaryCalculationMode === GridSummaryCalculationMode.childLevelsOnly,
togglable: true,
value: GridSummaryCalculationMode.childLevelsOnly