Skip to content

Commit 2a4e88a

Browse files
committed
MAGETWO-57651: Catalog Price not applying to bundle options
- Replaced table name
1 parent b41010b commit 2a4e88a

File tree

1 file changed

+6
-11
lines changed

1 file changed

+6
-11
lines changed

app/code/Magento/Catalog/Model/ProductCategoryList.php

Lines changed: 6 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@
55
*/
66
namespace Magento\Catalog\Model;
77

8+
use Magento\Catalog\Model\Indexer\Category\Product\AbstractAction;
89
use Magento\Framework\DB\Select;
910
use Magento\Framework\DB\Sql\UnionExpression;
10-
use Magento\Indexer\Model\ResourceModel\FrontendResource;
1111

1212
/**
1313
* Provides info about product categories.
@@ -29,24 +29,16 @@ class ProductCategoryList
2929
*/
3030
private $category;
3131

32-
/**
33-
* @var FrontendResource
34-
*/
35-
private $categoryProductIndexerFrontend;
36-
3732
/**
3833
* @param ResourceModel\Product $productResource
3934
* @param ResourceModel\Category $category
40-
* @param FrontendResource $categoryProductIndexerFrontend
4135
*/
4236
public function __construct(
4337
ResourceModel\Product $productResource,
44-
ResourceModel\Category $category,
45-
FrontendResource $categoryProductIndexerFrontend
38+
ResourceModel\Category $category
4639
) {
4740
$this->productResource = $productResource;
4841
$this->category = $category;
49-
$this->categoryProductIndexerFrontend = $categoryProductIndexerFrontend;
5042
}
5143

5244
/**
@@ -61,7 +53,10 @@ public function getCategoryIds($productId)
6153
$unionSelect = new UnionExpression(
6254
[
6355
$this->getCategorySelect($productId, $this->category->getCategoryProductTable()),
64-
$this->getCategorySelect($productId, $this->categoryProductIndexerFrontend->getMainTable())
56+
$this->getCategorySelect(
57+
$productId,
58+
$this->productResource->getTable(AbstractAction::MAIN_INDEX_TABLE)
59+
)
6560
],
6661
Select::SQL_UNION_ALL
6762
);

0 commit comments

Comments
 (0)