Day grouping on Activity view ignores user's time zone
On the Activity view the activities are grouped under the wrong day when the user's time zone is not equal to UTC+2.
For example when the user's time is UTC the activities from 22:00 to 23:59 are grouped under the following day.
#2 Updated by Adrien Crivelli about 10 years ago
activities_controller.rb:46, the events are grouped by
event_date. But in
acts_as_event.rb:62, the event_date method does not take the user timezone in account:
def event_date event_datetime.to_date end
Maybe these lines should be changed to always "shift" the date according to user's timezone ?
#4 Updated by Nickolay Mischenko over 9 years ago
Have same issue, it still not fixed.
1. I have server time set to UTC
2. Grouping is fine when user logged has time zone=utc too. Time labels are also fine.
3. When user time zone is my local GMT+11 grouping is still same as 2, but time labels are local
I can make patch for this, but I can't know what is right behavior: show utc times or group by local date? Resolution is - what team members see by sharing link to this pages?
#6 Updated by Achim Gaedke about 9 years ago
experiencing the same with redmine 2.0.2: the main activity list is correct, the one in the user tab doesn't do the day grouping correctly.
Redmine version 2.0.2.stable.9774
Ruby version 1.8.7 (x86_64-linux)
Rails version 3.2.5
Database adapter MySQL
no plugin installed
#7 Updated by Phil Miller over 8 years ago
As of 2.2.2, this seems to be partially working now.
When I have a timezone preference set on my account, the project, user, and overall activity pages present times and group by dates according to that timezone. Without a timezone set in my account preferences, all three activity pages appear to group by UTC but display time of day in server-local time.
When testing any fix for this, beware of #8889, which leads to caching of stale data in the project activity view, but not the others.
I'm glad to provide any additional information on this, and fiddle with personal settings, but I can't install test versions on my system, since I'm trying to get real users on board as quickly as possible, and this is relatively minor to that end.
#8 Updated by Pierre-Francois Laquerre about 8 years ago
This is just a "me too" for 2.3-stable at r11784.
I have a commit with committed_on = 2013-05-02 23:22:52.232768 and commit_date = 2013-05-02 in the changesets table. When not logged in, the activity tab lumps it into 2013-05-03 instead of 2013-05-02, but still has the correct time 23:22. The revision details page shows the commit as being "16 hours ago", which is accurate. The repository tab also shows the right date and time. This glitch goes away if I log in as a user with GMT-5.