datepicker initial date
Should be easy, but I can't find a way to set the landing date of the datepicker, trying:
I've checked uc_dob is null
Thanks
4 Replies
If this is editing a record,
default
might now work AFAIK. You need another way to set the datepicker value if it's null.Hi,
In this example, it is an edit.
But I'm surprised that this is not already a well required function.
doesn't appear to work.
Well, it doesn't make much sense having a default value during an edit. For example if someone opened that form and hit 'Save', the data would change even if they didn't change anything. Anyway, it's better if you do that manually using something like https://filamentphp.com/docs/3.x/forms/advanced#field-hydration
I'll check those docs. But it is not about having a default value as such, it is where the datepicker starts.
The datepicker opens up on, (when there is no pre-exisiting value), at the latest date it can. In my example
I want it to open up on (unless there is pre-existing data, in which case it opens up on that, which works fine)