[FIX]: select only posted (valid) entries
bzr revid: mga@tinyerp.co.in-20101030185438-eq2it7zoiv2t6hah
This commit is contained in:
parent
aee10ece66
commit
c8bf3b0e55
|
@ -404,7 +404,7 @@ class account_voucher(osv.osv):
|
|||
account_type = 'receivable'
|
||||
|
||||
if not context.get('move_line_ids', False):
|
||||
ids = move_line_pool.search(cr, uid, [('account_id.type', '=', account_type), ('reconcile_id', '=', False), ('partner_id', '=', partner_id)], context=context)
|
||||
ids = move_line_pool.search(cr, uid, [('state','=','valid'), ('account_id.type', '=', account_type), ('reconcile_id', '=', False), ('partner_id', '=', partner_id)], context=context)
|
||||
else:
|
||||
ids = context['move_line_ids']
|
||||
ids.reverse()
|
||||
|
@ -926,4 +926,4 @@ class account_bank_statement_line(osv.osv):
|
|||
|
||||
account_bank_statement_line()
|
||||
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
|
|
Loading…
Reference in New Issue