Project

General

Profile

Defect #5329 » time_report.rb.patch

Filou Centrinov, 2013-02-21 23:45

View differences:

time_report.rb
when 'month'
row['month'] = "#{row['tyear']}-#{row['tmonth']}"
when 'week'
row['week'] = "#{row['tyear']}-#{row['tweek']}"
row['week'] = "#{row['spent_on'].cwyear}-#{row['tweek']}"
when 'day'
row['day'] = "#{row['spent_on']}"
end
......
@periods << "#{date_from.year}-#{date_from.month}"
date_from = (date_from + 1.month).at_beginning_of_month
when 'week'
@periods << "#{date_from.year}-#{date_from.to_date.cweek}"
@periods << "#{date_from.to_date.cwyear}-#{date_from.to_date.cweek}"
date_from = (date_from + 7.day).at_beginning_of_week
when 'day'
@periods << "#{date_from.to_date}"
(3-3/4)