Returns url for fetching categories.

If sulu_product.category_root_key is specified only categories of this specific root key
are going to be fetched. Otherwise the whole category tree is returned.

@return string
770050
protected function getCategoryUrl()
    {
        $rootKey = $this->container->getParameter('sulu_product.category_root_key');

        if (null !== $rootKey) {
            return $this->generateUrl(
                'get_category_children',
                ['key' => $rootKey, 'flat' => 'true', 'sortBy' => 'depth', 'sortOrder' => 'asc']
            );
        }

        return $this->generateUrl(
            'get_categories',
            ['flat' => 'true', 'sortBy' => 'depth', 'sortOrder' => 'asc']
        );
    }
623192
public function getUrl()
    {
        if (!$this->isSortable()) {
            return '';
        }

        $params = ['sort_key' => $this->key];

        if ($this->isSortKey()) {
            $params['sort_order'] = $this->request->input('sort_order') == 'desc' ? 'asc' : 'desc';
        }

        return '?'.http_build_query($params + $this->request->all());
    }
830749
public function get_category_name() {
        global $DB;
        if ($this->categoryname === null) {
            $this->categoryname = $DB->get_field('user_info_category', 'name', ['id' => $this->field->categoryid]);
        }
        return $this->categoryname;
    }
495057
public function getCanonicalUrl()
    {
        if (($category = $this->getActiveCategory())) {
            $utilsUrl = \OxidEsales\Eshop\Core\Registry::getUtilsUrl();
            if (\OxidEsales\Eshop\Core\Registry::getUtils()->seoIsActive()) {
                $url = $utilsUrl->prepareCanonicalUrl(
                    $category->getBaseSeoLink($category->getLanguage(), $this->getActPage())
                );
            } else {
                $url = $utilsUrl->prepareCanonicalUrl(
                    $category->getBaseStdLink($category->getLanguage(), $this->getActPage())
                );
            }

            return $url;
        }
    }
148259
public function getEntryUri()
    {
        $oCategory = oxNew(\OxidEsales\Eshop\Application\Model\Category::class);
        if ($oCategory->load($this->getEditObjectId())) {
            return $this->_getEncoder()->getCategoryUri($oCategory, $this->getEditLang());
        }
    }
1300502
public static function getRootUrl()
    {
        if (empty(self::$root) && defined('ROOT_URL')) {
            self::$root = ROOT_URL;
            if (!preg_match("/\/$/", self::$root)) {
                self::$root .= '/';
            }
        }

        return self::$root;
    }
616754
public function getActiveCategory()
    {
        if ($this->_oActCategory === null) {
            $this->_oActCategory = false;
            if (($oManufacturerTree = $this->getManufacturerTree())) {
                if ($oManufacturer = $this->getActManufacturer()) {
                    $this->_oActCategory = $oManufacturer;
                }
            }
        }

        return $this->_oActCategory;
    }
353584
private function constructURL()
    {
        $cat = $this->getCategory()->getCat();
        $dashed = $this->getUrlisedTitle();
        $output = $cat.'/'.$this->getId().'/'.$dashed.'/'; // output: CAT/ID/TITLE/
        return $output;
    }
312333
function productCategoriesString()
    {
        $categories = $this->attribute( 'product_categories' );
        if ( !$categories )
        {
            $result = ezpI18n::tr( 'kernel/shop', 'Any' );
            return $result;
        }

        $categoriesNames = array();
        foreach ( $categories as $cat )
            $categoriesNames[] = $cat['name'];

        return join( ', ', $categoriesNames );
    }
1268698
public static function GetActiveRootCategory()
    {
        static $oActiveRootCategory = 'x';
        if ('x' === $oActiveRootCategory) {
            $oActiveRootCategory = null;
            $oActiveCategory = self::getShopService()->GetActiveCategory();
            if (null !== $oActiveCategory) {
                $oActiveRootCategory = $oActiveCategory->GetRootCategory();
            }
        }

        return $oActiveRootCategory;
    }
609981
public function getRoot($categoryId)
    {
        $category = CategoryQuery::create()->findPk($categoryId);

        if (0 !== $category->getParent()) {
            $parentCategory = CategoryQuery::create()->findPk($category->getParent());

            if (null !== $parentCategory) {
                $categoryId = $this->getRoot($parentCategory->getId());
            }
        }

        return $categoryId;
    }
861418
public function getUrl()
    {
        if ($this->idcat < 0) return false;     
        $url = '/'.$this->_alias;             
        if ( $this->getCatalog()->isServer() ) return $url;                   
        return rtrim($this->getCatalog()->getUrl(),'/').$url;
    }
384418
protected function _getCategoryBreadCrumb()
    {
        $paths = [];

        $categoryTree = $this->getCatTreePath();

        if ($categoryTree) {
            foreach ($categoryTree as $category) {
                /** @var \OxidEsales\Eshop\Application\Model\Category $category */
                $categoryPath = [];

                $categoryPath['link'] = $category->getLink();
                $categoryPath['title'] = $category->oxcategories__oxtitle->value;

                $paths[] = $categoryPath;
            }
        }

        return $paths;
    }
1272186
public function getQueryUrl()
    {
        if (isset($this->_url)) {
            $url = $this->_url;
        } else {
            $url = Zend_Gdata_Books::VOLUME_FEED_URI;
        }
        if ($this->getCategory() !== null) {
            $url .= '/-/' . $this->getCategory();
        }
        $url = $url . $this->getQueryString();
        return $url;
    }
922344
public function getUrl()
    {
        $query = $this->getQueryString();
        return sprintf('%s://%s/%s/%s%s',
            $this->getScheme(),
            trim($this->getHost(), '/'),
            trim($this->config->getRootEndpoint(), '/'),
            $this->getEntityType(),
            empty($query) ? '' : sprintf('?%s', $query)
        );
    }
542948
public function getUrlAttribute()
    {
        return url(trim(($this->parent ? $this->parent->full_slug : '').'/'.$this->slug, '/'));
    }
503883
protected function getSelectedCategory($categorySlug = null)
    {
        $selectedCategory = null;

        if ($categorySlug !== null) {
            $selectedCategory = $this->getCategoryRepository()->findOneBy(array('isActive' => true, 'slug' => $categorySlug));
        }

        return $selectedCategory;
    }