Magento – Override Store Controller magento admin

ce-1.7.0.2configurationcontrollersoverrides

I want to override the default functionality of stores (adding some fields like commission , location to deliver etc ), but i am not able to configure it. My configure file as follows

    <config>
  ...

    <admin>
        <routers>
            <adminhtml>
                <args>
                    <modules>
                        <store before="Mage_Adminhtml">Mycompany_Store_Adminhtml_Store</store>
                    </modules>
                </args>
            </adminhtml>
        </routers>
</admin>
 </global>
....
 </config>

It doesnt work at all.

Best Answer

With my comment on Marius' answer, his solution should work.

However, you c/should be doing this using system.xml, which allows you to specify fields in System Configuration. You can then read these values using Mage::getStoreConfig() and perform the logic which you need.

<sections>
    <general>
        <groups>
            <store_information>
                <fields>
                    <commission>
                        <label>Commission</label>
                        <frontend_type>text</frontend_type>
                        <sort_order>10</sort_order>
                        <show_in_default>1</show_in_default>
                        <show_in_website>1</show_in_website>
                        <show_in_store>1</show_in_store>
                    </commission>
                </fields>
            </store_information>
        </groups>
    </general>
</sections>
Related Topic