account_voucher : onchange_journal() takes at least 12 arguments (10 given).

Bug #911159 reported by DJ Patel (OpenERP)
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Odoo Addons (MOVED TO GITHUB)
Fix Released
Medium
OpenERP R&D Addons Team 3

Bug Description

Install account_voucher

Go to Accounting -> Journal Entries -> Journal Voucher.

Select the journal other than "Miscellaneous Journal (EUR)" and then select the "Partner".

It will gives the traceback :

Traceback (most recent call last):
  File "/home/mdi/openerp/openerp_trunk/openobject-server/openerp/osv/osv.py", line 120, in wrapper
    return f(self, dbname, *args, **kwargs)
  File "/home/mdi/openerp/openerp_trunk/openobject-server/openerp/osv/osv.py", line 172, in execute
    res = self.execute_cr(cr, uid, obj, method, *args, **kw)
  File "/home/mdi/openerp/openerp_trunk/openobject-server/openerp/osv/osv.py", line 163, in execute_cr
    return getattr(object, method)(cr, uid, *args, **kw)
  File "/home/mdi/openerp/openerp_trunk/openobject-addons/account_voucher/account_voucher.py", line 451, in onchange_journal_voucher
    vals = self.onchange_journal(cr, uid, ids, journal_id, line_ids, tax_id, partner_id, company_id, context)
TypeError: onchange_journal() takes at least 12 arguments (10 given)

Related branches

Amit Parik (amit-parik)
Changed in openobject-addons:
assignee: nobody → OpenERP R&D Addons Team 3 (openerp-dev-addons3)
importance: Undecided → Medium
status: New → Confirmed
Changed in openobject-addons:
status: Confirmed → In Progress
Revision history for this message
DJ Patel (OpenERP) (mdi-openerp) wrote :

The solution for this bug is proposed in the branch : https://code.launchpad.net/~openerp-dev/openobject-addons/trunk-bug-911159-mdi/

with following Revision ID and Number.

Revision ID : <email address hidden>
Revision Number : 6240

Thanks and Regards,

Divyesh Makwana(MDI)

Changed in openobject-addons:
status: In Progress → Fix Committed
Revision history for this message
sandeep (c-sandeep) wrote : Re: [Openerp-india] [Bug 911159] Re: account_voucher : onchange_journal() takes at least 12 arguments (10 given).

you have to check your Parameter are in your on change method

where you define 12 parameter and when you are calling that method from
on change your giving it only 7 argument while 3 are cr,uid and ids

so check it clear

Revision history for this message
Thibault Delavallée (OpenERP) (tde-openerp) wrote :

Hello,

Thanks for your fix. It landed in trunk.
revno: 6255
revision-id: <email address hidden>

Changed in openobject-addons:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.