From 1233c4a800f36275606001572cd503f30dc9b519 Mon Sep 17 00:00:00 2001 From: Rushabh Mehta Date: Fri, 11 Jan 2013 11:00:20 +0530 Subject: [PATCH] financial statements: show only companies where permission is given --- accounts/doctype/mis_control/mis_control.py | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/accounts/doctype/mis_control/mis_control.py b/accounts/doctype/mis_control/mis_control.py index a860c821c7..953fed00fc 100644 --- a/accounts/doctype/mis_control/mis_control.py +++ b/accounts/doctype/mis_control/mis_control.py @@ -53,11 +53,8 @@ class DocType: ret['period'] = ['Annual','Half Yearly','Quarterly','Monthly'] # ---- get companies --------- - res = sql("select name from `tabCompany`") - for r in res: - comp.append(r[0]) - #comp.append(r[0] for r in res) - ret['company'] = comp + from accounts.page.accounts_browser.accounts_browser import get_companies + ret['company'] = get_companies() #--- to get fiscal year and start_date of that fiscal year ----- res = sql("select name, year_start_date from `tabFiscal Year`")