Changeset View
Changeset View
Standalone View
Standalone View
plugins/kolab_addressbook/kolab_addressbook.php
Show First 20 Lines • Show All 234 Lines • ▼ Show 20 Lines | class kolab_addressbook extends rcube_plugin | ||||
protected function folder_tree_html($node, $data, &$jsdata) | protected function folder_tree_html($node, $data, &$jsdata) | ||||
{ | { | ||||
$out = ''; | $out = ''; | ||||
foreach ($node->children as $folder) { | foreach ($node->children as $folder) { | ||||
$id = $folder->id; | $id = $folder->id; | ||||
$source = $data[$id]; | $source = $data[$id]; | ||||
$is_collapsed = strpos($this->rc->config->get('collapsed_abooks',''), '&'.rawurlencode($id).'&') !== false; | $is_collapsed = strpos($this->rc->config->get('collapsed_abooks',''), '&'.rawurlencode($id).'&') !== false; | ||||
if ($folder->virtual) { | if (!empty($folder->virtual)) { | ||||
$source = $this->driver->abook_prop($folder->id, $folder); | $source = $this->driver->abook_prop($folder->id, $folder); | ||||
} | } | ||||
else if (empty($source)) { | else if (empty($source)) { | ||||
$this->sources[$id] = new kolab_contacts($folder->name); | $this->sources[$id] = new kolab_contacts($folder->name); | ||||
$source = $this->driver->abook_prop($id, $this->sources[$id]); | $source = $this->driver->abook_prop($id, $this->sources[$id]); | ||||
} | } | ||||
$content = $this->addressbook_list_item($id, $source, $jsdata); | $content = $this->addressbook_list_item($id, $source, $jsdata); | ||||
▲ Show 20 Lines • Show All 891 Lines • Show Last 20 Lines |