How to show additional fields in magento abandoned carts grid

Share
Posted on January 16th, 2012 | Posted by admin

Magento Abandoned carts report gives the list of customers who have added products to the shopping cart and logged out without placing orders, the products they placed will still be in their cart. Abandoned carts report will be shown as a grid in admin panel. This report notifies the store owner about the customers who have abandoned their carts, later the store admin can inform to the respective customer and make them clear their cart.
Recently I got a client requirement to show the customer telephone field in the abondoned cart grid. As it will be useful for the admin to call customers and alert them to complete their orders.

To add additional field to abandoned carts

Step 1: Copy the file app\code\core\Mage\Adminhtml\Block\Report\Shopcart\Abandoned\Grid.php to the local directory app\code\local\Mage\Adminhtml\Block\Report\Shopcart\Abandoned\Grid.php. Whenever a Core file is copied to the local directory structure, the file included in the local directory will get preference and it will be taken.

Step 2: Now in the _prepareCollection method we need to join our additional field to the existing collection. A collection is an array of model class objects.

How to add additional row limit count in magento admin grid

Share
Posted on January 16th, 2012 | Posted by admin

Magento Provides the Grid Based Layout in adminpanel pages for most of the pages like manage customers,manage products etc. The default row limit options are 20,50,100,200 etc per page. But for the stores with more than 1000 products and customers these options are not sufficient to display the records in less no. of pages.

Step 1: For this example we are going to add an additonal row limit count as 500. To do this locate the file which is reponsible for showing row count dropdown. The file is located in

app/design/adminhtml/default/default/template/widget/grid.phtml

Step 2: Around line 81 the code is located as shown below

How to extend Magento Order Grid?

Share
Posted on May 11th, 2011 | Posted by admin

Here is small example which explains how to modify order grid. Main class for order grid is “Mage_Adminhtml_Block_Sales_Order_Grid”, if you want to add some column you have to rewrite this class (block).

Dynamic grids anyone?

Share
Posted on May 10th, 2011 | Posted by admin

For my second :) article I’m again writing about Ext.js. Ext.js has one great part for showing data – grids. These look really nice and you can style them pretty easily. It all works like a charm when you’re using them for static data. But what when things get dynamic? What when you don’t know the number of the headers that you need in the table and not just rows? Here’s where this article will help.

First lets input some data to our view(i used ajax requests). For the request I modeled my json so it has several parts: fields-name of the fields in table, results – data to be shown, and flag – is it input data our output(i had to make a sort of a spreadsheet where input and output data had to be separated.)

How to add massactions to Magento’s grid

Share
Posted on April 19th, 2011 | Posted by admin

This article describes how does Magento’s mass actions work and how to add them in your existing grids.

You need to do 2 things:
- extend the block (grid) class with “protected function _prepareMassaction()
- add an action into your controller, which will handle your desired logic.

In my example I have added mass action in existing Tax Rates Grid which can delete a large number of tax rates, not just delete them one by one.

Page 1 of 212»