Skip to content
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

[BUG] [Magento 2.1.2] Programmatically creating an empty dropdown attribute, "apply_to" is set to NULL (from "simple") after adding options through store admin #7225

Closed
rendyep opened this issue Oct 28, 2016 · 2 comments
Assignees
Labels
bug report Component: Catalog Issue: Clear Description Gate 2 Passed. Manual verification of the issue description passed Issue: Confirmed Gate 3 Passed. Manual verification of the issue completed. Issue is confirmed Issue: Format is valid Gate 1 Passed. Automatic verification of issue format passed Issue: Ready for Work Gate 4. Acknowledged. Issue is added to backlog and ready for development Reproduced on 2.1.x The issue has been reproduced on latest 2.1 release Reproduced on 2.2.x The issue has been reproduced on latest 2.2 release Reproduced on 2.3.x The issue has been reproduced on latest 2.3 release

Comments

@rendyep
Copy link

rendyep commented Oct 28, 2016

Preconditions

  1. Magento 2.1.2
  2. Windows 10
  3. PHP 7.0.12
  4. MySQL 5.6.30

Steps to reproduce

  1. Create an empty dropdown product attribute named "price_unit" programmatically through InstallData.php, set "apply_to" to "simple".
  2. After setup:upgrade, things are going fine. In store admin, the "price_unit" attribute is shown on simple product create or edit page (an empty dropdown), and is hidden on other products create or edit page. The content of "apply_to" field of the current attribute in database table of "catalog_eav_attribute" is also "simple".
  3. After adding attribute options through store admin, the "price_unit" attribute is shown on all products create or edit page (dropdown with added options). The content of "apply_to" field of the current attribute in database table of "catalog_eav_attribute" become "null".

Expected result

  1. The "price_unit" attribute is shown on simple product create or edit page (an empty dropdown), and is hidden on other products create or edit page.
  2. The content of "apply_to" field of the current attribute in database table of "catalog_eav_attribute" is also "simple".

Actual result

  1. The "price_unit" attribute is shown on all products create or edit page.
  2. The content of "apply_to" field of the current attribute in database table of "catalog_eav_attribute" is "null".

Possibly related issue(s)

  1. 'Apply_to' column from catalog_eav_attribute has strange behaviour #6469 Magento 2.0.2 (different behaviour with same result)
@magento-engcom-team magento-engcom-team added bug report Component: Catalog Issue: Format is valid Gate 1 Passed. Automatic verification of issue format passed Issue: Clear Description Gate 2 Passed. Manual verification of the issue description passed labels Sep 11, 2017
@magento-engcom-team
Copy link
Contributor

@rendyep, thank you for your report.
We've created internal ticket(s) MAGETWO-77937 to track progress on the issue.

@magento-engcom-team magento-engcom-team added 2.2.x Issue: Ready for Work Gate 4. Acknowledged. Issue is added to backlog and ready for development Issue: Confirmed Gate 3 Passed. Manual verification of the issue completed. Issue is confirmed Reproduced on 2.1.x The issue has been reproduced on latest 2.1 release Reproduced on 2.2.x The issue has been reproduced on latest 2.2 release Reproduced on 2.3.x The issue has been reproduced on latest 2.3 release labels Oct 11, 2017
okorshenko pushed a commit that referenced this issue Nov 8, 2017
…aving attributes #11588

 - Merge Pull Request #11588 from MartinPeverelli/magento2:ISSUE#7225
 - Merged commits:
   1. 001df49
okorshenko pushed a commit that referenced this issue Nov 8, 2017
@okorshenko
Copy link
Contributor

The issue has been fixed in 2.2-develop branch. Will be available with 2.2.2 release

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug report Component: Catalog Issue: Clear Description Gate 2 Passed. Manual verification of the issue description passed Issue: Confirmed Gate 3 Passed. Manual verification of the issue completed. Issue is confirmed Issue: Format is valid Gate 1 Passed. Automatic verification of issue format passed Issue: Ready for Work Gate 4. Acknowledged. Issue is added to backlog and ready for development Reproduced on 2.1.x The issue has been reproduced on latest 2.1 release Reproduced on 2.2.x The issue has been reproduced on latest 2.2 release Reproduced on 2.3.x The issue has been reproduced on latest 2.3 release
Projects
None yet
Development

No branches or pull requests

5 participants