Nehal Panchal (OpenERP) has proposed merging
lp:~openerp-dev/openobject-addons/6.1-opw-576210-nep into
lp:openobject-addons/6.1.
Requested reviews:
Naresh(OpenERP) (nch-openerp)
For more details, see:
https://code.launchpad.net/~openerp-dev/openobject-addons/6.1-opw-576210-nep/+merge/114613
Hello,
Generate Opening Entries wizard should not generate credit and debit entries
with amount 0.0 at the time of balance transfer before closing the year.
This fixes the issue.
Thanks
--
https://code.launchpad.net/~openerp-dev/openobject-addons/6.1-opw-576210-nep/+merge/114613
Your team OpenERP R&D Team is subscribed to branch
lp:~openerp-dev/openobject-addons/6.1-opw-576210-nep.
=== modified file 'account/wizard/account_fiscalyear_close.py'
--- account/wizard/account_fiscalyear_close.py 2012-02-09 17:03:33 +0000
+++ account/wizard/account_fiscalyear_close.py 2012-07-12 11:32:20 +0000
@@ -226,8 +226,9 @@
for account in obj_acc_account.browse(cr, uid, account_ids, context={'fiscalyear': fy_id}):
balance_in_currency = 0.0
if account.currency_id:
- cr.execute('SELECT sum(amount_currency) as balance_in_currency FROM account_move_line ' \
+ cr.execute('SELECT COALESCE(sum(amount_currency),0.0) as balance_in_currency FROM account_move_line ' \
'WHERE account_id = %s ' \
+ 'AND (debit <> 0.0 and credit <> 0.0) ' \
'AND ' + query_line + ' ' \
'AND currency_id = %s', (account.id, account.currency_id.id))
balance_in_currency = cr.dictfetchone()['balance_in_currency']
_______________________________________________
Mailing list: https://launchpad.net/~openerp-dev-gtk
Post to : [email protected]
Unsubscribe : https://launchpad.net/~openerp-dev-gtk
More help : https://help.launchpad.net/ListHelp