// +----------------------------------------------------------------------+
require_once('initialize.php');
// +----------------------------------------------------------------------+
require_once('initialize.php');
// Access checks.
if (!(ttAccessAllowed('track_own_time') || ttAccessAllowed('track_time'))) {
header('Location: access_denied.php');
// Access checks.
if (!(ttAccessAllowed('track_own_time') || ttAccessAllowed('track_time'))) {
header('Location: access_denied.php');
$week_total = ttTimeHelper::getTimeForWeek($selected_date);
$timeRecords = $showFiles? ttTimeHelper::getRecordsWithFiles($user_id, $cl_date) : ttTimeHelper::getRecords($user_id, $cl_date);
$week_total = ttTimeHelper::getTimeForWeek($selected_date);
$timeRecords = $showFiles? ttTimeHelper::getRecordsWithFiles($user_id, $cl_date) : ttTimeHelper::getRecords($user_id, $cl_date);
$smarty->assign('selected_date', $selected_date);
$smarty->assign('week_total', $week_total);
$smarty->assign('day_total', ttTimeHelper::getTimeForDay($cl_date));
$smarty->assign('selected_date', $selected_date);
$smarty->assign('week_total', $week_total);
$smarty->assign('day_total', ttTimeHelper::getTimeForDay($cl_date));
$smarty->assign('show_start', $showStart);
$smarty->assign('show_finish', $showFinish);
$smarty->assign('show_duration', $showDuration);
$smarty->assign('show_start', $showStart);
$smarty->assign('show_finish', $showFinish);
$smarty->assign('show_duration', $showDuration);
$smarty->assign('show_note_column', $showNoteColumn);
$smarty->assign('show_note_row', $showNoteRow);
$smarty->assign('show_files', $showFiles);
$smarty->assign('show_note_column', $showNoteColumn);
$smarty->assign('show_note_row', $showNoteRow);
$smarty->assign('show_files', $showFiles);