© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
FilamentF
Filament•2y ago•
3 replies
pepperoni dogfart

Select field using search populate another field.

I have a select field that populates the options via an external API request:

Forms\Components\Select::make('ticket_number')
    ->searchable()
    ->getSearchResultsUsing(fn (string $search): array => \App\Models\Ticket::apiTickets($search))
    ->selectablePlaceholder(false)
    ->searchingMessage('Searching Tickets...')
    ->native(false)
    ->live(),

Forms\Components\TextInput::make('ticket_title')->readOnly(),
Forms\Components\Select::make('ticket_number')
    ->searchable()
    ->getSearchResultsUsing(fn (string $search): array => \App\Models\Ticket::apiTickets($search))
    ->selectablePlaceholder(false)
    ->searchingMessage('Searching Tickets...')
    ->native(false)
    ->live(),

Forms\Components\TextInput::make('ticket_title')->readOnly(),


How can I pass the selected result over to the TextInput field? I couldn't figure this out using
afterStateUpdated
afterStateUpdated
with the
getSearchResultsUsing
getSearchResultsUsing
method on the original field.
Filament banner
FilamentJoin
A powerful open source UI framework for Laravel • Build and ship admin panels & apps fast with Livewire
20,307Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

Search modified select field
FilamentFFilament / ❓┊help
9mo ago
Select field - Multiple & Search
FilamentFFilament / ❓┊help
3y ago
Select Field search not reloading options after clearing search
FilamentFFilament / ❓┊help
3y ago
Searchable select field shows incorrect search results
FilamentFFilament / ❓┊help
2y ago