Automatic Filament ViewAction on Livewire component
I have a Filament table on a Livewire component.
I want to be able to jump to the following URL:
/users?id=2
and have the component instantiate, but also to have the ViewAction for that specific user to fire.
This should be possible, but I just don't know how to go about it.4 Replies
In th view page you can rewrite the mount() function and get $usserId = request()?->id; and get the record from the id or other wise you can just send to its argument using /users/2 instead.
Thank you for your response Zen.
Yup, got that bit; but I can't get the view to automatically trigger to show it.
That's what the action looks like (minus the
->visible(false)
Do you use Filament UserResource or just Livewire component?
It's just a Livewire component for this one.
Tried a slightly different approach, and that's not working either.