[6.1] account_voucher : onchange_partner_id method call to fix in few modules
Bug #847630 reported by
Yannick Vaucher @ Camptocamp
This bug affects 2 people
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Odoo Addons (MOVED TO GITHUB) |
Invalid
|
Undecided
|
OpenERP Publisher's Warranty Team |
Bug Description
Hello,
In 6.1, the signature of the voucher method onchange_partner_id changed.
"currency_id" has been replaced by "voucher_
Then following modules must be updated:
l10n_ch
account_payment
account_coda_import
A patch proposal to change calls in those modules is attached.
An other option could be to recover the preview signature for compatibility reasons.
And to keep clarity in the code, doing a simple copy of in parameter currency_id into the voucher_currency_id variable.
Regards,
Yannick
Changed in openobject-addons: | |
status: | Fix Committed → New |
Changed in openobject-addons: | |
assignee: | nobody → OpenERP Publisher's Warranty Team (openerp-opw) |
tags: | added: maintenance |
To post a comment you must log in.
Still, calls and signature doesn't match. However, don't use my preview patch, it is inverted.
bzr revno openobject-addons/
5383
bzr revno openobject-server/
3768
[2011-10-18 07:04:30, 964][test_ voucher] DEBUG:tests. l10n_ch: Exception during evaluation of !python block in yaml_file .../openobject- addons/ l10n_ch/ test/l10n_ ch_dta. yml. -server/ openerp/ tools/yaml_ import. py", line 426, in process_python eval(code_ obj, {'ref': self.get_id}, code_context) -addons/ l10n_ch/ test/l10n_ ch_dta. yml", line 13, in <module> -addons/ account_ payment/ wizard/ account_ payment_ populate_ statement. py", line 79, in populate_statement obj.onchange_ partner_ id(cr, uid, [], partner_ id=line. partner_ id.id, journal_ id=statement. journal_ id.id, price=abs(amount), voucher_ currency_ id= statement. currency. id, ttype='payment', date=line. ml_maturity_ date, context=context) partner_ id() got an unexpected keyword argument 'voucher_ currency_ id' 965][test_ voucher] ERROR:tests. l10n_ch: onchange_ partner_ id() got an unexpected keyword argument 'voucher_ currency_ id' -server/ openerp/ tools/yaml_ import. py", line 740, in process _process_ node(node) -server/ openerp/ tools/yaml_ import. py", line 755, in _process_node process_ python( node) -server/ openerp/ tools/yaml_ import. py", line 426, in process_python eval(code_ obj, {'ref': self.get_id}, code_context) -addons/ l10n_ch/ test/l10n_ ch_dta. yml", line 13, in <module> -addons/ account_ payment/ wizard/ account_ payment_ populate_ statement. py", line 79, in populate_statement obj.onchange_ partner_ id(cr, uid, [], partner_ id=line. partner_ id.id, journal_ id=statement. journal_ id.id, price=abs(amount), voucher_ currency_ id= statement. currency. id, ttype='payment', date=line. ml_maturity_ date, context=context) partner_ id() got an unexpected keyword argument 'voucher_ currency_ id' 965][test_ voucher] ERROR:init. test:Tests failed to execute in module l10n_ch -server/ openerp/ modules/ loading. py", line 100, in load_test -server/ openerp/ modules/ loading. py", line 135, in _load_data convert_ yaml_import( cr, module_name, fp, idref, mode, noupdate) -server/ openerp/ tools/yaml_ import. py", line 805, in yaml_import interpreter. process( yaml_string) -server/ openerp/ tools/yaml_ import. py", line 740, in process _process_ node(node) -server/ openerp/ tools/yaml_ import. py", line 755, in _process_node process_ python( node) -server/ openerp/ tools/yaml_ import. py", line 426, in process_python eval(code_ obj, {'ref': self.get_id}, code_context) -addons/ l10n_ch/ t...
Traceback (most recent call last):
File ".../openobject
unsafe_
File ".../openobject
account_id: account.a_pay
File ".../openobject
result = voucher_
TypeError: onchange_
[2011-10-18 07:04:30,
Traceback (most recent call last):
File ".../openobject
self.
File ".../openobject
self.
File ".../openobject
unsafe_
File ".../openobject
account_id: account.a_pay
File ".../openobject
result = voucher_
TypeError: onchange_
[2011-10-18 07:04:30,
Traceback (most recent call last):
File ".../openobject
_load_data(cr, module_name, idref, mode, 'test')
File ".../openobject
tools.
File ".../openobject
yaml_
File ".../openobject
self.
File ".../openobject
self.
File ".../openobject
unsafe_
File ".../openobject