I am trying to get the sum of a column of integers in my grid. How come the aggregationValue is undefined
when in the gridOptions
I have it set as
{ field: 'premium', name: 'Premium', width: '*', aggregationType: uiGridConstants.aggregationTypes.sum, aggregationHideLabel: true, cellTemplate: '<div class="ui-grid-cell-contents">${{COL_FIELD}}</div>' },
Here is a snapshot of the object. As you can see aggregationType
is 2 (sum).
Here is a snap[shot of uiGridConstants
that shows that it knows the type
is sum
Here is an example of the object that makes up the grid
[
{
"id": "",
"name": "Hadassah Potts",
"type": "Wealth",
"status": "Completed",
"premium": 38823,
"commission": 2039,
"created_by": "Rose Strong",
"last_updated": 75
},
{
"id": "",
"name": "Michael D. Hodge",
"type": "Wealth",
"status": "In Review",
"premium": 37173,
"commission": 4644,
"created_by": "Thaddeus S. Wyatt",
"last_updated": 49
}
]
Even though im not using showColumnFooter: true,
i needed to have it in the code...