-
Notifications
You must be signed in to change notification settings - Fork 9.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Saving via ProductRepository changes untouched attributes #7879
Comments
I think something in the eav system is seriously broken. I've tried adding another website with a store and store view (say having the id 2). Having a product (with id 1) and the following values: Store 0 Name: "Testproduct" Store 0 Description: "Test description" Then I tried to edit an attribute of the new store with the following code:
I expected this result: Store 0 Name: "Testproduct" Store 0 Description: "Test description" But I got this result: Store 0 Name: "Testproduct" Store 0 Description: "Test description" And every other attribute in store 1 got copied from store 2. |
Possible duplicate #7720 |
@ochnygosch, thank you for your report. |
Is there a quick fix for this? Experiencing this within Magento 2.2.1 when saving an a product trough the product repository for a store. So i do set the StoreId but some attributes (not all and kind of random) are getting 'use default value' unchecked while not setting those. Edit : This is not random. This is only on the attributes that have a default value |
Closing, as this issue duplicates #7720 |
Love it. Just stumbled upon this issue. Using Magento 2.4.3 this is still an issue and it's definitly not a duplicate of #7720. This issue should be reopened and the bug fixed. Maybe a new ticket should be raised but I'm really too tired of creating new issues here which are closed for completely bs reasons. |
B2B-2423: Optimize addProductsToCart operations
Saving a loaded product via the ProductRepository updates attribute values of unchanged attributes. Even loading a product and saving it without making changes can lead to a product no longer using default values for a store.
Preconditions
Steps to reproduce
Expected result
Actual result
Attached is a sample module that provides a backend controller that loads product with id 1 and saves it without changing an attribute.
ProductSave.zip
The text was updated successfully, but these errors were encountered: