how to refresh the report on Angular 6
I used your example from GitHub (https://github.com/WebDataRocks/pivot-angular/tree/master/src/app).
<wbr-pivot #pivot1 [toolbar]=”flag”
I need to set the [report] after a asynchronous request http.get().
I used a getReport() method for return the data to [report], but when the component wbr-pivot is initiated the http request still don’t ended and the getReport() method return a data empty;
So, I need to set the [report] and refresh the component. how to do that?
Thank you for the question.
The correct sequence for your case is:
- Initialize the empty pivot and wait for
- Create a HTTP get request to the report and wait for the JSON response
- Use `this.child.webDataRocks.setReport()` API method to set the report
Please let us know if it helps.