I have added a custom tab using xml layout updates to the order view in Magento. I have then added a custom grid to the new tab and enabled Ajax on the grid. I have set setUseAjax(true) and setSaveParametersInSession(true). I have overridden the gridUrl method to return the controller method that should be used. In the controller method, I call loadLayout and create the grid block in the response body.

What now happens is that when I try to sort or filter on the grid, the grid data is returned, but the Please wait... loading element from Ajax does not disappear once the data is returned. I have made other custom grids with the same setup and it has worked fine, but some reason or another, it is not working here.

Does anyone have any comments or suggestions as to what could be going wrong here?

I have viewed the following posts about this:

1 Answer 1


Check on filter which method called in fire bug, you need to add your custom grid in same handle in sales.xml file

Updated ===>

load custom grid with unique name like "order-search2", then check load block in loadBlockAction() method of Mage_Adminhtml_Sales_Order_CreateController (Or you can overrider this controller in you custom module) and depending on custom block update handle of search like as

foreach ($blocks as $block) { 
   if($block == 'search_grid'){
       $searchblock = Mage::getSingleton('core/session')->getSearchArea();
       if($searchblock =='order-search2'){

write handle in sales.xml for the same

        <reference name="content">
            <block type="yourmodule/sales_order_create_search_grid2" name="grid2" />

Call this handle under

<reference name="root">
    <block type="adminhtml/sales_order_create" name="content">
        <block type="adminhtml/sales_order_create_form" template="sales/order/create/form.phtml" name="form">
            <block type="adminhtml/sales_order_create_data" template="sales/order/create/data.phtml" name="data">
                <block type="adminhtml/sales_order_create_search" template="sales/order/create/abstract.phtml" name="search2">
                            <block type="disableorders/sales_order_create_search_grid2" name="grid2" />

I Hope this will help you.

  • Are you able to explain a bit more? Why does it need to be added to sales.xml? Commented Mar 13, 2016 at 22:02
  • Are you able to explain a bit more what you mean? Commented Mar 18, 2016 at 20:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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