diff pylons_app/config/environment.py @ 239:b18f89d6d17f

Adde draft for permissions systems, made all needed decorators, and checks. For future usage in the system.
author Marcin Kuzminski <marcin@python-works.com>
date Sun, 30 May 2010 19:49:40 +0200
parents 5e2470ebdbc6
children 3782a6d698af
line wrap: on
line diff
--- a/pylons_app/config/environment.py	Sun May 30 17:55:56 2010 +0200
+++ b/pylons_app/config/environment.py	Sun May 30 19:49:40 2010 +0200
@@ -1,16 +1,17 @@
 """Pylons environment configuration"""
-import logging
-import os
-
 from mako.lookup import TemplateLookup
 from pylons.configuration import PylonsConfig
 from pylons.error import handle_mako_error
+from pylons_app.config.routing import make_map
+from pylons_app.lib.auth import set_available_permissions
+from pylons_app.model import init_model
 from sqlalchemy import engine_from_config
-
+import logging
+import os
 import pylons_app.lib.app_globals as app_globals
 import pylons_app.lib.helpers
-from pylons_app.config.routing import make_map
-from pylons_app.model import init_model
+
+
 
 log = logging.getLogger(__name__)
 
@@ -62,6 +63,7 @@
 
     init_model(sa_engine_db1)
 
+    set_available_permissions(config)
     # CONFIGURATION OPTIONS HERE (note: all config options will override
     # any Pylons config options)