2

Is it possible to configure some items from back-office's application_menu to open in a new browser tab?

enter image description here

There is an option called "Target Window" for frontend_menu but not for application_menu.

BorisD
  • 73
  • 5

2 Answers2

1

Yes, it is possible with the navigation.yml configuration that is merged across all the installed bundles.

You can use the link_attributes option to specify the target _blank for the menu item link.

E.g.:

link_attributes:
  target: _blank

For more details on navigation.yml features, see the OroNavigationBundle documentation.

Andrey Yatsenko
  • 1,936
  • 1
  • 11
  • 13
1

Looks like there is a bug with "link_attributes"

An exception has been thrown during the rendering of a template ("Cannot parse "Resources/config/oro/navigation.yml" configuration. 
Unrecognized option "link_attributes" under "navigation.menu_config.items.test_item". 
Did you mean "linkAttributes"?").

This works linkAttributes:

      test_item:
        label: 'Test Item'
        uri: 'link'
        linkAttributes:
          target: _blank
    tree:
      application_menu:
        children:
          ttttt:
            children:
              test_item: ~
BorisD
  • 73
  • 5
  • Thank you, Boris. We will fix the documentation then. Next time, please report bugs directly to Oro repositories, where it's much easier to track them: https://doc.oroinc.com/community/issues/ – Andrey Yatsenko Apr 04 '21 at 09:17