Added groups list sorting
This commit is contained in:
parent
631f19ca5e
commit
f5edc20089
1 changed files with 6 additions and 2 deletions
|
@ -239,9 +239,13 @@ class rcube_kolab_contacts extends rcube_addressbook
|
||||||
$groups = array();
|
$groups = array();
|
||||||
foreach ((array)$this->distlists as $group) {
|
foreach ((array)$this->distlists as $group) {
|
||||||
if (!$search || strstr(strtolower($group['last-name']), strtolower($search)))
|
if (!$search || strstr(strtolower($group['last-name']), strtolower($search)))
|
||||||
$groups[] = array('ID' => $group['ID'], 'name' => $group['last-name']);
|
$groups[$group['last-name']] = array('ID' => $group['ID'], 'name' => $group['last-name']);
|
||||||
}
|
}
|
||||||
return $groups;
|
|
||||||
|
// sort groups
|
||||||
|
ksort($groups, SORT_LOCALE_STRING);
|
||||||
|
|
||||||
|
return array_values($groups);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue