Exemplo n.º 1
0
 /**
  * @see	\wcf\page\IPage::readData()
  */
 public function readData()
 {
     parent::readData();
     // read categories
     $categoryNodeTree = new CategoryNodeTree('de.codequake.cms.file', 0, true);
     $this->categoryList = $categoryNodeTree->getIterator();
 }
 /**
  * @see	\wcf\page\IPage::readData()
  */
 public function readData()
 {
     parent::readData();
     // add breadcrumbs
     WCF::getBreadcrumbs()->add(new Breadcrumb(WCF::getLanguage()->get('cms.header.menu.news'), LinkHandler::getInstance()->getLink('NewsOverview', array('application' => 'cms'))));
     WCF::getBreadcrumbs()->add($this->entry->getDecoratedObject()->getBreadcrumb());
 }
 /**
  * @see	\wcf\page\IPage::readData()
  */
 public function readData()
 {
     parent::readData();
     // add breadcrumbs
     $leafCategories = $this->entry->getLeafCategories();
     $category = reset($leafCategories);
     LINKLISTCore::getInstance()->setLocation($category->getParentCategories(), $category, $this->entry->getDecoratedObject());
 }
Exemplo n.º 4
0
 public function readData()
 {
     parent::readData();
     VisitCountHandler::getInstance()->count();
     WCF::getBreadcrumbs()->add(new Breadcrumb(WCF::getLanguage()->get('cms.page.news'), LinkHandler::getInstance()->getLink('NewsCategoryList', array('application' => 'cms'))));
     // get categories
     $categoryTree = new NewsCategoryNodeTree('de.codequake.cms.category.news');
     $this->categoryList = $categoryTree->getIterator();
     $this->categoryList->setMaxDepth(0);
 }
 public function readData()
 {
     parent::readData();
     $categoryTree = new NewsCategoryNodeTree('de.codequake.cms.category.news');
     $this->categoryList = $categoryTree->getIterator();
     $this->categoryList->setMaxDepth(0);
     if (PageMenu::getInstance()->getLandingPage()->menuItem == 'cms.page.news') {
         WCF::getBreadcrumbs()->remove(0);
         MetaTagHandler::getInstance()->addTag('og:url', 'og:url', LinkHandler::getInstance()->getLink('NewsList', array('application' => 'cms')), true);
         MetaTagHandler::getInstance()->addTag('og:type', 'og:type', 'website', true);
         MetaTagHandler::getInstance()->addTag('og:title', 'og:title', WCF::getLanguage()->get(PAGE_TITLE), true);
         MetaTagHandler::getInstance()->addTag('og:description', 'og:description', WCF::getLanguage()->get(PAGE_DESCRIPTION), true);
         MetaTagHandler::getInstance()->addTag('generator', 'generator', 'Fireball CMS');
     }
 }
Exemplo n.º 6
0
 /**
  * @see wcf\page\IPage::readData()
  */
 public function readData()
 {
     parent::readData();
     // get marked users
     $this->markedUsers = WCF::getSession()->getVar('markedUsers');
     if ($this->markedUsers == null || !is_array($this->markedUsers)) {
         $this->markedUsers = array();
     }
     // get columns heads
     $this->readColumnsHeads();
     // get users
     $this->readUsers();
     // build page url
     $this->url = LinkHandler::getInstance()->getLink('UserList', array(), 'searchID=' . $this->searchID . '&action=' . rawurlencode($this->action) . '&pageNo=' . $this->pageNo . '&sortField=' . $this->sortField . '&sortOrder=' . $this->sortOrder);
 }
