We are using the PrimeReact calendar control and have noticed it converts the time from the field that is bound to it, to GMT. In other words, a field from the database that was saved by a user in India could have the value: "12/01/2020 18:30:00.000". Then, when that value is viewed in the Control, it is displayed as "12/02/2020". I suspect this is due to a default TimeZone conversion or something to that effect.
We would like the Calendar to basically always "ignore" the Time. All we care about is the Date. Since these are DateTime fields, there obviously has to be a "time", so it would probably be best to just have it always set to "00:00:00". What is the best/easiest way to accomplish this?
To be honest, I am not very strong in React, so I'm just looking for a quick/easy suggestion that I can implement. We are currently using version "3.3.3" of PrimeReact.
Any help is much appreciated. (Most developers are off this week, so I'm trying to work through this issue myself and not have to bother one of the "React Experts".)
Thank you.
Calendar - Always "ignore" time, set it to Midnight "00:00:00" and dont "convert".
-
- Posts: 2
- Joined: 31 Dec 2020, 03:14
I'm still stuck on this, if ANYBODY has any ideas?
-
- Posts: 5281
- Joined: 29 Jun 2013, 12:38
Could you please attach your Calendar component? What does the value of the pattern property? Also, could you please try the latest PrimeReact version?
Best Regards,
Best Regards,
Github Profile: https://github.com/mertsincan
-
- Information
-
Who is online
Users browsing this forum: No registered users and 16 guests