How to use the igniteui-angular.IgxNumberSummaryOperand.average function in igniteui-angular

To help you get started, we’ve selected a few igniteui-angular examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github IgniteUI / igniteui-angular-samples / src / app / grid / grid-boston-marathon / grid.component.ts View on Github external
public operate(data?: any[]): IgxSummaryResult[] {
        const result = [];
        result.push(
            {
                key: "min",
                label: "min",
                summaryResult: IgxNumberSummaryOperand.min(data)
            }, {
                key: "max",
                label: "max",
                summaryResult: IgxNumberSummaryOperand.max(data)
            }, {
                key: "average",
                label: "average",
                summaryResult: data.length ? IgxNumberSummaryOperand.average(data).toFixed(2) : null
            });

        return result;
    }
}
github IgniteUI / igniteui-angular-samples / src / app / grid / grid-groupby-summary-sample / grid-groupby-summary-sample.component.ts View on Github external
public operate(data?: any[]): IgxSummaryResult[] {
        const result = [];
        const avg = IgxNumberSummaryOperand.average(data);
        result.push({
            key: "avg",
            label: "Average",
            summaryResult: data.length ? "$" + avg.toFixed(2) : ""
        });
        return result;
    }
}
github IgniteUI / igniteui-angular-samples / src / app / hierarchical-grid / hierarchical-grid-summary / hierarchical-grid-summary.component.ts View on Github external
const result = [];
        result.push(
        {
            key: "min",
            label: "Min",
            summaryResult: IgxNumberSummaryOperand.min(data)
        },
        {
            key: "max",
            label: "Max",
            summaryResult: IgxNumberSummaryOperand.max(data)
        },
        {
          key: "avg",
          label: "Avg",
          summaryResult: IgxNumberSummaryOperand.average(data)
        });
        return result;
    }
}
github IgniteUI / igniteui-angular-samples / src / app / hierarchical-grid / hierarchical-grid-summary-styling / hierarchical-grid-summary-styling.component.ts View on Github external
const result = [];
        result.push(
        {
            key: "min",
            label: "Min",
            summaryResult: IgxNumberSummaryOperand.min(data)
        },
        {
            key: "max",
            label: "Max",
            summaryResult: IgxNumberSummaryOperand.max(data)
        },
        {
          key: "avg",
          label: "Avg",
          summaryResult: IgxNumberSummaryOperand.average(data)
        });
        return result;
    }
}
github IgniteUI / igniteui-cli / packages / igx-templates / igx-ts / hierarchical-grid / hierarchical-grid-summaries / files / src / app / __path__ / custom-summary.ts View on Github external
const result = [];
        result.push(
            {
                key: 'min',
                label: 'Min',
                summaryResult: IgxNumberSummaryOperand.min(data)
            },
            {
                key: 'max',
                label: 'Max',
                summaryResult: IgxNumberSummaryOperand.max(data)
            },
            {
                key: 'avg',
                label: 'Avg',
                summaryResult: IgxNumberSummaryOperand.average(data)
            });
        return result;
    }
}
github IgniteUI / igniteui-angular-samples / src / app / tree-grid / tree-grid-summary2-sample / tree-grid-summary2-sample.component.ts View on Github external
public operate(data?: any[]): IgxSummaryResult[] {
        const result = [];
        const avg = IgxNumberSummaryOperand.average(data);
        result.push({
            key: "avg",
            label: "Average",
            summaryResult: data.length ? "$" + avg.toFixed(2) : ""
        });
        return result;
    }
}
github IgniteUI / igniteui-angular-samples / src / app / hierarchical-grid / hierarchical-grid-editing / hierarchical-grid-editing.component.ts View on Github external
const result = [];
        result.push(
            {
                key: "min",
                label: "Min",
                summaryResult: IgxNumberSummaryOperand.min(data)
            },
            {
                key: "max",
                label: "Max",
                summaryResult: IgxNumberSummaryOperand.max(data)
            },
            {
                key: "avg",
                label: "Avg",
                summaryResult: IgxNumberSummaryOperand.average(data)
            });
        return result;
    }
}