Exemplo n.º 7
0
 /**
  * @see	\wcf\page\IPage::readData()
  */
 public function readData()
 {
     parent::readData();
     // add email column for authorized users
     if (WCF::getSession()->getPermission('admin.user.canEditMailAddress')) {
         array_unshift($this->columns, 'email');
     }
     // get marked users
     $this->markedUsers = WCF::getSession()->getVar('markedUsers');
     if ($this->markedUsers == null || !is_array($this->markedUsers)) {
         $this->markedUsers = array();
     }
     // get columns heads
     $this->readColumnsHeads();
     // get users
     $this->readUsers();
     // build page url
     $this->url = LinkHandler::getInstance()->getLink('UserList', array(), 'searchID=' . $this->searchID . '&action=' . rawurlencode($this->action) . '&pageNo=' . $this->pageNo . '&sortField=' . $this->sortField . '&sortOrder=' . $this->sortOrder);
 }
 /**
  * @see	\wcf\page\IPage::readData()
  */
 public function readData()
 {
     parent::readData();
 }
 /**
  * @see	\wcf\page\IPage::readData()
  */
 public function readData()
 {
     parent::readData();
     // categories
     $categoryTree = new NewsCategoryNodeTree($this->objectTypeName);
     $this->categoryList = $categoryTree->getIterator();
     $this->categoryList->setMaxDepth(0);
     // stats
     $this->stats = NewsStatsCacheBuilder::getInstance()->getData();
     $this->stats['categories'] = count(CategoryHandler::getInstance()->getCategories($this->objectTypeName));
     $this->stats['comments'] = count(CommentHandler::getInstance()->getObjectType('de.voolia.news.comment'));
     // users online list
     if (MODULE_USERS_ONLINE && NEWS_INDEX_ENABLE_USERS_ONLINE_LIST) {
         $this->usersOnlineList = new UsersOnlineList();
         $this->usersOnlineList->readStats();
         $this->usersOnlineList->getConditionBuilder()->add('session.userID IS NOT NULL');
         $this->usersOnlineList->readObjects();
     }
     // add breadcrumbs
     NEWSCore::getInstance()->setBreadcrumbs($this->category !== null ? $this->category->getParentCategories() : array());
 }
 /**
  * @see wcf\page\IPage::readData()
  */
 public function readData()
 {
     parent::readData();
     // read packages
     $this->readPackages();
 }
 /**
  * @see	\wcf\page\IPage::readData()
  */
 public function readData()
 {
     parent::readData();
     // categories
     $categoryTree = new NewsCategoryNodeTree($this->objectTypeName);
     $this->categoryList = $categoryTree->getIterator();
     $this->categoryList->setMaxDepth(0);
     // stats
     $this->stats = NewsStatsCacheBuilder::getInstance()->getData();
     $this->stats['categories'] = count(CategoryHandler::getInstance()->getCategories($this->objectTypeName));
     $this->stats['comments'] = count(CommentHandler::getInstance()->getObjectType('de.incendium.cms.news.comment'));
     // users online list
     if (MODULE_USERS_ONLINE && CMS_NEWS_ENABLE_USERS_ONLINE_LIST) {
         $this->usersOnlineList = new UsersOnlineList();
         $this->usersOnlineList->readStats();
         $this->usersOnlineList->getConditionBuilder()->add('session.userID IS NOT NULL');
         $this->usersOnlineList->readObjects();
     }
     // add breadcrumbs
     WCF::getBreadcrumbs()->add(new Breadcrumb(WCF::getLanguage()->get('cms.header.menu.news'), LinkHandler::getInstance()->getLink('NewsOverview', array('application' => 'cms'))));
     if ($this->category !== null) {
         foreach ($this->category->getParentCategories() as $parentCategory) {
             WCF::getBreadcrumbs()->add($parentCategory->getBreadcrumb());
         }
     }
 }
 /**
  * @see	\wcf\page\IPage::readData()
  */
 public function readData()
 {
     parent::readData();
     if ($this->filter != '') {
         // add breadcrumbs
         WCF::getBreadcrumbs()->add(new Breadcrumb(WCF::getLanguage()->get('wcf.conversation.conversations'), LinkHandler::getInstance()->getLink('ConversationList')));
     }
     // read stats
     if (!$this->labelID) {
         switch ($this->filter) {
             case '':
                 $this->conversationCount = $this->items;
                 break;
             case 'draft':
                 $this->draftCount = $this->items;
                 break;
             case 'hidden':
                 $this->hiddenCount = $this->items;
                 break;
             case 'outbox':
                 $this->outboxCount = $this->items;
                 break;
         }
     }
     if ($this->filter != '' || $this->labelID) {
         $conversationList = new UserConversationList(WCF::getUser()->userID, '');
         $this->conversationCount = $conversationList->countObjects();
     }
     if ($this->filter != 'draft' || $this->labelID) {
         $conversationList = new UserConversationList(WCF::getUser()->userID, 'draft');
         $this->draftCount = $conversationList->countObjects();
     }
     if ($this->filter != 'hidden' || $this->labelID) {
         $conversationList = new UserConversationList(WCF::getUser()->userID, 'hidden');
         $this->hiddenCount = $conversationList->countObjects();
     }
     if ($this->filter != 'outbox' || $this->labelID) {
         $conversationList = new UserConversationList(WCF::getUser()->userID, 'outbox');
         $this->outboxCount = $conversationList->countObjects();
     }
 }
