Closed (fixed)
Project:
Time Tracker
Version:
6.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Reporter:
Created:
26 Jan 2012 at 10:06 UTC
Updated:
23 Mar 2012 at 01:00 UTC
The issue exists in both the time_sheet module as in the atrium_time_tracker feature.
Where:
atrium_time_sheet_user_page()
theme_time_sheet_user_page()
What:
When not using the default settings on /admin/settings/time_tracker/time_sheets a non-existing date (0) is appended to the $days array resulting in a bogus 'Jan 1st 1970' entry at the bottom of the timesheet. This only happens if you have at least one day unchecked on the settings page.
If quick-fixed this, by updating
// create a new array of the ordered days of the week with timestamps
$days = array();
foreach ($days_of_week as $day) {
$days[$day] = $date_lookup[$day];
}
to
// create a new array of the ordered days of the week with timestamps
$days = array();
foreach ($days_of_week as $day) {
if (!$day) {
continue;
}
$days[$day] = $date_lookup[$day];
}
Comments
Comment #1
codi commentedFixed this one for the time_sheet module. Will have to get to the atrium feature later tomorrow.