From ede3a8ca053338ef613805c458f6b0ff973562f7 Mon Sep 17 00:00:00 2001 From: Rushabh Mehta Date: Wed, 24 Aug 2016 18:45:29 +0530 Subject: [PATCH] [fix] get_visible_columns in jinja.py --- frappe/__init__.py | 4 +++- frappe/utils/jinja.py | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/frappe/__init__.py b/frappe/__init__.py index cf559f6925..1be7ce2b8b 100644 --- a/frappe/__init__.py +++ b/frappe/__init__.py @@ -173,7 +173,9 @@ def get_site_config(sites_path=None, site_path=None): if os.path.exists(site_config): config.update(get_file_json(site_config)) elif local.site and not local.flags.new_site: - raise IncorrectSitePath, "{0} does not exist".format(site_config) + print "{0} does not exist".format(local.site) + sys.exit(1) + #raise IncorrectSitePath, "{0} does not exist".format(site_config) return _dict(config) diff --git a/frappe/utils/jinja.py b/frappe/utils/jinja.py index ee892e3a73..f2557a569f 100644 --- a/frappe/utils/jinja.py +++ b/frappe/utils/jinja.py @@ -107,8 +107,8 @@ def get_allowed_functions_for_jenv(): } if not frappe.flags.in_setup_help: + out['get_visible_columns'] = frappe.get_attr("frappe.www.print.get_visible_columns") out['frappe']['date_format'] = frappe.db.get_default("date_format") or "yyyy-mm-dd" - out['frappe']['get_visible_columns'] = frappe.get_attr("frappe.www.print.get_visible_columns") out['frappe']["db"] = { "get_value": frappe.db.get_value, "get_default": frappe.db.get_default,