[Fix] account: set the name of argument
bzr revid: sbh@tinyerp.com-20100714120532-t52k2jl6lais3a8c
This commit is contained in:
parent
9b42281a28
commit
7830609114
|
@ -115,12 +115,12 @@ class account_journal_common_default(object):
|
|||
|
||||
return self.cr.fetchone()[0] or 0.0
|
||||
|
||||
def _get_fiscalyear(self, form):
|
||||
def _get_fiscalyear(self, data):
|
||||
if data.get('form', False) and data['form'].get('fiscalyear_id', False):
|
||||
return pooler.get_pool(self.cr.dbname).get('account.fiscalyear').browse(self.cr, self.uid, data['form']['fiscalyear_id']).name
|
||||
return ''
|
||||
|
||||
def _get_company(self, form):
|
||||
def _get_company(self, data):
|
||||
if data.get('form', False) and data['form'].get('company_id', False):
|
||||
comp_obj = pooler.get_pool(self.cr.dbname).get('res.company').browse(self.cr, self.uid, data['form']['company_id'])
|
||||
return comp_obj.name
|
||||
|
|
Loading…
Reference in New Issue