From 68e2cdb338177bdd94f2de4c578d1d4c51eb22f3 Mon Sep 17 00:00:00 2001 From: aaron Date: Fri, 25 May 2018 16:35:26 +0200 Subject: [PATCH] [IMP]include origin when searching invoices --- rma_account/models/invoice.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/rma_account/models/invoice.py b/rma_account/models/invoice.py index ec0a109c..9cadb00b 100644 --- a/rma_account/models/invoice.py +++ b/rma_account/models/invoice.py @@ -78,12 +78,15 @@ class AccountInvoiceLine(models.Model): if self.env.context.get('rma'): for inv in self: if inv.invoice_id.reference: - res.append((inv.id, "%s %s %s qty:%s" % ( - inv.invoice_id.number, inv.invoice_id.reference, + res.append((inv.id, "%s %s %s %s qty:%s" % ( + inv.invoice_id.number or '', + inv.origin or '', + inv.invoice_id.reference or "", inv.product_id.name, inv.quantity))) elif inv.invoice_id.number: - res.append((inv.id, "%s %s qty:%s" % ( + res.append((inv.id, "%s %s %s qty:%s" % ( inv.invoice_id.number or '', + inv.origin or '', inv.product_id.name, inv.quantity))) else: res.append(super(AccountInvoiceLine, inv).name_get()[0])