bzr revid: mra@mra-laptop-20100913122227-6t7s8jcj56wcjw59
This commit is contained in:
Mustufa Rangwala 2010-09-13 17:52:27 +05:30
parent d23c2d51da
commit f7c4222fbf
1 changed files with 4 additions and 4 deletions

View File

@ -1537,9 +1537,9 @@ class account_tax_code(osv.osv):
if context is None:
context = {}
move_state = ('posted', )
if 'state' in context and context['state'] == 'all':
if context.get('state', False) == 'all':
move_state = ('draft', 'posted', )
if 'fiscalyear_id' in context and context['fiscalyear_id']:
if context.get('fiscalyear_id', False):
fiscalyear_id = context['fiscalyear_id']
else:
fiscalyear_id = self.pool.get('account.fiscalyear').find(cr, uid, exception=False)
@ -1557,9 +1557,9 @@ class account_tax_code(osv.osv):
if context is None:
context = {}
move_state = ('posted', )
if 'state' in context and context['state'] == 'all':
if context.get('state', False) == 'all':
move_state = ('draft', 'posted', )
if 'period_id' in context and context['period_id']:
if context.get('period_id', False):
period_id = context['period_id']
else:
period_id = self.pool.get('account.period').find(cr, uid)