Return ids instead of instance in credit wizard

issue2979
review709004
This commit is contained in:
Cédric Krier committed 2013-03-15 01:01:36 +01:00
1 parent 598767d6d1
commit 97f9a3796c
1 file changed
+3 -3
+3 -3
View File
@@ -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