Skip to content

Instantly share code, notes, and snippets.

@WinstonN
Created December 30, 2014 06:08
Show Gist options
  • Save WinstonN/216ebdf56250c2d4f2d3 to your computer and use it in GitHub Desktop.
Save WinstonN/216ebdf56250c2d4f2d3 to your computer and use it in GitHub Desktop.
<?php
// observer
public function addStockItemData($observer)
{
$collection = $observer->getCollection();
Mage::getSingleton('cataloginventory/stock')->addItemsToProducts($collection);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment