[open-ils-commits] r8406 -
branches/acq-experiment/Open-ILS/web/oilsweb/oilsweb/config
svn at svn.open-ils.org
svn at svn.open-ils.org
Thu Jan 17 15:12:12 EST 2008
Author: erickson
Date: 2008-01-17 14:46:30 -0500 (Thu, 17 Jan 2008)
New Revision: 8406
Modified:
branches/acq-experiment/Open-ILS/web/oilsweb/oilsweb/config/routing.py
Log:
simplified the routes by providing a common prefix
Modified: branches/acq-experiment/Open-ILS/web/oilsweb/oilsweb/config/routing.py
===================================================================
--- branches/acq-experiment/Open-ILS/web/oilsweb/oilsweb/config/routing.py 2008-01-17 18:57:17 UTC (rev 8405)
+++ branches/acq-experiment/Open-ILS/web/oilsweb/oilsweb/config/routing.py 2008-01-17 19:46:30 UTC (rev 8406)
@@ -18,15 +18,16 @@
# CUSTOM ROUTES HERE
- if config.get('use_mod_python'):
- map.connect(':controller/:action')
- map.connect('admin/:action/:type/:id', controller='admin')
- map.connect('admin/:action/:type', controller='admin')
- else:
- map.connect('oils/:controller/:action')
- map.connect('oils/admin/:action/:type/:id', controller='admin')
- map.connect('oils/admin/:action/:type', controller='admin')
+ prefix = ''
+ if not config.get('use_mod_python'):
+ prefix = 'oils/'
+ map.connect(prefix+':controller/:action')
+ map.connect(prefix+':controller/:action/:id')
+ map.connect(prefix+'admin/:action/:type/:id', controller='admin')
+ map.connect(prefix+'admin/:action/:type', controller='admin')
+
+
''' trying a different set of admin routes above...
map.connect('acq_admin', 'oils/admin', controller='acq_admin')
map.connect('acq_admin_object', 'oils/admin/:object', controller='acq_admin')
More information about the open-ils-commits
mailing list