From 9fbb0e95e41ec934343fb7bbc7bd4d3959e02000 Mon Sep 17 00:00:00 2001 From: Mustufa Rangwala Date: Thu, 30 Sep 2010 11:10:40 +0530 Subject: [PATCH] [REF] bzr revid: mra@mra-laptop-20100930054040-49hxtzj6v9pbtlfa --- addons/account_voucher/account_voucher.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/addons/account_voucher/account_voucher.py b/addons/account_voucher/account_voucher.py index d5d15a6e6fa..29fe1b0b92d 100644 --- a/addons/account_voucher/account_voucher.py +++ b/addons/account_voucher/account_voucher.py @@ -334,7 +334,7 @@ class account_voucher(osv.osv): return default - def onchange_partner_id(self, cr, uid, ids, partner_id, journal_id, price, currency_id, ttype, context={}): + def onchange_partner_id(self, cr, uid, ids, partner_id, journal_id, price, currency_id, ttype, context=None): """price Returns a dict that contains new values and context @@ -347,6 +347,9 @@ class account_voucher(osv.osv): if not journal_id: return {} + if context is None: + context = {} + currency_pool = self.pool.get('res.currency') move_pool = self.pool.get('account.move') line_pool = self.pool.get('account.voucher.line')