Merge lp:~openerp-dev/openobject-addons/trunk-opw-576210-port-mma into lp:openobject-addons
Proposed by
Mayur Maheshwari(OpenERP)
Status: | Merged |
---|---|
Merged at revision: | 8001 |
Proposed branch: | lp:~openerp-dev/openobject-addons/trunk-opw-576210-port-mma |
Merge into: | lp:openobject-addons |
Diff against target: |
14 lines (+2/-1) 1 file modified
account/wizard/account_fiscalyear_close.py (+2/-1) |
To merge this branch: | bzr merge lp:~openerp-dev/openobject-addons/trunk-opw-576210-port-mma |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Fabien (Open ERP) | Disapprove | ||
Review via email: mp+132490@code.launchpad.net |
Description of the change
Hello,
If you pay foreign currency invoices with foreign currency, it will generate debit and credit entry with amount 0.0. Due to this, Generate Opening Entries" wizard generates credit and debit entries with amount 0.0 at the time of balance transfer before closing the year.
This fixes the issue.
Code is forward port from 6.1
Thanks,
Mayur
To post a comment you must log in.
The fix was not clean, I had to do this:
=== modified file 'account/ wizard/ account_ fiscalyear_ close.py' wizard/ account_ fiscalyear_ close.py 2012-08-07 11:34:14 +0000 wizard/ account_ fiscalyear_ close.py 2012-11-12 08:48:12 +0000 account. browse( cr, uid, account_ids, context= {'fiscalyear' : fy_id}):
balance_ in_currency = 0.0 currency_ id: currency) as balance_in_currency FROM account_move_line ' \ amount_ currency, 0.0)) as balance_in_currency FROM account_move_line ' \
'WHERE account_id = %s ' \
'AND ' + query_line + ' ' \
'AND currency_id = %s', (account.id, account. currency_ id.id))
--- account/
+++ account/
@@ -226,7 +226,7 @@
for account in obj_acc_
if account.
- cr.execute('SELECT sum(amount_
+ cr.execute('SELECT sum(COALESCE(
I merged the clean fix.