Lines Matching full:group

64 …['select-user', 'select-user-groups', 'select-groups', 'insert-user', 'insert-group', 'join-group']
69 ['select-user', 'select-user-groups', 'select-groups', 'leave-group', 'delete-user']
94 …['select-user', 'select-user-groups', 'select-groups', 'leave-group', 'join-group', 'insert-group']
187 * The new user HAS TO be added to the default group by this
226 foreach ($grps as $group) {
227 if (!isset($allgroups[$group])) {
228 $ok = $this->addGroup($group);
235 foreach ($grps as $group) {
236 $ok = $this->joinGroup($userdata, $allgroups[$group]);
302 foreach ($oldgroups as $group) {
303 if (!in_array($group, $changes['grps']) && isset($allgroups[$group])) {
304 $ok = $this->leaveGroup($olddata, $allgroups[$group]);
311 foreach ($changes['grps'] as $group) {
312 if (!isset($allgroups[$group])) {
313 $ok = $this->addGroup($group);
318 // reload group info
322 foreach ($changes['grps'] as $group) {
323 if (!in_array($group, $oldgroups)) {
324 $ok = $this->joinGroup($olddata, $allgroups[$group]);
374 if (isset($filter['grps'])) $filter['group'] = $filter['grps'];
375 foreach (['user', 'name', 'mail', 'group'] as $key) {
413 if (isset($filter['grps'])) $filter['group'] = $filter['grps'];
414 foreach (['user', 'name', 'mail', 'group'] as $key) {
430 * Create a new group with the given name
432 * @param string $group
435 public function addGroup($group) argument
437 $sql = $this->getConf('insert-group');
439 $result = $this->query($sql, [':group' => $group]);
509 * Delete a user after removing all their group memberships
522 // remove group memberships (ignore errors)
523 foreach ($userdata['grps'] as $group) {
524 if (isset($allgroups[$group])) {
525 $this->leaveGroup($userdata, $allgroups[$group]);
544 * @return array|bool list of group names, false on error
556 if (!isset($row['group'])) {
557 … $this->debugMsg("No 'group' field returned in select-user-groups statement", -1, __LINE__);
560 $groups[] = $row['group'];
587 if (!isset($row['group'])) {
588 … $this->debugMsg("No 'group' field returned from select-groups statement", -1, __LINE__);
592 // relayout result with group name as key
593 $group = $row['group'];
594 $groups[$group] = $row;
605 * Remove all entries from the group cache
613 * Adds the user to the group
616 * @param array $groupdata all the group data
622 $sql = $this->getConf('join-group');
629 * Removes the user from the group
632 * @param array $groupdata all the group data
638 $sql = $this->getConf('leave-group');