コード例 #1
0
 /**
  * @see	\wcf\page\IPage::assignVariables()
  */
 public function assignVariables()
 {
     parent::assignVariables();
     I18nHandler::getInstance()->assignVariables(!empty($_POST));
     $availableCategories = new CategoryNodeTree($this->objectType->objectType, 0, true);
     WCF::getTPL()->assign(array('action' => 'edit', 'category' => $this->category, 'availableCategories' => $availableCategories->getIterator()));
 }
コード例 #2
0
ファイル: FileListPage.class.php プロジェクト: knzo/Fireball
 /**
  * @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();
 }
コード例 #3
0
 /**
  * @see	\wcf\page\IPage::assignVariables()
  */
 public function assignVariables()
 {
     parent::assignVariables();
     WCF::getTPL()->assign(array('addController' => $this->addController, 'categoryNodeList' => $this->categoryNodeTree->getIterator(), 'collapsedCategoryIDs' => $this->collapsedCategoryIDs, 'collapsibleObjectTypeID' => $this->collapsibleObjectTypeID, 'editController' => $this->editController, 'objectType' => $this->objectType));
     if ($this->pageTitle) {
         WCF::getTPL()->assign('pageTitle', $this->pageTitle);
     }
 }
コード例 #4
0
 /**
  * @see	\wcf\page\IPage::assignVariables()
  */
 public function assignVariables()
 {
     parent::assignVariables();
     I18nHandler::getInstance()->assignVariables();
     if ($this->aclObjectTypeID) {
         ACLHandler::getInstance()->assignVariables($this->aclObjectTypeID);
     }
     WCF::getTPL()->assign(array('aclObjectTypeID' => $this->aclObjectTypeID, 'action' => 'add', 'addController' => $this->addController, 'additionalData' => $this->additionalData, 'categoryNodeList' => $this->categoryNodeTree->getIterator(), 'editController' => $this->editController, 'isDisabled' => $this->isDisabled, 'listController' => $this->listController, 'objectType' => $this->objectType, 'parentCategoryID' => $this->parentCategoryID, 'showOrder' => $this->showOrder));
     if ($this->pageTitle) {
         WCF::getTPL()->assign('pageTitle', $this->pageTitle);
     }
 }
コード例 #5
0
 /**
  * @see	\wcf\data\category\CategoryNodeTree::buildTree()
  */
 protected function buildTree()
 {
     $categoryList = new CategoryList();
     $categoryList->getConditionBuilder()->add('category.objectTypeID = ?', array(CategoryHandler::getInstance()->getObjectTypeByName($this->objectType)->objectTypeID));
     $categoryList->readObjects();
     foreach ($categoryList as $category) {
         if (!isset($this->categoryStructureCache[$category->parentCategoryID])) {
             $this->categoryStructureCache[$category->parentCategoryID] = array();
         }
         $this->categoryStructureCache[$category->parentCategoryID][] = $category->categoryID;
         $this->categoryCache[$category->categoryID] = $category;
     }
     parent::buildTree();
 }
 /**
  * @see	\wcf\data\category\CategoryNodeTree::isIncluded()
  */
 public function isIncluded(CategoryNode $categoryNode)
 {
     return parent::isIncluded($categoryNode) && $categoryNode->isAccessible();
 }
コード例 #7
0
ファイル: FileAction.class.php プロジェクト: knzo/Fireball
 /**
  * Returns a formatted upload dialog.
  */
 public function getUploadDialog()
 {
     $categoryNodeTree = new CategoryNodeTree('de.codequake.cms.file', 0, true);
     $categoryList = $categoryNodeTree->getIterator();
     WCF::getTPL()->assign(array('categoryList' => $categoryList));
     return array('template' => WCF::getTPL()->fetch('fileUploadDialog', 'cms'), 'title' => WCF::getLanguage()->get('cms.acp.file.add'));
 }
コード例 #8
0
 /**
  * @see	\wcf\page\IPage::assignVariables()
  */
 public function assignVariables()
 {
     parent::assignVariables();
     I18nHandler::getInstance()->assignVariables();
     WCF::getTPL()->assign(array('action' => 'add', 'smileyTitle' => $this->smileyTitle, 'showOrder' => $this->showOrder, 'categoryID' => $this->categoryID, 'smileyCode' => $this->smileyCode, 'aliases' => $this->aliases, 'smileyPath' => $this->smileyPath, 'categoryNodeList' => $this->categoryNodeTree->getIterator(), 'uploadedFilename' => $this->uploadedFilename));
 }