Skip to content
This repository was archived by the owner on Apr 29, 2019. It is now read-only.

Commit ac0c755

Browse files
author
Stanislav Idolov
authored
ENGCOM-2241: #88: Set store id on import product category initialization to 0 #112
2 parents a3e285f + 5eab03b commit ac0c755

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

app/code/Magento/CatalogImportExport/Model/Import/Product/CategoryProcessor.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,7 @@ protected function initCategories()
7575
$collection->addAttributeToSelect('name')
7676
->addAttributeToSelect('url_key')
7777
->addAttributeToSelect('url_path');
78+
$collection->setStoreId(\Magento\Store\Model\Store::DEFAULT_STORE_ID);
7879
/* @var $collection \Magento\Catalog\Model\ResourceModel\Category\Collection */
7980
foreach ($collection as $category) {
8081
$structure = explode(self::DELIMITER_CATEGORY, $category->getPath());
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
product_websites,store_view_code,attribute_set_code,product_type,categories,sku,price,name,url_key
2-
base,,Default,simple,Default Category/category-defaultstore,product,123,product,product
2+
base,,Default,simple,Default Category/category-admin,product,123,product,product
33
,default,Default,simple,,product,,product-default,product-default
44
,fixturestore,Default,simple,,product,,product-fixture,product-fixture

0 commit comments

Comments
 (0)