Skip to content

Commit

Permalink
ENGCOM-2303: [Backport 2.1] Issue 14351: Product import doesn't chang…
Browse files Browse the repository at this point in the history
…e `Enable Qty Increments` field magento#14380
  • Loading branch information
Stanislav Idolov authored Jul 13, 2018
2 parents aa78f42 + 49a9966 commit 871f934
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@

namespace Magento\CatalogImportExport\Model\Import;

use Magento\CatalogInventory\Api\Data\StockItemInterface;
use Magento\Framework\App\Filesystem\DirectoryList;
use Magento\CatalogImportExport\Model\Import\Product\RowValidatorInterface as ValidatorInterface;
use Magento\Framework\Model\ResourceModel\Db\TransactionManagerInterface;
Expand Down Expand Up @@ -2549,7 +2550,10 @@ private function _setStockUseConfigFieldsValues($rowData)
{
$useConfigFields = array();
foreach ($rowData as $key => $value) {
$useConfigName = self::INVENTORY_USE_CONFIG_PREFIX . $key;
$useConfigName = $key === StockItemInterface::ENABLE_QTY_INCREMENTS
? StockItemInterface::USE_CONFIG_ENABLE_QTY_INC
: self::INVENTORY_USE_CONFIG_PREFIX . $key;

if (isset($this->defaultStockData[$key])
&& isset($this->defaultStockData[$useConfigName])
&& !empty($value)
Expand Down

0 comments on commit 871f934

Please sign in to comment.