-
-
Notifications
You must be signed in to change notification settings - Fork 693
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
[11.0][FIX] account_global_discount: link line taxes to discount move line #745
Conversation
048122d
to
89f6a5c
Compare
please review @carlosdauden |
89f6a5c
to
1da9249
Compare
1da9249
to
d2f508a
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@carlosdauden please check my latest changes |
d1f5859
to
fcd1690
Compare
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
fcd1690
to
a6d211d
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tested @pedrobaeza changes 👍
@carlosdauden Please re-review
This PR isn't ok, at the accounting entry of discount, I miss the detail of 349 model on intra-community invoices: Please, could you check it @chienandalu ? Thanks a lot! |
@SoniaViciana this is because you need a glue module between both. It's the problem of having this anti-nature way of giving discounts. We have been forced to do it in a customer, but we DON'T RECOMMEND these global discounts as it needs a lot of patching in successive things, like this 349 side effect. |
- We need to take into account invoice lines with multiple taxes, so the link should be m2m. - Migration scripts for preserving the best information on existing installations. - Tests for checking new conditions. - Perform sanity check for not ending in an incompatible situation. - Some refactor done on onchanges for avoiding duplicating operations. - Adjust UI for not allowing to edit computed invoice global discounts.
a6d211d
to
0ae672d
Compare
@SoniaViciana @chienandalu I think I have found method for not needing that glue modules in most cases. Can you please check with latest push about the 349? |
Well, not sure if we need to change 349 method: and doing this in invoice_line_move_line_get instead. And even in that case, it would depend on the call chain... I'm giving up now on this, as our customer only uses global discounts for national operations (and in very few cases). |
Yes, looks like a glue module is still needed for that case: https://github.com/OCA/l10n-spain/blob/245ff2527aabd2670c99325a056651fef5cfce3f/l10n_es_aeat_mod349/models/account_invoice.py#L35-L36 Anyway, let's move forward |
/ocabot merge patch |
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
Not all taxes combinations are possible with global discounts when they are later invoiced and posted, so we need to constraint them early. OCA/account-invoicing#745 addresses the problem at invoice level, posting correctly taxes for supported cases, and constraining the rest. We apply here the same constraints at sales order level. Existing tests have been changed because they were using one of the forbidden taxes combination, and 2 new tests have been added for covering the new constraints.
cc @Tecnativa TT24526