Backend Menu Item Disappeared in Magento 1.7 – How to Restore

adminconfigurationmagento-1.7

I'm managing a Magento installation for a client and I have installed one for development on the same server as well. There are a couple of custom modules in both installations. (They extend the BE as well as the FE.)

Now I have this weird situation that two menu items have disappeared from the Catalog menu in the admin panel, but only in the live installation. The menu items have been defined in the config.xml of a custom module.
However, if I copy/paste the URL of the admin module (e.g. index.php/managemanufacturer/adminhtml_managemanufacturerbackend/) it still works, in both installations! So, the module is properly installed. Only the menu items are gone.
How is this possible?

EDIT: Here is one of the config.xml files in question.

<?xml version="1.0"?>
<config>
  <modules>
    <Siwa_Mshipcalc>
      <version>0.1.0</version>
    </Siwa_Mshipcalc>
  </modules>
  <global>
    <models>
      <mshipcalc>
        <class>Siwa_Mshipcalc_Model</class>
      </mshipcalc>
    </models>
    <helpers>
      <mshipcalc>
        <class>Siwa_Mshipcalc_Helper</class>
      </mshipcalc>
    </helpers>
    <blocks>
      <mshipcalc>
        <class>Siwa_Mshipcalc_Block</class>
      </mshipcalc>
    </blocks>
    <resources>
      <mshipcalc_setup>
        <setup>
          <module>Siwa_Mshipcalc</module>
        </setup>
        <connection>
          <use>core_setup</use>
        </connection>
      </mshipcalc_setup>
      <mshipcalc_write>
        <connection>
          <use>core_write</use>
        </connection>
      </mshipcalc_write>
      <mshipcalc_read>
        <connection>
          <use>core_read</use>
        </connection>
      </mshipcalc_read>
    </resources>
  </global>
  <admin>
    <routers>
      <mshipcalc>
        <use>admin</use>
        <args>
          <module>Siwa_Mshipcalc</module>
          <frontName>mshipcalc</frontName>
        </args>
      </mshipcalc>
    </routers>
  </admin>
  <adminhtml>
    <acl>
      <resources>
        <all>
          <title>Allow Everything</title>
        </all>
        <admin>
          <children>
            <mshipcalc translate="title" module="mshipcalc">
              <title>Mshipcalc</title>
              <sort_order>1000</sort_order>
              <children>
                <mshipcalcbackend translate="title">
                  <title>Siwa Manufacturer Ship Calc</title>
                </mshipcalcbackend>
              </children>
            </mshipcalc>
          </children>
        </admin>
      </resources>
    </acl>
    <layout>
      <updates>
        <mshipcalc>
          <file>mshipcalc.xml</file>
        </mshipcalc>
      </updates>
    </layout>
    <menu>
      <catalog>
        <children>
          <mshipcalcbackend module="mshipcalc">
            <title>Manufacturer Ship Calc</title>
            <sort_order>1</sort_order>
            <action>mshipcalc/adminhtml_mshipcalcbackend</action>
          </mshipcalcbackend>
        </children>
      </catalog>
    </menu>
  </adminhtml>    
  <default>
    <carriers>
      <mshipcalc>
        <active>1</active>
        <model>Siwa_Mshipcalc_Model_Carrier_Mshipcalc</model>
        <name>mshipcalc</name>
        <title>MShipCalc</title>
        <description>Siwa Manufacturer Ship Calc</description>
        <sort_order>0</sort_order>
        <type>I</type>
        <handling_type>F</handling_type>
        <sallowspecific>0</sallowspecific>
      </mshipcalc>
    </carriers>
  </default>
</config>

Doesn't look wrong to me…

Best Answer

This is my guess what has most likely happened - somebody has modified the role permissions (most likely something unrelated to the module).

When you add a new path into the ACL node tree, by default people will be able to perform that action, despite the fact if you go to the Role management you will see that the field isn't checked. As soon as somebody saves the ACL for that role though, the ACL table will be updated and the person will no longer have permissions to perform the action.

If this is the case, simply going to System > Permissions > Roles ticking the box and saving should resolve the issue. NB: All users will have to log out and back in to update the ACL since the information is stored in your session when you first sign in.

Related Topic