[FIX] account: report overdue: name of company duplicated

Have a partner which is only a company
Print "Due Payments" report

Before this commit, the name of the company was shown in double
this was because both `name` and `contact_address` are shown in that report
but in the case of a company, or child of a company, the company's name
is included in contact_address

After this commit, the name appears only once

OPW 1970581

closes odoo/odoo#32838

Signed-off-by: Lucas Perais (lpe) <lpe@odoo.com>
This commit is contained in:
Lucas Perais (lpe)
2019-04-19 12:48:07 +00:00
parent 0106fcd59c
commit f9ce7d1fc8
+2 -1
View File
@@ -5,7 +5,8 @@
<div class="page">
<div class="row">
<div class="col-xs-5 col-xs-offset-7">
<span t-field="o.name"/><br/>
<!-- When partner is a company, its name is included in contact_address -->
<span t-if="not o.is_company"><span t-field="o.name"/><br/></span>
<span t-raw="o.contact_address.replace('\n\n', '\n').replace('\n', '&lt;br&gt;')"/>
<span t-field="o.vat"/>
</div>