injecting view data to action
I have an action::make inside a ViewRecord under getHeaderActions()
I have a ->disabled() value but want to pickup the model data to set this.
I have tried disabled(function ($data)) and also $arguments but these are both empty.
8 Replies
$record
, $this->getRecord()
?Thanks!
Is it possible to refresh the view page where the button was pressed when completed?
Isn't it happening?
So I am saving the updated record to the DB and sending this with refreshFormData as an array. I am also sending the notification which is being sent.
So inside the action I have $this->refreshFormData($array)
Which is a correct array
what is the issue?
Does refreshFormData update the view form of the model? It doesn't seem to but a page reload does
are you doing something like this?
refreshFormData
isn't necessary if you are using an infolistThanks for the help that helped a lot!