/** * @see \wcf\page\IPage::assignVariables() */ public function assignVariables() { parent::assignVariables(); $lastEventTime = $this->eventList->getLastEventTime(); // removes orphaned and non-accessable events UserActivityEventHandler::validateEvents($this->eventList); DashboardHandler::getInstance()->loadBoxes('com.woltlab.wcf.user.MembersListPage', $this); WCF::getTPL()->assign(array('eventList' => $this->eventList, 'lastEventTime' => $lastEventTime, 'sidebarCollapsed' => UserCollapsibleContentHandler::getInstance()->isCollapsed('com.woltlab.wcf.collapsibleSidebar', 'com.woltlab.wcf.user.MembersListPage'), 'sidebarName' => 'com.woltlab.wcf.user.MembersListPage', 'allowSpidersToIndexThisPage' => true)); }
/** * Toggles the collapse status of categories. */ public function toggleContainer() { $objectTypeID = UserCollapsibleContentHandler::getInstance()->getObjectTypeID($this->objects[0]->getCategoryType()->getCollapsibleObjectTypeName()); $collapsedCategories = UserCollapsibleContentHandler::getInstance()->getCollapsedContent($objectTypeID); $categoryID = $this->objects[0]->categoryID; if (array_search($categoryID, $collapsedCategories) !== false) { UserCollapsibleContentHandler::getInstance()->markAsOpened($objectTypeID, $categoryID); } else { UserCollapsibleContentHandler::getInstance()->markAsCollapsed($objectTypeID, $categoryID); } }
/** * Toggles a sidebar. */ public function toggle() { $isOpen = isset($_POST['isOpen']) ? intval($_POST['isOpen']) : 1; $objectID = isset($_POST['sidebarName']) ? StringUtil::trim($_POST['sidebarName']) : ''; if (empty($objectID)) { throw new UserInputException('sidebarName'); } $objectTypeID = UserCollapsibleContentHandler::getInstance()->getObjectTypeID('com.woltlab.wcf.collapsibleSidebar'); if ($isOpen) { UserCollapsibleContentHandler::getInstance()->markAsOpened($objectTypeID, $objectID); } else { UserCollapsibleContentHandler::getInstance()->markAsCollapsed($objectTypeID, $objectID); } }
/** * @see \wcf\data\IToggleContainerAction::toggleContainer() */ public function toggleContainer() { $collapsibleObjectTypeName = $this->objects[0]->getProcessor()->getObjectTypeName('com.woltlab.wcf.collapsibleContent'); if ($collapsibleObjectTypeName === null) { throw new SystemException("Categories of this type don't support collapsing"); } $objectTypeID = UserCollapsibleContentHandler::getInstance()->getObjectTypeID($collapsibleObjectTypeName); $collapsedCategories = UserCollapsibleContentHandler::getInstance()->getCollapsedContent($objectTypeID); $categoryID = $this->objects[0]->categoryID; if (array_search($categoryID, $collapsedCategories) !== false) { UserCollapsibleContentHandler::getInstance()->markAsOpened($objectTypeID, $categoryID); } else { UserCollapsibleContentHandler::getInstance()->markAsCollapsed($objectTypeID, $categoryID); } }
/** * @see \wcf\page\AbstractPage::assignVariables() */ public function assignVariables() { parent::assignVariables(); MessageQuoteManager::getInstance()->assignVariables(); WCF::getTPL()->assign(array('allowSpidersToIndexThisPage' => true, 'attachmentList' => $this->entry->getAttachments(), 'commentCanAdd' => WCF::getSession()->getPermission('user.news.canWriteComment'), 'commentList' => $this->commentList, 'commentObjectTypeID' => $this->objectTypeID, 'lastCommentTime' => $this->commentList->getMinCommentTime(), 'likeData' => MODULE_LIKE ? $this->commentList->getLikeData() : array(), 'entry' => $this->entry, 'entryLikeData' => $this->entryLikeData, 'sidebarCollapsed' => UserCollapsibleContentHandler::getInstance()->isCollapsed('com.woltlab.wcf.collapsibleSidebar', 'de.incendium.cms.NewsEntryPage'), 'sidebarName' => 'de.incendium.cms.NewsPage', 'tags' => $this->tags, 'moreEntryList' => $this->moreEntryList)); }
/** * @see \wcf\page\IPage::assignVariables() */ public function assignVariables() { parent::assignVariables(); DashboardHandler::getInstance()->loadBoxes('com.woltlab.wcf.user.MembersListPage', $this); WCF::getTPL()->assign(array('sidebarCollapsed' => UserCollapsibleContentHandler::getInstance()->isCollapsed('com.woltlab.wcf.collapsibleSidebar', 'com.woltlab.wcf.user.MembersListPage'), 'sidebarName' => 'com.woltlab.wcf.user.MembersListPage', 'allowSpidersToIndexThisPage' => true)); }
/** * @see wcf\page\IPage::readData() */ public function readData() { $this->objectType = CategoryHandler::getInstance()->getObjectTypeByName($this->objectTypeName); if ($this->objectType === null) { throw new SystemException("Unknown category object type with name '".$this->objectTypeName."'"); } // check permissions $this->checkCategoryPermissions(); $this->readCategories(); // note that the implementation of wcf\system\category\ICategoryType // needs to support a object type of the pseudo definition // 'com.woltlab.wcf.collapsibleContent.acp' which has to be registered // during package installation as a 'com.woltlab.wcf.collapsibleContent' // object type if you want to support collapsible categories in the // acp; the pseudo object type is used to distinguish between // collapsible categories in the frontend and the acp $collapsibleObjectTypeName = $this->objectType->getProcessor()->getObjectTypeName('com.woltlab.wcf.collapsibleContent.acp'); if ($collapsibleObjectTypeName) { $this->collapsibleObjectTypeID = UserCollapsibleContentHandler::getInstance()->getObjectTypeID($collapsibleObjectTypeName); // get ids of collapsed category if ($this->collapsibleObjectTypeID !== null) { $this->collapsedCategoryIDs = UserCollapsibleContentHandler::getInstance()->getCollapsedContent($this->collapsibleObjectTypeID); $this->collapsedCategoryIDs = array_flip($this->collapsedCategoryIDs); } } parent::readData(); }
public function assignVariables() { parent::assignVariables(); DashboardHandler::getInstance()->loadBoxes('de.codequake.cms.news.news', $this); WCF::getTPL()->assign(array('newsID' => $this->newsID, 'news' => $this->news, 'likeData' => MODULE_LIKE && $this->commentList ? $this->commentList->getLikeData() : array(), 'newsLikeData' => $this->likeData, 'commentCanAdd' => WCF::getUser()->userID && WCF::getSession()->getPermission('user.cms.news.canAddComment'), 'commentList' => $this->commentList, 'commentObjectTypeID' => $this->commentObjectTypeID, 'tags' => $this->tags, 'lastCommentTime' => $this->commentList ? $this->commentList->getMinCommentTime() : 0, 'attachmentList' => $this->news->getAttachments(), 'allowSpidersToIndexThisPage' => true, 'sidebarCollapsed' => UserCollapsibleContentHandler::getInstance()->isCollapsed('com.woltlab.wcf.collapsibleSidebar', 'de.codequake.cms.news.news'), 'sidebarName' => 'de.codequake.cms.news.news')); }
/** * @see \wcf\page\IPage::assignVariables() */ public function assignVariables() { parent::assignVariables(); WCF::getTPL()->assign(array('assignedUserID' => $this->assignedUserID, 'queue' => $this->queue, 'queueID' => $this->queueID, 'commentCanAdd' => true, 'commentList' => $this->commentList, 'commentObjectTypeID' => $this->commentObjectTypeID, 'lastCommentTime' => $this->commentList ? $this->commentList->getMinCommentTime() : 0, 'sidebarCollapsed' => UserCollapsibleContentHandler::getInstance()->isCollapsed('com.woltlab.wcf.collapsibleSidebar', 'com.woltlab.wcf.ModerationForm'), 'sidebarName' => 'com.woltlab.wcf.ModerationForm')); }
public function assignVariables() { parent::assignVariables(); DashboardHandler::getInstance()->loadBoxes('de.codequake.cms.news.newsList', $this); WCF::getTPL()->assign(array('category' => $this->category, 'categoryID' => $this->categoryID, 'controller' => 'NewsList', 'allowSpidersToIndexThisPage' => true, 'sidebarCollapsed' => UserCollapsibleContentHandler::getInstance()->isCollapsed('com.woltlab.wcf.collapsibleSidebar', 'de.codequake.cms.news.newsList'), 'sidebarName' => 'de.codequake.cms.news.newsList', 'categoryList' => $this->categoryList)); }
/** * @see \wcf\page\IPage::assignVariables() */ public function assignVariables() { parent::assignVariables(); // configuration for dashboard boxes DashboardHandler::getInstance()->loadBoxes('de.voolia.news.NewsOverviewPage', $this); WCF::getTPL()->assign(array('letters' => str_split(self::$availableLetters), 'letter' => $this->letter, 'stats' => $this->stats, 'categoryID' => $this->categoryID, 'category' => $this->category, 'categoryList' => $this->categoryList, 'sidebarCollapsed' => UserCollapsibleContentHandler::getInstance()->isCollapsed('com.woltlab.wcf.collapsibleSidebar', 'de.voolia.news.NewsOverviewPage'), 'sidebarName' => 'de.voolia.news.NewsOverviewPage', 'usersOnlineList' => $this->usersOnlineList, 'statistics' => $this->statistics, 'user' => $this->user, 'userID' => $this->userID, 'allowSpidersToIndexThisPage' => true)); }
/** * @see \wcf\page\IPage::assignVariables() */ public function assignVariables() { parent::assignVariables(); DashboardHandler::getInstance()->loadBoxes('com.woltlab.wcf.user.MembersListPage', $this); WCF::getTPL()->assign(array('letters' => str_split(self::$availableLetters), 'letter' => $this->letter, 'searchID' => $this->searchID, 'sidebarCollapsed' => UserCollapsibleContentHandler::getInstance()->isCollapsed('com.woltlab.wcf.collapsibleSidebar', 'com.woltlab.wcf.user.MembersListPage'), 'sidebarName' => 'com.woltlab.wcf.user.MembersListPage', 'allowSpidersToIndexThisPage' => true)); if (count($this->objectList) === 0) { @header('HTTP/1.0 404 Not Found'); } }
/** * @see \wcf\page\IPage::assignVariables() */ public function assignVariables() { parent::assignVariables(); DashboardHandler::getInstance()->loadBoxes('com.woltlab.wcf.user.MembersListPage', $this); WCF::getTPL()->assign(array('username' => $this->username, 'optionTree' => $this->optionTree, 'sidebarCollapsed' => UserCollapsibleContentHandler::getInstance()->isCollapsed('com.woltlab.wcf.collapsibleSidebar', 'com.woltlab.wcf.user.MembersListPage'), 'sidebarName' => 'com.woltlab.wcf.user.MembersListPage')); }
/** * @see \wcf\page\IPage::assignVariables() */ public function assignVariables() { parent::assignVariables(); WCF::getTPL()->assign(array('contentNodeTree' => $this->contentNodeTree, 'sidebarNodeTree' => $this->sidebarNodeTree, 'page' => $this->page, 'likeData' => MODULE_LIKE && $this->commentList ? $this->commentList->getLikeData() : array(), 'commentCanAdd' => WCF::getUser()->userID && $this->page->getPermission('canAddComment'), 'commentList' => $this->commentList, 'commentObjectTypeID' => $this->commentObjectTypeID, 'lastCommentTime' => $this->commentList ? $this->commentList->getMinCommentTime() : 0, 'allowSpidersToIndexThisPage' => $this->page->allowIndexing)); // sidebar WCF::getTPL()->assign(array('sidebarCollapsed' => UserCollapsibleContentHandler::getInstance()->isCollapsed('com.woltlab.wcf.collapsibleSidebar', 'de.codequake.cms.page'), 'sidebarName' => 'de.codequake.cms.page')); }
/** * @see \wcf\page\AbstractPage::assignVariables() */ public function assignVariables() { parent::assignVariables(); MessageQuoteManager::getInstance()->assignVariables(); // configuration for dashboard boxes DashboardHandler::getInstance()->loadBoxes('de.voolia.news.NewsPage', $this); WCF::getTPL()->assign(array('allowSpidersToIndexThisPage' => true, 'attachmentList' => $this->news->getAttachments(), 'commentCanAdd' => WCF::getSession()->getPermission('user.news.canWriteComment'), 'commentList' => $this->commentList, 'commentObjectTypeID' => $this->objectTypeID, 'lastCommentTime' => $this->commentList->getMinCommentTime(), 'likeData' => MODULE_LIKE ? $this->commentList->getLikeData() : array(), 'news' => $this->news, 'newsLikeData' => $this->newsLikeData, 'sidebarCollapsed' => UserCollapsibleContentHandler::getInstance()->isCollapsed('com.woltlab.wcf.collapsibleSidebar', 'de.voolia.news.NewsPage'), 'sidebarName' => 'de.voolia.news.NewsPage', 'tags' => $this->tags, 'moreNewsList' => $this->moreNewsList)); }