© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
FilamentF
Filament•3y ago•
12 replies
astronomic

Error when I use searchable() in wizard step

Hello everyone. I have an error when I want to use a Select with searchable() in a wizard step. Error: Cannot read properties of null (reading 'location'), my code:
 Wizard\Step::make('form')
                    ->icon('heroicon-o-pencil')
                    ->label('Formulario')
                    ->schema([
                        Forms\Components\TextInput::make('name')
                            ->label('Nombre')
                            ->required(),
                        Forms\Components\TextInput::make('last_name')
                            ->label('Apellidos')
                            ->required(),
                        Forms\Components\TextInput::make('dni')
                            ->label('DNI')
                            ->required(),
                        Forms\Components\Select::make('location')
                            ->label('Población')
                            ->required()                            
                            ->options(CpMunicipality::get()->take(20)->pluck('name', 'id'))
                            ->searchable()
                            ->columnSpan(3),
                        Forms\Components\TextInput::make('contact_name')
                            ->label('Nombre persona contacto')
                            ->required(),
                        Forms\Components\TextInput::make('contact_last_name')
                            ->label('Apellido persona contacto')
                            ->required(),
                        Forms\Components\TextInput::make('email')
                            ->label('Email')
                            ->required(),
                        Forms\Components\TextInput::make('phone')
                            ->label('Teléfono')
                            ->required(),
                    ]),
 Wizard\Step::make('form')
                    ->icon('heroicon-o-pencil')
                    ->label('Formulario')
                    ->schema([
                        Forms\Components\TextInput::make('name')
                            ->label('Nombre')
                            ->required(),
                        Forms\Components\TextInput::make('last_name')
                            ->label('Apellidos')
                            ->required(),
                        Forms\Components\TextInput::make('dni')
                            ->label('DNI')
                            ->required(),
                        Forms\Components\Select::make('location')
                            ->label('Población')
                            ->required()                            
                            ->options(CpMunicipality::get()->take(20)->pluck('name', 'id'))
                            ->searchable()
                            ->columnSpan(3),
                        Forms\Components\TextInput::make('contact_name')
                            ->label('Nombre persona contacto')
                            ->required(),
                        Forms\Components\TextInput::make('contact_last_name')
                            ->label('Apellido persona contacto')
                            ->required(),
                        Forms\Components\TextInput::make('email')
                            ->label('Email')
                            ->required(),
                        Forms\Components\TextInput::make('phone')
                            ->label('Teléfono')
                            ->required(),
                    ]),

If I remove searchable(), the error goes away. Can anybody help me? I am doing something wrong? Thank you
Filament banner
FilamentJoin
A powerful open source UI framework for Laravel • Build and ship admin panels & apps fast with Livewire
20,307Members
Resources
Was this page helpful?

Similar Threads

Recent Announcements

Similar Threads

Wizard Step type error
FilamentFFilament / ❓┊help
3y ago
How to use relationship in Wizard Step?
FilamentFFilament / ❓┊help
3y ago
Additional actions in wizard step
FilamentFFilament / ❓┊help
11mo ago
Next Step action in Wizard
FilamentFFilament / ❓┊help
2y ago