@@ -349,12 +349,13 @@ class Product extends \Magento\ImportExport\Model\Export\Entity\AbstractEntity
349
349
private $ productEntityLinkField ;
350
350
351
351
/**
352
+ * Product constructor.
352
353
* @param \Magento\Framework\Stdlib\DateTime\TimezoneInterface $localeDate
353
354
* @param \Magento\Eav\Model\Config $config
354
355
* @param \Magento\Framework\App\ResourceConnection $resource
355
356
* @param \Magento\Store\Model\StoreManagerInterface $storeManager
356
357
* @param \Psr\Log\LoggerInterface $logger
357
- * @param \Magento\Catalog\Model\ResourceModel\Product\Collection $collection
358
+ * @param \Magento\Catalog\Model\ResourceModel\Product\CollectionFactory $collectionFactory
358
359
* @param \Magento\ImportExport\Model\Export\ConfigInterface $exportConfig
359
360
* @param \Magento\Catalog\Model\ResourceModel\ProductFactory $productFactory
360
361
* @param \Magento\Eav\Model\ResourceModel\Entity\Attribute\Set\CollectionFactory $attrSetColFactory
@@ -363,10 +364,10 @@ class Product extends \Magento\ImportExport\Model\Export\Entity\AbstractEntity
363
364
* @param \Magento\Catalog\Model\ResourceModel\Product\Option\CollectionFactory $optionColFactory
364
365
* @param \Magento\Catalog\Model\ResourceModel\Product\Attribute\CollectionFactory $attributeColFactory
365
366
* @param Product\Type\Factory $_typeFactory
366
- * @param \Magento\Catalog\Model\Product \LinkTypeProvider $linkTypeProvider
367
- * @param \Magento\CatalogImportExport\Model\Export\ RowCustomizerInterface $rowCustomizer
367
+ * @param ProductEntity \LinkTypeProvider $linkTypeProvider
368
+ * @param RowCustomizerInterface $rowCustomizer
368
369
* @param array $dateAttrCodes
369
- * @SuppressWarnings(PHPMD.ExcessiveParameterList)
370
+ * @throws \Magento\Framework\Exception\LocalizedException
370
371
*/
371
372
public function __construct (
372
373
\Magento \Framework \Stdlib \DateTime \TimezoneInterface $ localeDate ,
@@ -695,7 +696,9 @@ protected function updateDataWithCategoryColumns(&$dataRow, &$rowCategories, $pr
695
696
}
696
697
697
698
/**
698
- * {@inheritdoc}
699
+ * Get header columns
700
+ *
701
+ * @return string[]
699
702
*/
700
703
public function _getHeaderColumns ()
701
704
{
@@ -754,7 +757,10 @@ protected function _getExportMainAttrCodes()
754
757
}
755
758
756
759
/**
757
- * {@inheritdoc}
760
+ * Get entity collection
761
+ *
762
+ * @param bool $resetCollection
763
+ * @return \Magento\Framework\Data\Collection\AbstractDb
758
764
*/
759
765
protected function _getEntityCollection ($ resetCollection = false )
760
766
{
@@ -861,7 +867,10 @@ public function export()
861
867
}
862
868
863
869
/**
864
- * {@inheritdoc}
870
+ * Apply filter to collection and add not skipped attributes to select.
871
+ *
872
+ * @param \Magento\Eav\Model\Entity\Collection\AbstractCollection $collection
873
+ * @return \Magento\Eav\Model\Entity\Collection\AbstractCollection
865
874
* @since 100.2.0
866
875
*/
867
876
protected function _prepareEntityCollection (\Magento \Eav \Model \Entity \Collection \AbstractCollection $ collection )
@@ -923,8 +932,7 @@ protected function getExportData()
923
932
}
924
933
925
934
/**
926
- * Load products' data from the collection
927
- * and filter it (if needed).
935
+ * Load products' data from the collection and filter it (if needed).
928
936
*
929
937
* @return array Keys are product IDs, values arrays with keys as store IDs
930
938
* and values as store-specific versions of Product entity.
@@ -1066,6 +1074,8 @@ private function wrapValue($value)
1066
1074
}
1067
1075
1068
1076
/**
1077
+ * Collect multi raw data from
1078
+ *
1069
1079
* @return array
1070
1080
*/
1071
1081
protected function collectMultirawData ()
@@ -1107,6 +1117,8 @@ protected function collectMultirawData()
1107
1117
}
1108
1118
1109
1119
/**
1120
+ * Check the current data has multiselect value
1121
+ *
1110
1122
* @param \Magento\Catalog\Model\Product $item
1111
1123
* @param int $storeId
1112
1124
* @return bool
@@ -1119,6 +1131,8 @@ protected function hasMultiselectData($item, $storeId)
1119
1131
}
1120
1132
1121
1133
/**
1134
+ * Collect multiselect values based on value
1135
+ *
1122
1136
* @param \Magento\Catalog\Model\Product $item
1123
1137
* @param string $attrCode
1124
1138
* @param int $storeId
@@ -1143,6 +1157,8 @@ protected function collectMultiselectValues($item, $attrCode, $storeId)
1143
1157
}
1144
1158
1145
1159
/**
1160
+ * Check attribute is valid
1161
+ *
1146
1162
* @param string $code
1147
1163
* @param mixed $value
1148
1164
* @return bool
@@ -1162,6 +1178,8 @@ protected function isValidAttributeValue($code, $value)
1162
1178
}
1163
1179
1164
1180
/**
1181
+ * Append multi row data
1182
+ *
1165
1183
* @param array $dataRow
1166
1184
* @param array $multiRawData
1167
1185
* @return array
@@ -1291,6 +1309,8 @@ private function appendMultirowData(&$dataRow, $multiRawData)
1291
1309
}
1292
1310
1293
1311
/**
1312
+ * Add multi row data to export
1313
+ *
1294
1314
* @deprecated 100.1.0
1295
1315
* @param array $dataRow
1296
1316
* @param array $multiRawData
@@ -1338,6 +1358,8 @@ protected function _customHeadersMapping($rowData)
1338
1358
}
1339
1359
1340
1360
/**
1361
+ * Convert option row to cell string
1362
+ *
1341
1363
* @param array $option
1342
1364
* @return string
1343
1365
*/
0 commit comments