What happened:
Wrong time displayed when creating new ticket and when adding comment in a ticket. Even after Timezone changed to Asia/Jakarta, the time still is somehow hardcoded to use the default (America/New_York). Also, in Conversations, when a message is first sent, the timestamp is wrong, but it will display the correct time after refreshing the Conversations page.
Installation on native Linux Debian and using Docker, tried version 1.1.11, 1.2.0, 1.2.1, 1.2.2
Tried fresh installation as well as upgraded version
Change the timezone and restart the server. Also tried to use a private browsing session to access Trudesk after the restart of the server still producing the same (erroneous) result
Update:
After doing some more testing (on v1.2.2, then updated to v1.2.3), I found that the time display will show correct offset (UTC+7) after refreshing the browser by pressing the F5 (Refresh) key:
After Create Ticket, open the ticket in the Tickets menu, refresh the browser
After Create Ticket and add comments to the ticket, open the ticket in the ticket menu, refresh the browser
After add comments to a ticket, refresh the browser
Then if I go to another ticket, other menu or logout, the time display will go back to UTC-5 offset.
3.js sets cookie to the default of America/New_York. Found a workaround, change the first entry of "America/New_York" to the local timezone in ~/trudesk/public/js/3.js, this works for me in linux debian:
sed -i 's/"America\/New_York"/"Asia\/Jakarta"/' /usr/src/trudesk/public/js/3.js
Afterwards, just refresh the web browser or open a new tab of Trudesk dashboard.
3.js sets cookie to the default of America/New_York. Found a workaround, change the first entry of "America/New_York" to the local timezone in ~/trudesk/public/js/3.js, this works for me in linux debian (Trudesk v1.2.3 and v1.2.4):
sed -i 's/"America\/New_York"/"Asia\/Jakarta"/' /usr/src/trudesk/public/js/3.js
Another example if your timezone is Asia/Phnom_Penh:
sed -i 's/"America\/New_York"/"Asia\/Phnom_Penh"/' /usr/src/trudesk/public/js/3.js
If Trudesk is running on docker container, do this first:
docker exec -it <container_name> bash
Then execute the sed command above. Afterwards, just refresh the web browser or open a new tab of Trudesk dashboard.
I’m going to move the timezone setting to user prefs. Once that is completed each user can set the timezone they wish. (default to server timezone setting)
I have pushed a new branch (tz-update) that moves timezone settings to the profile → preferences page . This will allow a server fallback timezone but users have the ability to set their own timezone.
It’s still unstable as I haven’t tested all-time displays yet…
In the course of my setup, of course, I also came across it.
The whole system is now running on the correct time zone and with the correct time format (24h), but unfortunately not for answers. As described above, it somehow runs hardcoded on a different time zone…
I could also find no user-specific settings for this. Is there any news or things I need to be aware of?
@Luukullus I just want to confirm you are on the master branch and not using the new ts branch where the timezone setting was moved to the user preferences.
This will be included in v1.2.6 which I believe fixes the issue.
Iam using the installed version 1.2.5 wich got delivered with the install script from Git.
Isn’t that correct?
I’ve noticed other problems, but maybe it’s all fixed with the version…