Skip to content

Commit d7b0cfe

Browse files
authored
Merge pull request #23 from integer-net/indexing-bug-multistore
Indexing bug multistore
2 parents 2ff41c9 + cbafcdb commit d7b0cfe

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

src/app/code/community/IntegerNet/Solr/Model/Bridge/ProductRepository.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,9 @@ function($parentId, $childrenIds) {
7070
*/
7171
public function getAllProductIds()
7272
{
73+
// Fixes a bug with flat product collections called for different stores, see https://magento.stackexchange.com/q/30956/2207
74+
Mage::unregister('_resource_singleton/catalog/product_flat');
75+
7376
/** @var $productCollection Mage_Catalog_Model_Resource_Product_Collection */
7477
$productCollection = Mage::getResourceModel('catalog/product_collection');
7578
return $productCollection->getAllIds();

src/app/code/community/IntegerNet/Solr/Test/Model/Result.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ public function shouldUseParametersBasedOnToolbar()
9595
)
9696
);
9797
$logMock->expects($this->at(4))->method('debug')->with(
98-
'Filter Query: store_id:1 AND is_visible_in_search_i:1');
98+
'Filter Query: content_type:product AND store_id:1 AND is_visible_in_search_i:1');
9999

100100
/* @var Mage_Core_Block_Text $toolbar Not using actual toolbar block which reads from session */
101101
$toolbar = $this->app()->getLayout()->createBlock('core/text', 'product_list_toolbar');

0 commit comments

Comments
 (0)