Beispiel #1
0
 function getSubCategories()
 {
     $this->getBrowseCategory();
     if ($this->browseCategory) {
         // Set Selected Browse Category
         $this->browseCategory->getSubCategories();
         // add subcategory information to the selected category
         $subCategories = array();
         /** @var SubBrowseCategories $subCategory */
         foreach ($this->browseCategory->subBrowseCategories as $subCategory) {
             // Get Needed Info about sub-category
             /** @var BrowseCategory $temp */
             $temp = BrowseCategory::staticGet('id', $subCategory->subCategoryId);
             if ($temp) {
                 $this->subCategories[] = $temp;
                 $subCategories[] = array('label' => $temp->label, 'textId' => $temp->textId);
             }
         }
         if ($subCategories) {
             global $interface;
             $interface->assign('subCategories', $subCategories);
             $result = $interface->fetch('Search/browse-sub-category-menu.tpl');
             return $result;
         }
     }
 }