Skip to content
Snippets Groups Projects
Commit 0d273e68 authored by Maximilien (malb)'s avatar Maximilien (malb)
Browse files

[FIX] l10n_de: shipping address traceback

Before this PR, when there is no shipping address, the pdf show an empty
"Shipping Address" header. By changing the colspan dynamically we can manage to
keep the layout like it was and remove the useless section.

Task-id: 3262408
Part-of: odoo/odoo#134107
parent d8498091
Branches
Tags
No related merge requests found
......@@ -45,7 +45,7 @@ class AccountMove(models.Model):
record.l10n_din5008_addresses = data = []
if record.partner_shipping_id == record.partner_id:
data.append((_("Invoicing and Shipping Address:"), record.partner_shipping_id))
elif record.move_type in ("in_invoice", "in_refund"):
elif record.move_type in ("in_invoice", "in_refund") or not record.partner_shipping_id:
data.append((_("Invoicing and Shipping Address:"), record.partner_id))
else:
data.append((_("Shipping Address:"), record.partner_shipping_id))
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment