2

Magento version 1.9

I want to create a copy of manage product in a new menu in magento admin. I created the menu and i am struck with copying the product view grid and rest of the thing.Can any one help me please to achieve this task.

My config.xml file

<config>  
<modules> 
    <Eight25media_Tproducts> 
        <version>0.1.0</version>
    </Eight25media_Tproducts>
</modules>
<global>
    <helpers>
        <tproducts>
            <class>Eight25media_Tproducts_Helper</class>
        </tproducts>
    </helpers>
</global>
<admin>
    <routers>
        <adminhtml>             
            <args>
                <modules>
                    <tproducts>Eight25media_Tproducts_Adminhtml</tproducts>
                </modules>
            </args>
        </adminhtml>
    </routers>
</admin>

My adminhtml.xml file

<config>  
<menu>
    <tproducts translate="title" module="tproducts">
        <title>Products - Training</title>
        <sort_order>100</sort_order>
        <children>
            <manage_tproducts>
                <title>Manage Products(Training) </title>
                <sort_order>1</sort_order>
                <action>adminhtml/catalog_product/</action>
            </manage_tproducts>
        </children>
    </tproducts>
</menu>

For now, i just called the catalog_product link. But i want to call in my own frontend name.

How can i implement this?

2

you are missing after="Mage_Adminhtml" in config.xml

<admin>
    <routers>
        <adminhtml>             
            <args>
                <modules>
                    <tproducts after="Mage_Adminhtml">Eight25media_Tproducts_Adminhtml</tproducts>
                </modules>
            </args>
        </adminhtml>
    </routers>
</admin>

then simply call the <action>adminhtml/controllername_actionname/</action>

simply extends your grid block with all grid will be loaded

 class Eight25media_Tproducts_Block_Adminhtml_Tproducts_Grid extends Mage_Adminhtml_Block_Catalog_Product_Grid 
{


}

now all the action will goes to your controller

you want to just add the block nothing to change just add this xml in your layout

<reference name="content">
            <block type="adminhtml/catalog_product" name="products_list">
                <block type="adminhtml/store_switcher" name="store_switcher" as="store_switcher">
                    <action method="setUseConfirm"><params>0</params></action>
                </block>
            </block>
        </reference> 
| improve this answer | |
  • Thank you. I can view the menu.My question is how to make a clone of catalog ->manage products – Mujahidh Jan 31 '17 at 6:20
  • @mujas you want to show the product grid? – Qaisar Satti Jan 31 '17 at 6:22
  • yes under my link name as well as all actions related to product. – Mujahidh Jan 31 '17 at 6:25
  • here is you can do create the your grid container and then your grid and extends your grid with magento product grid. hope this will work for you. – Qaisar Satti Jan 31 '17 at 6:27
  • can you pleas explain this as an answer,i ave no clue or idea to implement.Great help – Mujahidh Jan 31 '17 at 6:28

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.