[Mpuls-commits] r1630 - in wasko/branches/2.0: . mpulsweb/config
scm-commit@wald.intevation.org
scm-commit at wald.intevation.org
Tue Feb 16 16:26:18 CET 2010
Author: bh
Date: 2010-02-16 16:26:16 +0100 (Tue, 16 Feb 2010)
New Revision: 1630
Modified:
wasko/branches/2.0/ChangeLog
wasko/branches/2.0/mpulsweb/config/environment.py
Log:
* mpulsweb/config/environment.py (load_environment): Import
app_globals using import_overridable_module so that it can be
overridden in an MPuls specialization
Modified: wasko/branches/2.0/ChangeLog
===================================================================
--- wasko/branches/2.0/ChangeLog 2010-02-16 15:20:30 UTC (rev 1629)
+++ wasko/branches/2.0/ChangeLog 2010-02-16 15:26:16 UTC (rev 1630)
@@ -1,5 +1,11 @@
2010-02-16 Bernhard Herzog <bh at intevation.de>
+ * mpulsweb/config/environment.py (load_environment): Import
+ app_globals using import_overridable_module so that it can be
+ overridden in an MPuls specialization
+
+2010-02-16 Bernhard Herzog <bh at intevation.de>
+
* mpulsweb/config/importer.py: New module with one function:
(import_overridable_module): Load a module either from the
specialization or mpulsweb.
Modified: wasko/branches/2.0/mpulsweb/config/environment.py
===================================================================
--- wasko/branches/2.0/mpulsweb/config/environment.py 2010-02-16 15:20:30 UTC (rev 1629)
+++ wasko/branches/2.0/mpulsweb/config/environment.py 2010-02-16 15:26:16 UTC (rev 1630)
@@ -30,10 +30,11 @@
from mako.lookup import TemplateLookup
from pylons import config
-import mpulsweb.lib.app_globals as app_globals
import mpulsweb.lib.helpers
from mpulsweb.config.routing import make_map
+from mpulsweb.config.importer import import_overridable_module
+
log = logging.getLogger(__name__)
def load_environment(global_conf, app_conf):
@@ -73,7 +74,7 @@
template_engine='mako', paths=paths)
config['routes.map'] = make_map()
- config['pylons.g'] = app_globals.Globals()
+ config['pylons.g'] = import_overridable_module("lib.app_globals").Globals()
config['pylons.h'] = mpulsweb.lib.helpers
# Create the Mako TemplateLookup, with the default auto-escaping
More information about the Mpuls-commits
mailing list