mojotech / torch

A rapid admin generator for Elixir & Phoenix
Other
1.1k stars 79 forks source link

Manual Date Entry is Changing #281

Closed samcdavid closed 2 years ago

samcdavid commented 2 years ago

What we are doing

We have some date filters on our index pages. In the event when a user manually changes the date in a date field, the date changes to the day before the one that was typed on blur. Below is a screen video of what we are seeing.

https://user-images.githubusercontent.com/773102/149384540-4b1c5e0f-d8a6-4bcc-961a-cabc2c45e15c.mov

Versions

Torch: seen in 3.6.4 and 3.7.1

cpjolicoeur commented 2 years ago

This sounds/looks pretty similar to Issue #241 that you reported a few months back. My guess is that it is the same type of logic issue within Pikaday.

Care to take a look into it based on how we resolved #241 @samcdavid ? Otherwise, I'll try to get to this sometime in the next week or two if possible.

samcdavid commented 2 years ago

@cpjolicoeur I think that I have some time to be able to take a stab at it.

cpjolicoeur commented 2 years ago

@samcdavid Version 3.8.0 was released today. I believe this should fix your date issue. If you can confirm, that would be great.

If you are on Phoenix 1.6, however, you'll need to use a Torch v4 release which will be released later today that includes this same fix.

samcdavid commented 2 years ago

@cpjolicoeur you're the best. I'll get this on my plate to take a look at soon 😄

samcdavid commented 2 years ago

@cpjolicoeur was torch 4 released yet? I'm not seeing it up on hex.

samcdavid commented 2 years ago

FWIW, it does not look like this is fixed in the cpj/v4_updates branch. We're on Phoenix 1.6 now so we have to go the v4 route ☹️

cpjolicoeur commented 2 years ago

@samcdavid V4 has not been released yet. I hope to have an initial RC released to hex soon, but I'm in the middle of updating the layout and styles as part of this move. Version 3.8.0 was released and should fix your issue for the existing Torch v3 line of code though.