Skip to content

Commit

Permalink
🔃 [EngCom] Public Pull Requests - 2.1-develop
Browse files Browse the repository at this point in the history
Accepted Public Pull Requests:
 - #15933: Do not display anchor if admin submenu has no children (by @rogyar)
  • Loading branch information
Stanislav Idolov authored Jun 11, 2018
2 parents 6db65b0 + 1824663 commit 08ec01b
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions app/code/Magento/Backend/Block/Menu.php
Original file line number Diff line number Diff line change
Expand Up @@ -211,9 +211,12 @@ protected function _renderItemCssClass($menuItem, $level)
protected function _renderAnchor($menuItem, $level)
{
if ($level == 1 && $menuItem->getUrl() == '#') {
$output = '<strong class="submenu-group-title" role="presentation">'
. '<span>' . $this->_getAnchorLabel($menuItem) . '</span>'
. '</strong>';
$output = '';
if ($menuItem->hasChildren()) {
$output = '<strong class="submenu-group-title" role="presentation">'
. '<span>' . $this->_getAnchorLabel($menuItem) . '</span>'
. '</strong>';
}
} else {
$output = '<a href="' . $menuItem->getUrl() . '" ' . $this->_renderItemAnchorTitle(
$menuItem
Expand Down

0 comments on commit 08ec01b

Please sign in to comment.