Skip to content

Commit 4999592

Browse files
ACP2E-561 Base image label not updating when imported via CSV
1 parent 81340cb commit 4999592

File tree

2 files changed

+15
-0
lines changed

2 files changed

+15
-0
lines changed

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

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1541,6 +1541,8 @@ public function getImagesFromRow(array $rowData)
15411541
$labels[$column] = array_slice($labels[$column], 0, count($images[$column]));
15421542
}
15431543
}
1544+
} elseif (!empty($rowData[$column . '_label'])) {
1545+
$labels[$column] = $this->parseMultipleValues($rowData[$column . '_label']);
15441546
}
15451547
}
15461548

app/code/Magento/CatalogImportExport/Test/Unit/Model/Import/ProductTest.php

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1704,6 +1704,19 @@ public function getImagesFromRowDataProvider(): array
17041704
'_media_image' => ['label1', 'label2']
17051705
]
17061706
]
1707+
],
1708+
[
1709+
[
1710+
'image' => '',
1711+
'_media_image' => '',
1712+
'_media_image_label' => 'label1,label2'
1713+
],
1714+
[
1715+
[],
1716+
[
1717+
'_media_image' => ['label1', 'label2']
1718+
]
1719+
]
17071720
]
17081721
];
17091722
}

0 commit comments

Comments
 (0)