Exemplo n.º 13
0
 /**
  * @see	\wcf\page\IPage::readData()
  */
 public function readData()
 {
     parent::readData();
     // get template groups
     $this->availableTemplateGroups = TemplateGroup::getSelectList(array(), 1);
     // get applications
     $applications = ApplicationHandler::getInstance()->getApplications();
     $applications[] = ApplicationHandler::getInstance()->getWCF();
     foreach ($applications as $application) {
         $package = PackageCache::getInstance()->getPackage($application->packageID);
         $this->availableApplications[ApplicationHandler::getInstance()->getAbbreviation($package->packageID)] = $package;
         // issues with the language cache would cause the uasort() below to throw a
         // misleading error message, calling it here just reveals the real error
         $package->getName();
     }
     uasort($this->availableApplications, function ($a, $b) {
         return $a->getName() > $b->getName();
     });
 }
Exemplo n.º 14
0
 /**
  * @see	\wcf\page\IPage::readData()
  */
 public function readData()
 {
     parent::readData();
     // add breadcrumbs
     if (MODULE_MEMBERS_LIST) {
         WCF::getBreadcrumbs()->add(new Breadcrumb(WCF::getLanguage()->get('wcf.user.members'), LinkHandler::getInstance()->getLink('MembersList')));
     }
     // load locations
     foreach (ObjectTypeCache::getInstance()->getObjectTypes('com.woltlab.wcf.user.online.location') as $objectType) {
         $this->locations[$objectType->controller] = $objectType;
     }
     // cache data
     foreach ($this->objectList as $userOnline) {
         if (isset($this->locations[$userOnline->controller]) && $this->locations[$userOnline->controller]->getProcessor()) {
             $this->locations[$userOnline->controller]->getProcessor()->cache($userOnline);
         }
     }
     // set locations
     foreach ($this->objectList as $userOnline) {
         if (isset($this->locations[$userOnline->controller])) {
             if ($this->locations[$userOnline->controller]->getProcessor()) {
                 $userOnline->setLocation($this->locations[$userOnline->controller]->getProcessor()->get($userOnline, $this->locations[$userOnline->controller]->languagevariable));
             } else {
                 $userOnline->setLocation(WCF::getLanguage()->get($this->locations[$userOnline->controller]->languagevariable));
             }
         }
     }
 }
 /**
  * @see	\wcf\page\IPage::readData()
  */
 public function readData()
 {
     parent::readData();
     // get categories
     $categoryTree = new FilebaseCategoryNodeTree('de.incendium.filebase.category');
     $this->categoryList = $categoryTree->getIterator();
     $this->categoryList->setMaxDepth(0);
     // add breadcrumbs
     FILEBASECore::getInstance()->setLocation($this->category->getParentCategories());
 }
 /**
  *
  * @see wcf\page\IPage::readData()
  */
 public function readData()
 {
     parent::readData();
     $categoryTree = new LinklistCategoryNodeTree('de.incendium.linklist.category');
     $this->categoryList = $categoryTree->getIterator();
     $this->categoryList->setMaxDepth(0);
     // add breadcrumbs
     LINKLISTCore::getInstance()->setLocation($this->category->getParentCategories());
 }