Skip to content

Commit

Permalink
some improvements
Browse files Browse the repository at this point in the history
  • Loading branch information
PululuK committed Mar 3, 2020
1 parent 17a7440 commit 033044a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 2 additions & 2 deletions classes/Tools.php
Expand Up @@ -4264,8 +4264,8 @@ public static function getPath($url_base, $id_category, $path = '', $highlight =
$n = 1;
$n_categories = (int) count($categories);
foreach ($categories as $category) {
$action = (($category['id_category'] == (int) Configuration::get('PS_HOME_CATEGORY') || $home) ? 'admin_categories_index' : 'admin_categories_edit');
$link = Context::getContext()->link->getAdminLink('AdminCategories',true, array('route'=>$action,'categoryId'=>(int) $category['id_category']));
$action = (($category['id_category'] == (int) Configuration::get('PS_HOME_CATEGORY') || $home) ? 'index' : 'updatecategory');
$link = Context::getContext()->link->getAdminLink('AdminCategories',true, array('action'=> $action,'categoryId'=> (int) $category['id_category']));
$edit = '<a href="' . Tools::safeOutput($link).'" title="' . ($category['id_category'] == Category::getRootCategory()->id_category ? 'Home' : 'Modify') . '"><i class="icon-' . (($category['id_category'] == Category::getRootCategory()->id_category || $home) ? 'home' : 'pencil') . '"></i></a> ';
$full_path .= $edit .
($n < $n_categories ? '<a href="' . Tools::safeOutput($link) . '" title="' . htmlentities($category['name'], ENT_NOQUOTES, 'UTF-8') . '">' : '') .
Expand Down
Expand Up @@ -5,6 +5,8 @@ admin_categories_index:
_controller: PrestaShopBundle:Admin\Sell\Catalog\Category:index
_legacy_controller: AdminCategories
_legacy_link: AdminCategories
_legacy_parameters:
id_category: categoryId
categoryId: null
requirements:
categoryId: '\d+'
Expand Down

0 comments on commit 033044a

Please sign in to comment.