Removing an Item from Magento's Admin Panel Navigation

后端 未结 4 427
眼角桃花
眼角桃花 2020-12-30 05:11

Using the Magento Ecommerce system, is is possible to remove an item from the Admin Panel Navigation menu? More generally, is there a way to use the config override system

相关标签:
4条回答
  • 2020-12-30 05:26

    You could inject a bogus module dependency into the menu item in your config.xml.

    In your case,

    <adminhtml>
      <menu>
        <cms translate="title" module="cms">
          <depends><module>HideMe</module></depends>
        </cms>
      </menu>
    </adminhtml>
    
    0 讨论(0)
  • 2020-12-30 05:35

    Cleaner way to do this:

    Add a adminhtml.xml (e.g. to an existing modules that keeps all other customization stuff, or create a new module)

    <?xml version="1.0" ?>
    <config>
        <menu>
            <xmlconnect>
                <disabled>1</disabled>
            </xmlconnect>
        </menu>
    </config>
    
    0 讨论(0)
  • 2020-12-30 05:50

    I don't think Alan would still need anyone to ask this question, but for anyone else that might end up reading this, it would be a bit better to use:

    <adminhtml>
      <menu>
        <cms translate="title" module="cms">
          <depends><config>some/configuration/flag</config></depends>
        </cms>
      </menu>
    </adminhtml>
    
    0 讨论(0)
  • 2020-12-30 05:50

    For a specific menu point you can use:

    <?xml version="1.0"?>
    <config>
        <menu>
            <customer>
                <children>
                    <online>
                        <disabled>1</disabled>
                    </online>
                </children>
            </customer>
        </menu>
    </config>
    
    0 讨论(0)
提交回复
热议问题