How do you properly nest a Table in a FilamentPHP Form Tab?
Issue Description
I'm using a Filament resource with a form that includes multiple tabs. One of the tabs, "VAT Settings", contains a Filament table rendered through a Livewire component.
Resource Snippet
vat-table-wrapper.blade.php
VatTable Component
vat-table.blade.php
The Problem
When this table is rendered in the ViewField, the form displays correctly and all tabs are editable. However, saving the resource no longer works. Removing the table restores normal save behaviour.
Question
Is it possible to embed a Filament table inside a resource form tab without breaking the parent save functionality?
3 Replies
Hey @gemini.dev , if this is still current, I would try to use the
Livewire::make(YourTableClass)
method: https://filamentphp.com/docs/3.x/forms/advanced#inserting-livewire-components-into-a-formYou cannot nest tables in forms because they contain forms, too. You can however create a view file and use the tab component.
Thanks both. Ended up using the relation manager instead. It makes the code less confusing lol