diff options
| author | Goffin Simon <sig@odoo.com> | 2021-03-31 11:40:44 +0000 |
|---|---|---|
| committer | Goffin Simon <sig@odoo.com> | 2021-03-31 12:43:00 +0000 |
| commit | 49cf25fcc80ec2cb8ba3b3473c7c8d31533e2037 (patch) | |
| tree | 2aa6cdf526a3d9f803a53375ade278fa34468d8c | |
| parent | df53e57c009cb2d35cc48d1335b727f3f5fddc73 (diff) | |
[FIX] l10n_it_edi: Error when adding a note on invoice lines
Steps to reproduce the bug:
- Install l10n_it_edi
- Let's consider an italian company C with l10n_it xhart of accounts
- Create a customer invoice I in C and add a line with a price and a tax
- Add a note line
- Confirm I
Bug:
This UserError was raised: You must select one and only one tax by line.
opw:2484338
closes odoo/odoo#68594
Signed-off-by: Josse Colpaert <jco@openerp.com>
| -rw-r--r-- | addons/l10n_it_edi/models/account_invoice.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/addons/l10n_it_edi/models/account_invoice.py b/addons/l10n_it_edi/models/account_invoice.py index a88e5d1badd..2103f8eb7d6 100644 --- a/addons/l10n_it_edi/models/account_invoice.py +++ b/addons/l10n_it_edi/models/account_invoice.py @@ -111,7 +111,7 @@ class AccountMove(models.Model): # <2.2.1> for invoice_line in self.invoice_line_ids: - if len(invoice_line.tax_ids) != 1: + if not invoice_line.display_type and len(invoice_line.tax_ids) != 1: raise UserError(_("You must select one and only one tax by line.")) for tax_line in self.line_ids.filtered(lambda line: line.tax_line_id): |
