X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/timetracker.git/blobdiff_plain/26dd5629ee5f2c3de36ff44e65529e4ca491cab1..HEAD:/projects.php diff --git a/projects.php b/projects.php index 236291cd..1b137895 100644 --- a/projects.php +++ b/projects.php @@ -40,15 +40,17 @@ if (MODE_PROJECTS != $user->getTrackingMode() && MODE_PROJECTS_AND_TASKS != $use } // End of access checks. +$showFiles = $user->isPluginEnabled('at'); + if($user->can('manage_projects')) { - $active_projects = ttGroupHelper::getActiveProjects(); - $inactive_projects = ttGroupHelper::getInactiveProjects(); + $active_projects = ttGroupHelper::getActiveProjects($showFiles); + $inactive_projects = ttGroupHelper::getInactiveProjects($showFiles); } else - $active_projects = $user->getAssignedProjects(); + $active_projects = $user->getAssignedProjects($showFiles); $smarty->assign('active_projects', $active_projects); $smarty->assign('inactive_projects', $inactive_projects); -$smarty->assign('show_files', $user->isPluginEnabled('at')); +$smarty->assign('show_files', $showFiles); $smarty->assign('title', $i18n->get('title.projects')); $smarty->assign('content_page_name', 'projects.tpl'); $smarty->display('index.tpl');