diff --git a/addons/account/wizard/wizard_general_ledger_report.py b/addons/account/wizard/wizard_general_ledger_report.py index 5dab0f59744..0aa23c79ccb 100644 --- a/addons/account/wizard/wizard_general_ledger_report.py +++ b/addons/account/wizard/wizard_general_ledger_report.py @@ -145,7 +145,7 @@ def _check_date(self, cr, uid, data, context): raise wizard.except_wizard('UserError','Date not in a defined fiscal year') def _check_state(self, cr, uid, data, context): - print"data",data + my_ids=data['ids'] if data['model']!='account.account': my_ids=[data['form']['Account_list']] @@ -155,7 +155,7 @@ def _check_state(self, cr, uid, data, context): for child in child_ids : child_account = pooler.get_pool(cr.dbname).get('account.account').browse(cr, uid, child) res = pooler.get_pool(cr.dbname).get('account.move.line').search(cr, uid,[('account_id','=',child_account.id)]) - print"res",res + if not len(res): raise wizard.except_wizard('UserError',"Make sure the account you select has children accounts.")