getOptions() on chart widget - called but not reflected on the the chart #9918
Unanswered
nlvrendell
asked this question in
Help
Replies: 1 comment 1 reply
-
I am also trying to implement a dynamic configuration in my charts, in my case it is a custom dashboard with charts and widgets + multiple filters displayed in a modal. Indeed getOptions() is called whenever I apply changes in filters, but those changes don't affect a chart at all (configuration is not reloaded). @nlvrendell in your case, try to use the built-in method: public function getHeading(): string|Htmlable|null
{
return 'Total Sent: '.$this->sum;
} at least the title of a chart can be dynamic. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
So I used the
getOptions()
of chart widget to set a dynamic option on the chart. I have a function which is triggered by (dispatch()) to update the data of chart. The data and the content of getOptions() is update/change as I have used logger to trace its value But, the the title on the chart is not updated.Code at getOptions. $this->sum is dynamically updated.
Beta Was this translation helpful? Give feedback.
All reactions