X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=clients.php;h=177bd61ee0f7afd0c5d9f47703e57daa733458e5;hb=45c855269d952873285f7a835e82fc2b3eff3971;hp=61c66583b1b58c276e0083df5f72a2a3147422c4;hpb=098a79f0819ebb89b7d48df4a6b154af4560f68e;p=timetracker.git diff --git a/clients.php b/clients.php index 61c66583..177bd61e 100644 --- a/clients.php +++ b/clients.php @@ -30,15 +30,18 @@ require_once('initialize.php'); import('form.Form'); import('ttTeamHelper'); -// Access check. -if (!ttAccessCheck(right_manage_team)) { +// Access checks. +if (!ttAccessAllowed('manage_clients')) { header('Location: access_denied.php'); exit(); } +if (!$user->isPluginEnabled('cl')) { + header('Location: feature_disabled.php'); + exit(); +} -$smarty->assign('active_clients', ttTeamHelper::getActiveClients($user->team_id, true)); -$smarty->assign('inactive_clients', ttTeamHelper::getInactiveClients($user->team_id, true)); -$smarty->assign('title', $i18n->getKey('title.clients')); +$smarty->assign('active_clients', ttTeamHelper::getActiveClients($user->group_id, true)); +$smarty->assign('inactive_clients', ttTeamHelper::getInactiveClients($user->group_id, true)); +$smarty->assign('title', $i18n->get('title.clients')); $smarty->assign('content_page_name', 'clients.tpl'); $smarty->display('index.tpl'); -?> \ No newline at end of file