This commit is contained in:
Arthur Schiwon 2014-04-17 18:25:05 +02:00
parent 3e411c82a5
commit 5444a1114d
1 changed files with 0 additions and 38 deletions

View File

@ -44,43 +44,5 @@ if(!$isAdmin) {
$accessiblegroups = array_intersect($groups, $subadminGroups);
}
// $sortGroupsIndex = 0;
// $sortGroupsKeys = array();
// $sortAdminGroupsIndex = 0;
// $sortAdminGroupsKeys = array();
//
// foreach($accessiblegroups as $group) {
// $gid = $group->getGID();
// $group = $groupManager->get($gid);
// if(!$group) {
// continue;
// }
// $usersInGroup = $group->count();
// if (!OC_User::isAdminUser($gid)) {
// $groups[] = array(
// 'id' => str_replace(' ','', $gid ),
// 'name' => $gid,
// 'usercount' => $usersInGroup,
// );
// $sortGroupsKeys[$sortGroupsIndex] = $usersInGroup;
// $sortGroupsIndex++;
// } else {
// $adminGroup[] = array(
// 'id' => str_replace(' ','', $gid ),
// 'name' => $gid,
// 'usercount' => $usersInGroup
// );
// $sortAdminGroupsKeys[$sortAdminGroupsIndex] = $usersInGroup;
// $sortAdminGroupsIndex++;
// }
// }
//
// if(!empty($groups)) {
// array_multisort($sortGroupsKeys, SORT_DESC, $groups);
// }
// if(!empty($adminGroup)) {
// array_multisort($sortAdminGroupsKeys, SORT_DESC, $adminGroup);
// }
OC_JSON::success(
array('data' => array('adminGroups' => $adminGroups, 'groups' => $groups)));