This only happens when the report has a dataSource type of "api".
If for example I add the following event handler:
pivot.on('reportchange', ($event) => {
console.log(pivot.getReport());
});
After certain actions, for example:
The Pivot.getReport function returns a null report in the event handler.
After other actions like:
The function returns a report as expected.
This isn't the same when the report is a CSV for example, in which case everything works as expected.
This is tested on the latest (2.8.11) version.
Hello,
Thank you for reporting this problem to us.
We have managed to reproduce the issue on our end as well.
Our team will provide the fix to this issue in the minor release version with the ETA 24th of August.
In the meantime, as a workaround, we kindly suggest using a combination of two events: reportchange
and reportcomplete
:
Looking deeper, we have noticed that for the custom data source API, the reportchange
event is fired before the changed report object is ready.
The reportcomplete
event can be used to get the changed report object.
Here is a JSFiddle example for illustration: http://jsfiddle.net/flexmonster/qdytz2f5/
Please let us know if this would work for you.
Looking forward to your response.
Kind regards,
Vera
Ok, thank you for that insight, using reportcomplete
in combination works reasonably well as a workaround.
Hi!
We are happy to let you know that the issue with getReport()
returning null
after the reportchange
event was fixed.
This is included in the 2.8.14 version of Flexmonster: https://www.flexmonster.com/release-notes/
You are welcome to update the component. Here is our updating to the latest version tutorial for guidance: https://www.flexmonster.com/doc/updating-to-the-latest-version/
Please let us know if everything works fine for you.
Best regards,
Mykhailo
Hi!
Hope you're doing well.
We were wondering if you've received our previous heads-up regarding the latest update. Have you had a chance to test this on your side?
We would be happy to hear your feedback.
Regards,
Mykhailo
Hello there Mykhailo,
Thanks for your message. We have received your update and have now tested the new version of the component.
I can confirm that it is indeed working as expected now 🙂
I wanted to report a little css/rendering bug that I noticed in the last version, when using the fields menu on the right, see here: https://jsfiddle.net/ezk84/r08dkf6b/
Notice that the buttons to close the bar, as well as to add calculated measures now overflow the container and aren't completely visible.
Regards,
Ezequiel
Hello!
Thank you for reporting the issue and providing detailed info about it.
We have managed to reproduce the reported behavior on our side - the fix for the issue is going to be provided with a minor release ETA Sep 7th.
Please let us know if any other questions arise.
Best regards,
Milena
Hello,
We are glad to announce that the issue with buttons’ icon alignment (CSS) for fieldListPosition: 'right' was fixed.
This is available in the 2.8.15 version of Flexmonster: https://www.flexmonster.com/release-notes/.
You are welcome to update the component.
Here is our updating to the latest version guide for assistance: https://www.flexmonster.com/doc/updating-to-the-latest-version/.
Please contact us in case any questions arise.
Best regards,
Milena
Great, that works as expected. Thank you!
Hello,
I am running into the same problem that getReport() returns a null in the reportchange or update event handler. We are currently on version 2.8.7 and are at the end of our release cycle so upgrading to a new version is difficult. The reportcomplete is not fired if I change any of the column filters or row filters. It is only fired when I drag or remove a measure or a dimension from the fields list. Our data source is an OLAP cube. Can you please suggest a work around?
Thanks.
Nilesh
Hello, Nilesh,
Thank you for reaching out to us.
We want to confirm that the reportcomplete
event is not triggered after sorting and filtering. Therefore, we recommend using the reportchange
event instead.
However, until version 2.8.14, the getReport
method may return null after the reportchange
event as mentioned in your question.
We are currently not ready to provide you with a workaround except the one mentioned earlier in this thread (using reportcomplete
event, which is not an option for you).
Therefore, we highly recommend considering updating to the latest version of the component.
You are welcome to see our updating to the latest version guide. It consists of steps leading to the smooth update of the component.
Please let us know if it works for your case.
Our team is looking forward to hearing from you.
Best regards,
Illia
Hello, Nilesh,
We are wondering whether our suggestion was helpful for you.
Our team is looking forward to hearing your feedback.
Best regards,
Illia
Hello, Nilesh,
We are reaching out to ask if our recent suggestion helped.
Please contact us if further questions arise.
Kind regards,
Illia