/** * Get current layer product collection * * @return Mage_Catalog_Model_Resource_Eav_Mysql4_Product_Collection */ public function getProductCollection() { if (!Mage::helper('factfinder')->isEnabled()) { return parent::getProductCollection(); } if (isset($this->_productCollections[$this->getCurrentCategory()->getId()])) { $collection = $this->_productCollections[$this->getCurrentCategory()->getId()]; } else { $collection = Mage::getResourceModel('factfinder/search_collection'); $this->prepareProductCollection($collection); $this->_productCollections[$this->getCurrentCategory()->getId()] = $collection; } return $collection; }
/** * Retrieve current layer product collection * * @return Mage_Catalog_Model_Resource_Eav_Mysql4_Product_Attribute_Collection */ public function getProductCollection() { if (Mage::helper('conversionpro')->getIsEngineAvailableForNavigation()) { if (isset($this->_productCollections[$this->getCurrentCategory()->getId()])) { $collection = $this->_productCollections[$this->getCurrentCategory()->getId()]; } else { //@todo switch to our helper. $collection = Mage::helper('catalogsearch')->getEngine()->getResultCollection(); $collection->setStoreId($this->getCurrentCategory()->getStoreId()); $this->prepareProductCollection($collection); $this->_productCollections[$this->getCurrentCategory()->getId()] = $collection; } return $collection; } else { return parent::getProductCollection(); } }