[FIX] account: Update invoice_partner_display_name

Steps to reproduce the bug:

- Open a customer invoice I
- Click on the partner P set on I
- Change the contact name of P
- Go to the list view of customer invoice

Bug:

The name of P was not updated.

opw:2354492

closes odoo/odoo#59507

X-original-commit: be5d72974ad89c985e413f0eb84352a00a6cd043
Signed-off-by: Simon Goffin (sig) <sig@openerp.com>
This commit is contained in:
Goffin Simon
2020-10-08 12:33:26 +00:00
parent cd9f6ef589
commit d2b0488fd9
+1 -1
View File
@@ -1326,7 +1326,7 @@ class AccountMove(models.Model):
res = True
r.invoice_has_matching_suspense_amount = res
@api.depends('partner_id', 'invoice_source_email')
@api.depends('partner_id', 'invoice_source_email', 'partner_id.name')
def _compute_invoice_partner_display_info(self):
for move in self:
vendor_display_name = move.partner_id.display_name