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

task 5180 #15

Open
wants to merge 9 commits into
base: 16.0-mar
Choose a base branch
from
Open

task 5180 #15

wants to merge 9 commits into from

Conversation

gabriele-baldessari
Copy link

No description provided.

grindtildeath and others added 9 commits February 18, 2025 12:38
Until now, the triple discount feature did use the standard Odoo field
as the first discount field, adding only extra fields for the second
and the third discount. This implied we had to override any function
using discount to consider the other discounts properly.

By adding an extra field discount1 to store the first discount, it allows
to redefine the standard discount field to a computed field that will
consolidate the triple discount from the other fields, and avoid the
need to redefine anything relying on the discount field as it will
already consider the triple discounts.
…orithm

[FIX] account_invoice_triple_discount: populate discount1 field to avoid inconsistency if database contains account.move.line with not null discount before the installation of the module

[REF] account_invoice_triple_discount: Add GRAP as coauthor of the module

[FIX] account_invoice_triple_discount: Manage Correct creation of account move lines, where 'discount' field is set
In case this module is installed and sale module is also installed
but not sale_triple_discount, or in case sale_triple_discount is not
updated to its latest version, make sure that setting discount, without
having discount1 defined, will not mess with the triple discounts.
- set modules as incompatible in the manifest. (For the time being, there is only a informative message in the README of the module account_invoice_fixed_discount)
- Run separated tests for both modules.
…eld 'discount' as the field is now a technical field that should not have limitation. For exemple in the default case where digits precision of Discount is 2, if discounts are 05%, 09% and 13% the main discount is 24.7885 % (and not 24.79)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants