From 97f9a3796cefa68e6bbc171005ada1d79a5d9973 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Fri, 15 Mar 2013 01:01:36 +0100 Subject: [PATCH] Return ids instead of instance in credit wizard issue2979 review709004 --- invoice.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/invoice.py b/invoice.py index 2d94b64af7..5d58d2e4bb 100644 --- a/invoice.py +++ b/invoice.py @@ -2661,9 +2661,9 @@ class CreditInvoice(Wizard): (invoice.rec_name,)) self.raise_user_error('refund_supplier') - invoice_ids = Invoice.credit(invoices, refund=refund) + credit_invoices = Invoice.credit(invoices, refund=refund) - data = {'res_id': invoice_ids} - if len(invoice_ids) == 1: + data = {'res_id': [i.id for i in credit_invoices]} + if len(credit_invoices) == 1: action['views'].reverse() return action, data