diff --git a/addons/account_voucher/voucher.py b/addons/account_voucher/voucher.py
index 3a9855e35f3..b898adf68bf 100644
--- a/addons/account_voucher/voucher.py
+++ b/addons/account_voucher/voucher.py
@@ -254,7 +254,7 @@ class account_voucher(osv.osv):
})
return {'value':default}
- def onchange_journal_voucher(self, cr, uid, ids, partner_id=False, journal_id=False, context={}):
+ def onchange_journal_voucher(self, cr, uid, ids, line_ids=False, tax_id=False, price=0.0, partner_id=False, journal_id=False, ttype=False, context={}):
"""price
Returns a dict that contains new values and context
@@ -290,9 +290,13 @@ class account_voucher(osv.osv):
default['value']['account_id'] = account_id
default['value']['type'] = tr_type
+
+ vals = self.onchange_journal(cr, uid, ids, journal_id, line_ids, tax_id, partner_id, context)
+ default['value'].update(vals.get('value'))
+
return default
- def onchange_partner_id(self, cr, uid, ids, partner_id, journal_id=False, price=0.0, currency_id=False, ttype=False, context={}):
+ def onchange_partner_id(self, cr, uid, ids, partner_id, journal_id, price, currency_id, ttype, context):
"""price
Returns a dict that contains new values and context
diff --git a/addons/account_voucher/voucher_sales_purchase_view.xml b/addons/account_voucher/voucher_sales_purchase_view.xml
index 9a55d5e4f83..f40e2088d63 100644
--- a/addons/account_voucher/voucher_sales_purchase_view.xml
+++ b/addons/account_voucher/voucher_sales_purchase_view.xml
@@ -40,7 +40,6 @@
-
account.voucher.sale.select
account.voucher
@@ -80,7 +79,6 @@
-
Sales Payment
account.voucher
@@ -216,7 +214,7 @@
-
+
diff --git a/addons/account_voucher/voucher_view.xml b/addons/account_voucher/voucher_view.xml
index 94f7f18c4a0..29008201992 100644
--- a/addons/account_voucher/voucher_view.xml
+++ b/addons/account_voucher/voucher_view.xml
@@ -28,8 +28,8 @@