Group your Many-to-many relationships in a clear visual way using Filament Fieldset.
We have a Filament resource to show a list of kindergarten groups.
app/Filament/Resources/GroupResource.php:
use Filament\Tables;use Filament\Tables\Table; public static function table(Table $table): Table{ return $table ->columns([ Tables\Columns\TextColumn::make('name'), ]) // ...}
We added an action to the table to assign meals (breakfast, lunch, or dinner) to kids in a group.
When the action is triggered, a modal slides out with a list of kids and meals for each kid. A form is generated manually for each kid and meal.
Next, we will create: