diff --git a/addons/account/account.py b/addons/account/account.py index 46e7b3457ec..c3ead387fba 100644 --- a/addons/account/account.py +++ b/addons/account/account.py @@ -1563,11 +1563,15 @@ class account_move_reconcile(osv.osv): _defaults = { 'name': lambda self,cr,uid,ctx={}: self.pool.get('ir.sequence').get(cr, uid, 'account.reconcile') or '/', } + def reconcile_partial_check(self, cr, uid, ids, type='auto', context=None): total = 0.0 for rec in self.browse(cr, uid, ids, context=context): for line in rec.line_partial_ids: - total += (line.debit or 0.0) - (line.credit or 0.0) + if line.account_id.currency_id: + total += line.amount_currency + else: + total += (line.debit or 0.0) - (line.credit or 0.0) if not total: self.pool.get('account.move.line').write(cr, uid, map(lambda x: x.id, rec.line_partial_ids), diff --git a/addons/account/account_invoice_view.xml b/addons/account/account_invoice_view.xml index 11ec7d8360a..a84eb5f5a32 100644 --- a/addons/account/account_invoice_view.xml +++ b/addons/account/account_invoice_view.xml @@ -305,8 +305,8 @@