Fixed issue #1176 - Generation of weekly report fails with internal server error.

This commit is contained in:
Thorsten Eckel 2017-06-09 10:06:04 +02:00
parent 1eaf46f466
commit 44e41dcf10

View file

@ -143,7 +143,7 @@ class ReportsController < ApplicationController
stop = "#{date}T23:59:59Z"
range = 'hour'
elsif params[:timeRange] == 'week'
start = Date.commercial(params[:year], params[:week]).iso8601
start = Date.commercial(params[:year].to_i, params[:week].to_i).iso8601
stop = Date.parse(start).end_of_week.iso8601
range = 'week'
elsif params[:timeRange] == 'month'