Help with a Form and ViewField::make
I cant figure this out, so in a form I'm using a ViewField to make a visual element of the data in the form, but if I have a select box called 'owners' how can I pass the value of 'owners' into the ViewField?
3 Replies
via
$set
. The ViewField has an state:
Fab, is there way I can send the entire form state, so all the current filled out fields?
And then if I wanted to send values from the ViewField into the main form is that possible?
I think you can get all fields using
$this->data
Yes, you get the state from the viewField when you submit the form