From 67bacb735ad212f03d877611d1d2f55cb27b442b Mon Sep 17 00:00:00 2001 From: Rushabh Mehta Date: Fri, 6 Sep 2013 12:42:54 +0530 Subject: [PATCH] [minor] moved developer mode to wn --- templates/pages/login.html | 2 +- webnotes/boot.py | 8 +++++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/templates/pages/login.html b/templates/pages/login.html index f0c6b20579..23d5fdea30 100644 --- a/templates/pages/login.html +++ b/templates/pages/login.html @@ -14,7 +14,7 @@ {% set title="Login" %} {% block body %} -
+
diff --git a/webnotes/boot.py b/webnotes/boot.py index 80c3dfc823..ae8ee2a7ed 100644 --- a/webnotes/boot.py +++ b/webnotes/boot.py @@ -47,6 +47,7 @@ def get_bootinfo(): add_home_page(bootinfo, doclist) add_allowed_pages(bootinfo) load_translations(bootinfo) + load_conf_settings(bootinfo) # ipinfo if webnotes.session['data'].get('ipinfo'): @@ -66,7 +67,12 @@ def get_bootinfo(): bootinfo['docs'] = compress(bootinfo['docs']) return bootinfo - + +def load_conf_settings(bootinfo): + import conf + for key in ['developer_mode']: + if hasattr(conf, key): bootinfo[key] = getattr(conf, key) + def add_allowed_pages(bootinfo): bootinfo.page_info = dict(webnotes.conn.sql("""select distinct parent, modified from `tabPage Role` where role in ('%s')""" % "', '".join(webnotes.get_roles())))