Hey guys,
I have a problem displaying the date and time in my application, our license is cloud and the application is reactive.
As we are in the cloud, we do not have the possibility of configuring the server time, having to manage this in the application.
The application runs in Brazil, so the time zone must be GMT-03.
In server actions, I created logic to not use CurrDateTime() and correctly save the current time in the database.
This recording step is working successfully and recording okay.
However, on the front end, when displaying this time saved in the bank, the application is automatically reducing -3 hours, as if the displayed time was still ahead, and now I have the problem of displaying an hour late.
DataBaseScreen:
What should I do about the display issue?
Hi Eduardo ,
As you created the server action for saving the Timedate correctly vice versa you can create action to display correctly.
Please refer below link.
https://success.outsystems.com/support/enterprise_customers/maintenance_and_operations/outsystems_cloud_and_time_zones/
And can also use forge component:
https://www.outsystems.com/forge/component-overview/500/time-zone
As suggested by OS Doc.
Regards,
Amreen
Hello,
I think it's not a very good idea to mess with timezone conversion before saving date/time values in the database. Let OutSystems handle the conversions automatically when saving/fetching the values from the database.
Is there a specific reason why you want to store the values in a different timezone?
Hi Eduardo,
I agree with Aurelio, better not mess with the time on the server side, better using default one.
What you need to do, is doing time conversion when those data is shown on the front end / screen.
If you need the data as excel for example, then do the conversion when the data is being write on the excel.
Hi, the date time is shown based on the computer's timezone (the browser reads it). Change the timezone of your computer to keep it same.
regards