[TIME-208] wrong date in report template when showUsers=true and time zone isn't 0

Issue #208 invalid
Andriy Zhdanov created an issue

I made some changes to the templates, but when I installed it on the production I found strange issue. When I opened report with showUsers=true all worklog values where "moved" to the next day, though sum by issue per day was correct. Like values (per day) were <empty> 1 1 2, but sums were 1 1 2 <empty>. The problem was date comparison in timesheet-entry.vm:

#if ($weekDay.getWeekDayDate().getDate() == $worklog.getStartDate().getDate()) #if ($weekDay.getWeekDayDate().getMonth() == $worklog.getStartDate().getMonth()) #if ($weekDay.getWeekDayDate().getYear() == $worklog.getStartDate().getYear()) #set ($timespent = $issueWorkLog.get($worklog).intValue()) #end #end #end

it didn't use timezones, so I replaced it with

#if ($weekDay.equalsToDate($worklog.getStartDate())) #set ($timespent = $issueWorkLog.get($worklog).intValue()) #end

it works correctly now, so I believe this should be fixed for next version.
regards.

By kubelox/Victor on Tue, 20 Dec 2011 04:03:48 -0800

Comments (3)

  1. Andriy Zhdanov reporter

    Thank you for the fix, but I can't find this in 2.2.5, which file do you mean?

    By azhdanov on Tue, 20 Dec 2011 10:07:28 -0800

  2. Andriy Zhdanov reporter

    I really can't see it in source code repository or plugin.jar, something went wrong on your side, sorry.

    By azhdanov on Wed, 21 Dec 2011 09:36:42 -0800

  3. Log in to comment