示例#1
0
文件: Menu.php 项目: spthaolt/movim
 function ajaxRefresh()
 {
     Notification::append(null, $this->__('menu.refresh'));
     $sd = new \modl\SubscriptionDAO();
     $subscriptions = $sd->getSubscribed();
     foreach ($subscriptions as $s) {
         $r = new GetItems();
         $r->setTo($s->server)->setNode($s->node)->request();
     }
 }
示例#2
0
文件: Groups.php 项目: vijo/movim
 function prepareSubscriptions()
 {
     $sd = new \modl\SubscriptionDAO();
     $view = $this->tpl();
     $view->assign('subscriptions', $sd->getSubscribed());
     $html = $view->draw('_groups_subscriptions', true);
     return $html;
 }
示例#3
0
文件: Rooms.php 项目: Trim/movim
 public function setBookmark($item = false)
 {
     $arr = array();
     if ($item) {
         array_push($arr, $item);
     }
     $sd = new \modl\SubscriptionDAO();
     $cd = new \modl\ConferenceDAO();
     foreach ($sd->getSubscribed() as $s) {
         array_push($arr, array('type' => 'subscription', 'server' => $s->server, 'title' => $s->title, 'subid' => $s->subid, 'tags' => unserialize($s->tags), 'node' => $s->node));
     }
     foreach ($cd->getAll() as $c) {
         array_push($arr, array('type' => 'conference', 'name' => $c->name, 'autojoin' => $c->autojoin, 'nick' => $c->nick, 'jid' => $c->conference));
     }
     $b = new Set();
     $b->setArr($arr)->setTo($this->user->getLogin())->request();
 }