F
Filament11mo ago
Jack

Format datetime picker

Hi all, Having some issues trying to format the datetime picker? Any clues?
Forms\Components\DateTimePicker::make('created_at')
->format('l jS M H:i:s')
->disabled()
->hiddenOn('create'),
Forms\Components\DateTimePicker::make('updated_at')
->format('l jS M H:i:s')
->disabled()
->hiddenOn('create'),
Forms\Components\DateTimePicker::make('created_at')
->format('l jS M H:i:s')
->disabled()
->hiddenOn('create'),
Forms\Components\DateTimePicker::make('updated_at')
->format('l jS M H:i:s')
->disabled()
->hiddenOn('create'),
Is still outputting
No description
4 Replies
Dennis Koch
Dennis Koch11mo ago
I think you are looking for ->displayFormat()
Jack
JackOP11mo ago
oh my bad, thank you
Dennis Koch
Dennis Koch11mo ago
It’s mentioned in the docs:
You may customize the format of the field when it is saved in your database
Jack
JackOP11mo ago
No description

Did you find this page helpful?