コード例 #1
0
 /**
  *
  */
 protected function save_links($uid, $links)
 {
     // make sure we have a valid array
     if (empty($links)) {
         $links = array();
     }
     $storage = kolab_storage_config::get_instance();
     $remove = array_diff($storage->get_object_links($uid), $links);
     return $storage->save_object_links($uid, $links, $remove);
 }
コード例 #2
0
ファイル: kolab_driver.php プロジェクト: nciftci/plugins
 /**
  * Build a struct representing the given message reference
  *
  * @see calendar_driver::get_message_reference()
  */
 public function get_message_reference($uri_or_headers, $folder = null)
 {
     if (is_object($uri_or_headers)) {
         $uri_or_headers = kolab_storage_config::get_message_uri($uri_or_headers, $folder);
     }
     if (is_string($uri_or_headers)) {
         return kolab_storage_config::get_message_reference($uri_or_headers, 'event');
     }
     return false;
 }
コード例 #3
0
 /**
  * Find tasks assigned to a specified message
  *
  * @see tasklist_driver::get_message_related_tasks()
  */
 public function get_message_related_tasks($headers, $folder)
 {
     $config = kolab_storage_config::get_instance();
     $result = $config->get_message_relations($headers, $folder, 'task');
     foreach ($result as $idx => $rec) {
         $result[$idx] = $this->_to_rcube_task($rec, kolab_storage::folder_id($rec['_mailbox']));
     }
     return $result;
 }