akeneo / magento2-connector-community

Akeneo Connector for Magento 2
Open Software License 3.0
80 stars 87 forks source link

handleNoName() overrides admin channel value, when Product has no name set in one of the Channels #656

Open sri-ndc opened 10 months ago

sri-ndc commented 10 months ago

Information on your environment

Akeneo v6.0.61 Akeneo Connector v104.0.0 Magento ver. 2.4.5-p1

Summary of the issue

During Product Import in the insertData() function calls a function handleNoName(). This function is supposed to add a name for a magento product if none exists. The function adds an Attribute value without adding scope and locale information.

Steps to reproduce

Configure product with name attribute and two channels, only have an attribute value in the admin channel.

Expected and actual results

When there is no name attribute value for a channel, it results in the admin channel value being overriden by an empty string. I would expect the function to set empty name attribute values only for the specific channel where the name is missing. For that the handleNoName function would need information about the variable $filter from the calling insertData() function.