From 98b7aff595c1c7889fa4e704cd1507ff9dc060da Mon Sep 17 00:00:00 2001 From: Mantavya Gajjar Date: Sat, 19 Mar 2011 14:07:45 +0530 Subject: [PATCH] [FIX]: post voucher entry based on the journal posting state 'entry_posted' bzr revid: mga@tinyerp.com-20110319083745-6ddijyo4rksfgt6t --- addons/account_voucher/account_voucher.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/addons/account_voucher/account_voucher.py b/addons/account_voucher/account_voucher.py index c80bb9b3c62..16e09a6a840 100644 --- a/addons/account_voucher/account_voucher.py +++ b/addons/account_voucher/account_voucher.py @@ -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)