You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Let's say that I create a module that should remove a backend menu item. I still don't have a valid use case, but let's say I want that. :).
I see that there is already a menu command for that.
in theory it should work if I add this to my adminhtml/menu.xml file:
<remove id="Dummy_Demo::dummy" />
Doing this throws an exeption:
Missing required param title
#0 MAGENTO_ROOT/app/code/Magento/Backend/Model/Menu/Item.php(184): Magento\Backend\Model\Menu\Item\Validator->validate(Array)
This happense because the 'title' attribute is marked as required in Magento\Backend\Model\Menu\Item\Validator::$_required. I tried adding a dummy title on the remove command
Let's say that I create a module that should remove a backend menu item. I still don't have a valid use case, but let's say I want that. :).
I see that there is already a menu command for that.
in theory it should work if I add this to my adminhtml/menu.xml file:
Doing this throws an exeption:
This happense because the 'title' attribute is marked as required in
Magento\Backend\Model\Menu\Item\Validator::$_required
. I tried adding a dummy title on the remove commandBut "no go". In this case my xml is not valid, because the
remove
tag does not support atitle
attribute, as defined inMagento/Backend/etc/menu.xsd
[EDIT]:
the same goes for the
resource
attribute and for the<update>
command.Note. It works if I try to remove a core menu, but a non-core one.
The text was updated successfully, but these errors were encountered: