© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
FilamentF
Filament•2y ago•
7 replies
Matthew

datepicker initial date

Should be easy, but I can't find a way to set the landing date of the datepicker, trying:

            DatePicker::make('uc_dob')
                ->required()
                ->label('Date of Birth')
                ->displayFormat(Date::FORMAT_DATE_HUMAN)
                ->default(now()->subYears(45))
                ->visible(fn ($record) : bool => $record->uc_dob == false)
                ->minDate(now()->subYears(90))
                ->maxDate(now()->subYears(18)),
            DatePicker::make('uc_dob')
                ->required()
                ->label('Date of Birth')
                ->displayFormat(Date::FORMAT_DATE_HUMAN)
                ->default(now()->subYears(45))
                ->visible(fn ($record) : bool => $record->uc_dob == false)
                ->minDate(now()->subYears(90))
                ->maxDate(now()->subYears(18)),

I've checked uc_dob is null

Thanks
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

Datepicker date format
FilamentFFilament / ❓┊help
3y ago
Default date of DatePicker
FilamentFFilament / ❓┊help
14mo ago
Multiple date selection in datepicker
FilamentFFilament / ❓┊help
3y ago