FilamentF
Filament3y ago
Veur

Return a BelongsToMany in getTableQuery()

I have a Livewire component with a Client $client model property. In that component I'd like to render a table with the users of that client, which I can access with $client->users() (BelongsToMany)

Is there a way to use $client->users() inside getTableQuery(), instead of writing the Eloquent query?
Was this page helpful?