Tag Archives: grid

Magento Grid View Debug

In order to check if everything is working properly in your grid view you maybe will be willing to check that the SQL statements look as you expected:

Way to do that in Magento is $collection -> load(true); to the _prepareCollection() of the Grid view that you want to debug
Continue reading Magento Grid View Debug

Magento status and created_at grid view issues

Have you ever tried to change the Magento Grid View collections to a custom selects and joins?

For example you want your Invoice Grid to take some columns from the Order table:

 

Continue reading Magento status and created_at grid view issues

Magento join – EAV and Flat table

Case 1: After the Magento join, we want to have a EAV Collection as a result collection

//the ‘1’ is just a example of a where clause, you can totally miss this part, if you do not need it :)


$collection = Mage::getModel('catalog/product_link')
                    ->useRelatedLinks()
                    ->getProductCollection()
                    ->joinTable('sales/order_item',
                                'product_id=entity_id',
                                array('*'),
                                'entity_id=1',
                                'left');

Continue reading Magento join – EAV and Flat table