[FIX] account: account_analytic_plan break the creation of inovice from analytic lines

lp bug: https://launchpad.net/bugs/701895 fixed

bzr revid: psi@tinyerp.co.in-20110117051525-3lwmprov1zamc2vp
This commit is contained in:
psi (Open ERP) 2011-01-17 10:45:25 +05:30
parent 424f217e3f
commit 6cc21d77fa
1 changed files with 2 additions and 1 deletions

View File

@ -901,7 +901,8 @@ class account_move_line(osv.osv):
if context.get('account_id', False):
cr.execute('SELECT code FROM account_account WHERE id = %s', (context['account_id'], ))
res = cr.fetchone()
res = _('Entries: ')+ (res[0] or '')
if res:
res = _('Entries: ')+ (res[0] or '')
return res
if (not context.get('journal_id', False)) or (not context.get('period_id', False)):
return False