Merge lp:~vauxoo/openobject-addons/fix_change_diff_payable_voucher-dev-moylop260-vauxoo2 into lp:openobject-addons/6.1

Proposed by Moisés López - http://www.vauxoo.com
Status: Needs review
Proposed branch: lp:~vauxoo/openobject-addons/fix_change_diff_payable_voucher-dev-moylop260-vauxoo2
Merge into: lp:openobject-addons/6.1
Diff against target: 12 lines (+2/-0)
1 file modified
account_voucher/account_voucher.py (+2/-0)
To merge this branch: bzr merge lp:~vauxoo/openobject-addons/fix_change_diff_payable_voucher-dev-moylop260-vauxoo2
Reviewer Review Type Date Requested Status
OpenERP Core Team Pending
Review via email: mp+124575@code.launchpad.net
To post a comment you must log in.

Unmerged revisions

6928. By Moisés López - http://www.vauxoo.com

[FIX] [account_voucher] Fix Change Diff Payable

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'account_voucher/account_voucher.py'
2--- account_voucher/account_voucher.py 2012-08-28 10:58:11 +0000
3+++ account_voucher/account_voucher.py 2012-09-16 15:08:19 +0000
4@@ -923,6 +923,8 @@
5 The first element returned is the one that gonna be reconciled (with the receivalble or payable account)
6 :rtype: tuple of dict
7 '''
8+ if line.account_id.type in ('payable'):
9+ amount_residual = amount_residual*-1.0
10 if amount_residual > 0:
11 account_id = line.voucher_id.company_id.expense_currency_exchange_account_id
12 if not account_id: