In my current project, I am utilizing Angular and Typescript along with the DevExtreme library. I have encountered a challenge while trying to remove specific rows from the PivotGrid in DevExtreme.
According to the documentation and forum discussions I found, the recommended approach is to set the hideEmptySummaryCells
property to true on the grid and adjust the calculateSummaryValue
function for the desired field to return null when removing a row. However, the signature of calculateSummaryValue
requires a number to be returned, making it impossible to pass null. Here is a snippet of my code:
var entity: Field = {
area: "data",
dataField: "countOfItems",
caption: 'Count of Items',
isMeasure: false,
expanded: false,
filterType: 'include',
filterValues: [],
visible: true,
calculateSummaryValue: function(e: dxPivotGridSummaryCell) {
//Unable to return null
return 0;
}
};
I appreciate any guidance or solutions you can provide. Thank you in advance, and I hope you have a wonderful day :)