-$smarty->assign('active_clients', ttTeamHelper::getActiveClients($user->team_id, true));
-$smarty->assign('inactive_clients', ttTeamHelper::getInactiveClients($user->team_id, true));
+if($user->can('manage_clients')) {
+ $active_clients = ttGroupHelper::getActiveClients(true);
+ $inactive_clients = ttGroupHelper::getInactiveClients(true);
+} else
+ $active_clients = $user->getAssignedClients();
+
+$smarty->assign('active_clients', $active_clients);
+$smarty->assign('inactive_clients', $inactive_clients);