From 60b49869c697bd2fdd6912edb83474ae8153266a Mon Sep 17 00:00:00 2001 From: Josse Colpaert Date: Mon, 19 Sep 2022 14:35:42 +0000 Subject: [PATCH] [FIX] l10n_it_edi: auto-fattura coming from foreign vendors should be imported as vendor bill Of course, for an XML that is imported or exported the type of the invoice will be different: vendor bill for import, customer invoice for export e.g. But in the case of vendor bill reverse charge we create the XML from the vendor bill, but we did not think straight about how it should be imported. We did not expect it to be imported, but somehow in a database it was the case and we see it is actually corresponding to a vendor bill coming from a foreign vendor, so it would be better as well to import it as such. Also those types are only needed as vendor bills/refunds in our system. (only support bill for the moment) opw-2977126 closes odoo/odoo#102693 X-original-commit: 75a936eaf0202b468534add610afba8976a91b59 Signed-off-by: Quentin De Paoli Signed-off-by: Josse Colpaert --- addons/l10n_it_edi/models/account_edi_format.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/addons/l10n_it_edi/models/account_edi_format.py b/addons/l10n_it_edi/models/account_edi_format.py index acb1f8321fb..090e848edd5 100644 --- a/addons/l10n_it_edi/models/account_edi_format.py +++ b/addons/l10n_it_edi/models/account_edi_format.py @@ -235,9 +235,9 @@ class AccountEdiFormat(models.Model): 'TD07': dict(move_types=['out_invoice'], import_type='in_invoice', simplified=True), 'TD08': dict(move_types=['out_refund'], import_type='in_refund', simplified=True), 'TD09': dict(move_types=['out_invoice'], import_type='in_invoice', simplified=True), - 'TD17': dict(move_types=['in_invoice', 'in_refund'], import_type='out_invoice', self_invoice=True, services_or_goods="service"), - 'TD18': dict(move_types=['in_invoice', 'in_refund'], import_type='out_invoice', self_invoice=True, services_or_goods="consu", partner_in_eu=True), - 'TD19': dict(move_types=['in_invoice', 'in_refund'], import_type='out_invoice', self_invoice=True, services_or_goods="consu", goods_in_italy=True), + 'TD17': dict(move_types=['in_invoice', 'in_refund'], import_type='in_invoice', self_invoice=True, services_or_goods="service"), + 'TD18': dict(move_types=['in_invoice', 'in_refund'], import_type='in_invoice', self_invoice=True, services_or_goods="consu", partner_in_eu=True), + 'TD19': dict(move_types=['in_invoice', 'in_refund'], import_type='in_invoice', self_invoice=True, services_or_goods="consu", goods_in_italy=True), } def _l10n_it_get_document_type(self, invoice):