We are trying to combine filters and summary calculations, which doesn’t seem to work.
Imagine following table data:
NAME…| VALUE
…
PersonA | 10
PersonA | 20
PersonB | 15
PersonA | 30
Now we already successfully added an empty fixed row to the bottom which holds the columnSummary calculated data.
Using: destinationRow: 0, destinationColumn: 1, reversedRowCoords: true, type: 'sum', forceNumeric: true
This works fine and gives us the following result:
NAME…| VALUE
…
PersonA | 10
PersonA | 20
PersonB | 15
PersonA | 30
…| 75
However, as soon as the user applies a filter on the first column e.g. choosing only “PersonA”, the summary results disappear. But what the user would expect and what we would like to have is a summary caluculation based on the applied filter:
FILTER: PersonA
PersonA | 10
PersonA | 20
PersonA | 30
…| 60
If your data is not very complicated you can use setDataAtCell() method to get updated value. To get indexes of trimmed rows (those that were hidden via filtering process) you should use the following line:
instance_name.getPlugin('trimRows').trimmedRows;
this will return an array of trimmed rows. If filters are not applied the following line returns an empty array.
I think that users should have a choice to set if they want to update the results so I’m addinf the improvement suggestion label for this topic. Thank you very much for suggesting @onelogic
What I really would like, is a fixed summary row at the bottom of the table, which is not part of the data it self.
So that the shown summary calculations are always caluculated by the current data visible to the user.
I am sure there would be a lot of use cases for such a feature.
I agree @onelogic
actually we have the same issue as you described on our internal ticketing system. Summary calculations row should not be counted to the data like rest of the cells.
You’re welcome @onelogic
I would rather want to share more optimistic news however I am currently gathering all issues that will be used to create a new Roadmap for 2017. If the team would decide that we need to fix anything related to this task in Q1 I’ll come back with news.