Refresh widget method `getOptions()` after filtering
I posted this on Github last week, but haven't had any response: https://github.com/filamentphp/filament/discussions/16111
I have filters on my Chart Widget like this:
Upon select of one of these options, i want to change the min and max values in the y axis using the
If i do this and change the filter options, the min and max values don't change (even though I am using
How can I fix this?
I have filters on my Chart Widget like this:
Upon select of one of these options, i want to change the min and max values in the y axis using the
getOptions method.If i do this and change the filter options, the min and max values don't change (even though I am using
array_rand(), because getOptions only renders once. Upon changing filter I need to somehow refresh the method/component/widget so that the random values (in this example) actually change. If you try this with a chart widget you will see they stay the same. How can I fix this?
GitHub
I have filters on my Chart Widget like this: protected function getFilters(): ?array { return [ 'today' => 'Today', 'week' => 'Last week', 'month' =>...