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] 10.0 sale_triple_discount #979

Merged
merged 1 commit into from Mar 10, 2020

Conversation

gurneyalex
Copy link
Member

there are cases where the cache trick done in triple_discount_preprocess
is lost when sale.order.line _compute_amount is called and processes the
1st line of the sale order => all remaining lines are impacted, and don't
have the discounts 2 and 3 taken into account.

Not updating the sale.order _amount_all method because it is unlikely that
fields on the lines depend on the total amount of the sale.

there are cases where the cache trick done in triple_discount_preprocess
is lost when sale.order.line _compute_amount is called and processes the
1st line of the sale order => all remaining lines are impacted, and don't
have the discounts 2 and 3 taken into account.

Not updating the sale.order _amount_all method because it is unlikely that
fields on the lines depend on the total amount of the sale.
Copy link
Contributor

@grindtildeath grindtildeath left a comment

Choose a reason for hiding this comment

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

Seems legit 👍

Copy link
Contributor

@AaronHForgeFlow AaronHForgeFlow left a comment

Choose a reason for hiding this comment

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

👍 LGTM

@OCA-git-bot
Copy link
Contributor

This PR has the approved label and has been created more than 5 days ago. It should therefore be ready to merge by a maintainer (or a PSC member if the concerned addon has no declared maintainer). 🤖

@rousseldenis
Copy link
Sponsor Contributor

@lmignon This would be interesting for you

Copy link
Sponsor Contributor

@lmignon lmignon left a comment

Choose a reason for hiding this comment

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

Makes sens. Fix after fix, these triple discount addons seems to be a nightmare. Shouldn't the overall design of these addons be redesigned? (But that may be impossible)

@dreispt
Copy link
Sponsor Member

dreispt commented Mar 10, 2020

/ocabot merge patch

@OCA-git-bot
Copy link
Contributor

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

@OCA-git-bot OCA-git-bot merged commit 38e3ab6 into OCA:10.0 Mar 10, 2020
@OCA-git-bot
Copy link
Contributor

Congratulations, your PR was merged at c8463e7. 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.

None yet

8 participants