Hi Flexmonster team, I would like to ask if there is maybe an issue with data retrieval for integration with charting libraries.
We have followed the guide: https://www.flexmonster.com/doc/integration-with-any-charting-library/
but we were unbale to get it working properly. The problem is, that when the slice is defined, the returned data always contains original data without any filtering. E.g.: If I filter out a country, the chart always contains all countries.
It looks like the jsfiddle has also this problem: https://jsfiddle.net/flexmonster/ybaefLh4/
On the other hand, when we were working with the webdatarocks library before the flexmonster, this issue was not present: https://codepen.io/webdatarocks/pen/bJyrmG
Here the filtering works as expected.
Thank you very much
Thank you for posting to our forum.
We would like to kindly explain the behavior of the example you sent.
Please have a look at the 45 line: the
slice object is specified in the
options parameter of
pivot.getData(). This slice will be shown on the chart even when some changes have been made to the grid. If
options.slice is not defined, the slice passed to the charts will be the one currently displayed in the pivot table.
Therefore, we suggest removing the
slice object from the
Speaking about WebDataRocks, the behavior of this library in the discussed case was a bug that we fixed in the Flexmonster component. With the
options.slice parameter, Flexmonster provides an opportunity to display different slices in pivot and charts.
Please let us know if the suggested approach would work for you.
Looking forward to your response.
Thank you very much for your answer. Yes, it looks like we could work with that.
We were thinking that that may be the issue, that declaring the slice object would mean, that we would always get the data as declared in the slice 🙂
BR and thanks again