Browse Source

[FIX] Return algo cuando la empresa sea vacia

6.0
Humberto Arocha 12 years ago
parent
commit
d072d9ef49
  1. 4
      account_financial_report/model/account_financial_report.py
  2. 4
      account_financial_report/wizard/wizard.py

4
account_financial_report/model/account_financial_report.py

@ -121,6 +121,10 @@ class account_financial_report(osv.osv):
context = {}
context['company_id']=company_id
res = {'value':{}}
if not company_id:
return res
cur_id = self.pool.get('res.company').browse(cr,uid,company_id,context=context).currency_id.id
fy_id = self.pool.get('account.fiscalyear').find(cr, uid,context=context)
res['value'].update({'fiscalyear_id':fy_id})

4
account_financial_report/wizard/wizard.py

@ -118,6 +118,10 @@ class wizard_report(osv.osv_memory):
context = {}
context['company_id']=company_id
res = {'value':{}}
if not company_id:
return res
cur_id = self.pool.get('res.company').browse(cr,uid,company_id,context=context).currency_id.id
fy_id = self.pool.get('account.fiscalyear').find(cr, uid,context=context)
res['value'].update({'fiscalyear':fy_id})

Loading…
Cancel
Save