FilamentF
Filament3y ago
Remi

Preloaded select component loads selected values

Trying to figure out if this is a bug or if i'm doing something wrong.

I have a select component with a relationship

Select::make('managers')
    ->relationship('managers', 'full_name')
    ->multiple()
    ->preload(),


When i use the form->fill it selects the current selected items, which works, but it also adds these to the drop down.
These items are unresponsive in the dropdown. When i remove an item, and reselect it in the dropdown, it is removed from the dropdown.

My expected behavior would be: on load, the currently selected items, are removed from the dropdown and only readded when the selection is removed.
Was this page helpful?