laravel / nova-issues

554 stars 34 forks source link

DateTime field changes in every edit by error #5614

Closed paugm closed 1 year ago

paugm commented 1 year ago

Description:

Every time I edit a resource, I can see a DateTime field set. If I do not interact with the datetime field, when I click Update or Update and continue editing, the datetime changes to the current system time.

https://github.com/laravel/nova-issues/assets/13300485/302a4d00-cd41-4fd8-977d-336565ad9412

Detailed steps to reproduce the issue on a fresh Nova installation:

1) Create a new resource that has different fields, including a datetime 2) Edit the resource and only change some of the fields that are not the datetime 3) When you save, the datetime field will change

crynobone commented 1 year ago

Please provide the following:

  1. Application's timezone
  2. Value of DateTime stored in the database
  3. User's timezone
  4. Machine's timezone (Browser)
paugm commented 1 year ago

Please provide the following:

  1. Application's timezone
  2. Value of DateTime stored in the database
  3. User's timezone
  4. Machine's timezone (Browser)

Here we go!

App's timezone: UTC Example of value stored: 2022-05-10 21:00:00 User's timezone: CET Machine's timezone (Browser): CET

Thanks

crynobone commented 1 year ago

Hi there, I'm not able to replicate your issue. If you look at the form it's showing UTC and if the User's timezone it not set to UTC it would show otherwise:

image

Unable to reproduce the issue, please provide full reproducing repository based on fresh installation as suggested in the bug report template (or you can refer to https://github.com/nova-issues for example)