[FIX] hr_timesheet_invoice: Call super on on_change_account_id of hr.analytic.timesheet
`hr_timesheet_invoice.py` overrides `on_change_account_id` of model `hr.analytic.timesheet`. The super call wasn't done, probably because this on_change method in the base model was trivial: `return {'value':{}}` Nevertheless, if another module overrides this on_change, according to the module dependences, this method could have been called first in the calling chain, discarding the changes from the other overriden `on_change_account_id` methods, preventing any customization in this on_change according to the current database state. Closes #8248
This commit is contained in:
parent
f4e6dba097
commit
12c1993e03
|
@ -320,7 +320,8 @@ class account_analytic_line(osv.osv):
|
|||
class hr_analytic_timesheet(osv.osv):
|
||||
_inherit = "hr.analytic.timesheet"
|
||||
def on_change_account_id(self, cr, uid, ids, account_id, user_id=False):
|
||||
res = {}
|
||||
res = super(hr_analytic_timesheet, self).on_change_account_id(
|
||||
cr, uid, ids, account_id, user_id=user_id)
|
||||
if not account_id:
|
||||
return res
|
||||
res.setdefault('value',{})
|
||||
|
|
Loading…
Reference in New Issue