]> wagnertech.de Git - timetracker.git/blobdiff - users.php
Excluded clients from getActiveUsers call.
[timetracker.git] / users.php
index 4afd5521f2cd802d8d6a64f5434c52ed591792b8..77b7e5525a556911f1ad8fe2ca23978811647869 100644 (file)
--- a/users.php
+++ b/users.php
@@ -48,7 +48,7 @@ if ($request->isPost()) {
   $group_id = $request->getParameter('group');
   $user->setOnBehalfGroup($group_id);
 } else {
-  $group_id = $user->getActiveGroup();
+  $group_id = $user->getGroup();
 }
 
 $form = new Form('usersForm');
@@ -79,12 +79,13 @@ if($user->can('manage_users')) {
   $inactive_users = $user->getUsers($options);
 }
 
-// Check if the group is set to show indicators for uncompleted time entries.
-if ($user->uncompleted_indicators) {
+$uncompleted_indicators = $user->getConfigOption('uncompleted_indicators');
+if ($uncompleted_indicators) {
   // Check each active user if they have an uncompleted time entry.
   foreach ($active_users as $key => $user) {
     $active_users[$key]['has_uncompleted_entry'] = (bool) ttTimeHelper::getUncompleted($user['id']);
   }
+  $smarty->assign('uncompleted_indicators', true);
 }
 
 $smarty->assign('forms', array($form->getName()=>$form->toArray()));