From d3f99f75a66429121d7cebbe2c0460c892fc5066 Mon Sep 17 00:00:00 2001 From: Christophe Simonis Date: Sun, 24 Nov 2013 19:10:37 +0100 Subject: [PATCH] [MERGE] backport trunk revision 8974 qdp-launchpad@openerp.com-20131113100713-tvl30z5oqym22jqj bzr revid: chs@openerp.com-20131124181037-1tks1yruahiv0jwi --- addons/account_payment/wizard/account_payment_order.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/account_payment/wizard/account_payment_order.py b/addons/account_payment/wizard/account_payment_order.py index de9c47ec005..8d5df048fe0 100644 --- a/addons/account_payment/wizard/account_payment_order.py +++ b/addons/account_payment/wizard/account_payment_order.py @@ -104,7 +104,7 @@ class payment_order_create(osv.osv_memory): # payment = self.pool.get('payment.order').browse(cr, uid, context['active_id'], context=context) # Search for move line to pay: - domain = [('reconcile_id', '=', False), ('account_id.type', '=', 'payable'), ('amount_residual', '>', 0)] + domain = [('reconcile_id', '=', False), ('account_id.type', '=', 'payable'), ('credit', '>', 0), ('account_id.reconcile', '=', True)] domain = domain + ['|', ('date_maturity', '<=', search_due_date), ('date_maturity', '=', False)] line_ids = line_obj.search(cr, uid, domain, context=context) context.update({'line_ids': line_ids})