Opening modals on page visit
I have several modals in my resource (FilamentComments, a custom 'relation manager' in a modal etc.). Is there a way to have a particular modal opened on visiting the edit page? Or having a table row action which opens the edit page with an opened modal?
3 Replies
Yes, add a mount to the ListRecords file (the index). Below an example:
Make sure to pass a request parameter to the page, like so:/
You can set a
$defaultAction
https://filamentphp.com/docs/3.x/panels/pages#opening-an-action-modal-when-a-page-loadsAh, thank you! I didn't know I could trigger actions via URL parameters. So I just used this snippet in my list view to open the comments modal: