55 \
Magento\Catalog\Model\
Product\WebsiteFactory $productWebsiteFactory,
63 $this->_productWebsiteFactory = $productWebsiteFactory;
66 $this->_productEavIndexerProcessor = $productEavIndexerProcessor;
90 $this->_eventManager->dispatch(
91 'catalog_product_attribute_update_before',
97 [
'product_ids' => array_unique(
$productIds),
'attributes_data' => $attrData,
'store_id' =>
$storeId]
101 $this->_productEavIndexerProcessor->reindexList(array_unique(
$productIds));
104 $categoryIndexer = $this->indexerRegistry->get(\
Magento\Catalog\Model\Indexer\
Product\Category::INDEXER_ID);
105 if (!$categoryIndexer->isScheduled()) {
106 $categoryIndexer->reindexList(array_unique(
$productIds));
157 if (
$type ==
'add') {
167 $categoryIndexer = $this->indexerRegistry->get(\
Magento\Catalog\Model\Indexer\
Product\Category::INDEXER_ID);
168 if (!$categoryIndexer->isScheduled()) {
169 $categoryIndexer->reindexList(array_unique(
$productIds));
setData($key, $value=null)
elseif(isset( $params[ 'redirect_parent']))
__construct(\Magento\Framework\Model\Context $context, \Magento\Framework\Registry $registry, \Magento\Catalog\Model\Product\WebsiteFactory $productWebsiteFactory, \Magento\Framework\Indexer\IndexerRegistry $indexerRegistry, \Magento\Eav\Model\Config $eavConfig, \Magento\Catalog\Model\Indexer\Product\Eav\Processor $productEavIndexerProcessor, \Magento\Framework\Model\ResourceModel\AbstractResource $resource=null, \Magento\Framework\Data\Collection\AbstractDb $resourceCollection=null, array $data=[])
updateAttributes($productIds, $attrData, $storeId)
updateWebsites($productIds, $websiteIds, $type)
_hasIndexableAttributes($attributesData)
$_productEavIndexerProcessor
_attributeIsIndexable($attribute)