cakan
Tabs with different content
This is the working code. I have custom component Company:
class CompanyProperties extends Entry
{
protected string $view = 'filament.admin.pages.company-projects';
}
with a blade:
<x-filament::section>
@livewire('list-projects')
</x-filament::section>
And a livewire component:
class ListProperties extends Component implements HasForms, HasTable
{
use InteractsWithTable;
use InteractsWithForms;
public function render()
{
return view('livewire.list-projects');
}
public function table(Table $table): Table
{
return ProjectResource::table($table)
->query(ProjectResource::getEloquentQuery())
->actions([
EditAction::make()->form(getProjectSchema()),
]);
}
with a following blade:
<div>
{{ $this->table }}
</div>
Then, in my infolist that display the tabs I added this tab:
Tabs\Tab::make("Projects")->schema([
Pages\CompanyProjects::make('projects')
]),
13 replies
Tabs with different content
I've managed to make it work. I re-did everything again from the scratch and actions are working this time. I don't see any difference in current and previous solution. Code is the same, it's just magically works 🙂
13 replies