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

[FIX] product_configurator_mrp_component: configurable component selection and variant creation #63

Merged

Conversation

patrickrwilson
Copy link
Contributor

  1. Fixes issue where if config component only has a few values in an attribute and the parent has and the selected value is not in the configurable component, an error would be raised. The fix is don't create and add the component if this is the case. This was causing an error because it was trying to create the variant even if the value selected didn't apply to the config component. This will allow more flexibility with config components.

  2. Fixes issue where the available configuration components that show in the drop down wasn't showing all the compatible product templates. It would show if the first attribute only had a few of the values but any attribute below that would have to have all the values in order for it to show.

1. Fixes issue where if config component only has a few values in an attribute and the parent selects the values that the comp doesn't have, then don't create and add the component. This was causing an error because it was trying to create the variant even if the value selected didn't apply to the config component. This will allow more flexibility with config components.
2. Fixes issue where the available config components that show in the drop down will allow if the first attribute only had a few of the values but any attribute below that would have to have all the values in order for it to show.
@dreispt dreispt changed the title [FIX] configurable component selection and variant creation [FIX] product_configurator_mrp_component: configurable component selection and variant creation Mar 22, 2022
@dreispt dreispt self-requested a review March 22, 2022 09:01
Copy link
Member

@dreispt dreispt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

With so much logic, it is worth investing in adding some tests here...

@dreispt
Copy link
Member

dreispt commented Mar 23, 2022

/ocabot merge patch

@OCA-git-bot
Copy link
Contributor

On my way to merge this fine PR!
Prepared branch 14.0-ocabot-merge-pr-63-by-dreispt-bump-patch, awaiting test results.

@OCA-git-bot OCA-git-bot merged commit 6270d12 into OCA:14.0 Mar 23, 2022
@OCA-git-bot
Copy link
Contributor

Congratulations, your PR was merged at aaac433. Thanks a lot for contributing to OCA. ❤️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants