Hi FlexMonster team!
First of all, congratuations for the excelent product!
I am using flexmonster in a Demo to a customer, and using Angular4. I need to get a variable (an index, for instance), and customize the [report] property according to it. I tried using “FlexmonsterPivot.prototype.report” at my ngOnInit() function, but it fails 🙁
Thank you for writing. Please have a look at our Angular4 integration tutorial – https://www.flexmonster.com/doc/integration-with-angular/, there you can find the reference to the GitHub repository with the sample project. In app.component.ts file you can see the example of using Flexmonster’s setReport() API call. Please find more information about available API calls in our docs – https://www.flexmonster.com/api/setreport/.
Let us know if the information above was helpful for you.
Your solution is elegant and fast! But as I am using routes (<component>/:<queryid>, for instance: view/1, view/2 etc) to identify the queryId, the onReportComplete Event is only executed when the Component is first entered. Any Ideias on how to solve this?
BTW, I will use you solution at another situation i have, thanks very much!!!
Our team is really glad that previously suggested solution is useful for your project!
As about customizing the
[report] property, please try the following approach:
every time when
queryId is changed, please use
setReport() API call.
setReport() will set new report for the component, i.e. change the
[report] property. Check how setReport() should be called and which properties report may contain.
Please share your feedback with us!