[FIX]: post voucher entry based on the journal posting state 'entry_posted'

bzr revid: mga@tinyerp.com-20110319083745-6ddijyo4rksfgt6t
This commit is contained in:
Mantavya Gajjar 2011-03-19 14:07:45 +05:30
parent 7b645682ae
commit 98b7aff595
1 changed files with 2 additions and 1 deletions

View File

@ -777,7 +777,8 @@ class account_voucher(osv.osv):
'state': 'posted',
'number': name,
})
move_pool.post(cr, uid, [move_id], context={})
if inv.journal_id.entry_posted:
move_pool.post(cr, uid, [move_id], context={})
for rec_ids in rec_list_ids:
if len(rec_ids) >= 2:
move_line_pool.reconcile_partial(cr, uid, rec_ids)