From 5c037970923a164c3396bba4abf6688d0a9e65d3 Mon Sep 17 00:00:00 2001 From: Ahmed Aly Date: Tue, 8 May 2018 15:42:10 +0200 Subject: [PATCH] =?UTF-8?q?Fall=205430:=20=C3=84nderungsw=C3=BCnsche=20-?= =?UTF-8?q?=20Andruck=20Zolltarifnummer?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ext/custom-addons/dp_custom/models/account.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/ext/custom-addons/dp_custom/models/account.py b/ext/custom-addons/dp_custom/models/account.py index f0b92f00..28ea0f62 100644 --- a/ext/custom-addons/dp_custom/models/account.py +++ b/ext/custom-addons/dp_custom/models/account.py @@ -131,11 +131,16 @@ class AccountInvoice(models.Model): self.ensure_one() info = "Bei folgenden Produkten fehlt die Zolltarifnummer:\n" intrastrat_not_set = False + position = 1 for invoice_line in self.invoice_line_ids: if invoice_line.product_id and invoice_line.product_id.type != 'service': if not invoice_line.intrastat_id and not invoice_line.hide_intrastat_code: - info += invoice_line.name + "\n" + info += "Zeile: "+str(position) + if invoice_line.product_id.default_code: + info += "\tProduktcode: " + invoice_line.product_id.default_code + info += "\n" intrastrat_not_set = True + position += 1 if intrastrat_not_set: action = self.env.ref('dp_custom.action_wizard_confirm_print_invoice').read()[0] action['context'] = str({"default_info": info, "invoice_ids": self.env.context.get("active_ids")})