$result = $this->attrsForSearch($criteria, array('mail', 'alias'),
KOLAB_SERVER_RESULT_STRICT);
- $addrs = array_merge((array) $result['mail'], (array) $result['alias']);
+ $addrs = array_merge((array) $result['mail'], (array) $result['alias']);
if (empty($result)) {
return array();
* The base class representing Kolab objects stored in the server
* database.
*
- *
* PHP version 5
*
* @category Kolab
* This class provides methods to deal with Kolab objects stored in
* the Kolab db.
*
- *
* Copyright 2008-2009 The Horde Project (http://www.horde.org/)
*
* See the enclosed file COPYING for license information (LGPL). If you
}
$result = array();
foreach ($attrs as $key) {
- $value = $this->get($key);
+ $value = $this->get($key);
$result[$key] = $value;
}
* @return array An array of Kolab objects.
*
* @throws Horde_Kolab_Server_Exception
+ *
+ * @todo Sorting
*/
public function listObjects($type, $params = null)
{
}
if ($sort) {
-/* $this->sort($result, $sort); */
+ /* FIXME */
+ /*$this->sort($result, $sort); */
}
if (isset($params['from'])) {
$to = -1;
}
-/* $entries = $this->_getDns($result, $from, $to); */
-/* if (!$entries && $this->_errno()) { */
-/* return PEAR::raiseError(sprintf(_("Search failed. Error was: %s"), */
-/* $this->_error())); */
-/* } */
-/* if (!$entries) { */
-/* return false; */
-/* } */
-
$entries = array();
foreach ($result as $entry) {
$entries[] = $entry['dn'];
if (!empty($vars['required_group']) && $required_group->isMember($dn)) {
continue;
}
- $result = $this->fetch($dn, $type);
+ $result = $this->fetch($dn, $type);
$objects[] = $result;
}
return $objects;
$criteria = array('AND' => array($users));
}
- $filter = $this->searchQuery($criteria);
+ $filter = $this->searchQuery($criteria);
return $this->dnForFilter($filter, $restrict);
}
$criteria = array('AND' => array($groups));
}
- $filter = $this->searchQuery($criteria);
+ $filter = $this->searchQuery($criteria);
return $this->dnForFilter($filter, $restrict);
}