Customize tabs in customer edit page in backend

671 Views Asked by At

I need to customize the tabs in the customer edit page in the backend. The requirement is that all the tabs on the left column should be moved to the main content block and they should be displayed inline. I had implemented this by customizing the customer.xml file and setting a customized template for the tabs block. How can I remove some tabs from the default set of tabs? For accomplishing the same, I tried overriding _beforeToHtml() method of Mage_Adminhtml_Block_Customer_Edit_Tabs by block rewrites. Even though I could remove some tabs using the removeTab() method, I am not able to remove some tabs such as 'Recurring Profiles (beta)'. What is the proper way to remove tabs and where exactly is the tabs array set.

1

There are 1 best solutions below

0
On BEST ANSWER

Billing Agreements and Recurring Profiles (beta) Tabs comes from "app/design/adminhtml/default/default/layout/sales.xml" In this file find below code and remove tab as per your requirement. You can override this block in your xml file too. If you override then use removeTab method.

<adminhtml_customer_edit>
    <reference name="customer_edit_tabs">
        <action method="addTab"><name>customer_edit_tab_agreements</name><block>sales/adminhtml_customer_edit_tab_agreement</block></action>
        <action method="addTab"><name>customer_edit_tab_recurring_profile</name><block>sales/adminhtml_customer_edit_tab_recurring_profile</block></action>
    </reference>
</adminhtml_customer_edit>