area17 / twill

Twill is an open source CMS toolkit for Laravel that helps developers rapidly create a custom admin console that is intuitive, powerful and flexible. Chat with us on Discord at https://discord.gg/cnWk7EFv8R.
https://twillcms.com
Apache License 2.0
3.78k stars 574 forks source link

DatePicker not setting the field value #2429

Closed iedex closed 9 months ago

iedex commented 9 months ago

Description

Explained behavior below

Steps to reproduce

Case 1:

Case 2:

Expected result

Actual result

Versions

Twill 3.1.0

ifox commented 9 months ago

Did you update your Twill assets? This should be fixed with the build in 3.1.0

iedex commented 9 months ago

I did this: image

Checked from an incognito window, and same issues.

ifox commented 9 months ago

Ok, sorry to hear that, it's been an annoying bug and I thought my fix was enough. At least I wasn't able to reproduce it anymore on my end. I'll try again.

ifox commented 9 months ago

I still can't reproduce. Which browser are you using?

iedex commented 9 months ago

Chrome on Windows

iedex commented 9 months ago

image

ifox commented 9 months ago

You have duplicate js files that you can delete. You can try deleting public/assets/twill and running twill:update again, but I highly doubt that it will help since your manifest should be correct and use the latest ones you got, which do match the one I use in my testing.

I wanted to confirm something else: in which context are you using the faulty date picker field? Form? Block? Publisher sidebar?

iedex commented 9 months ago

Form, Twill / ...Controller / getForm...


DatePicker::make()->name('first_reg')->label('1st reg.')->time24Hr()->withoutTime()->allowClear(),
iedex commented 9 months ago

now I realized the absurd "->time24Hr()->withoutTime()". anyway, I don't think this is the problem.

ifox commented 9 months ago

Closing as a dupe of #2237