Changeset 7484 for cowsserver


Ignore:
Timestamp:
21/09/10 11:31:41 (9 years ago)
Author:
astephen
Message:

Updated routes to pylons 1.0 requirement using new Routes syntax.
Also added the lines:

# We need minization switched on
map.minimization = True
map.explicit = False

To handle enable "implicit" routing, see:

 http://routes.groovie.org/manual.html#implicit-defaults-and-route-memory

File:
1 edited

Legend:

Unmodified
Added
Removed
  • cowsserver/branches/migrate-py26-pylons10/lib/cowsserver/config/routing.py

    r7340 r7484  
    1313                 always_scan=config['debug']) 
    1414 
     15    # We need minization switched on 
     16    map.minimization = True 
     17    map.explicit = False 
     18 
    1519    # The ErrorController route (handles 404/500 error pages); it should 
    1620    # likely stay at the top, ensuring it can always be resolved 
    17     map.connect('error/{action}/{id}', controller='error') 
     21    map.connect('/error/{action}', controller='error') 
     22    map.connect('/error/{action}/{id}', controller='error') 
    1823 
    1924    # CUSTOM ROUTES HERE 
    20     #map.connect('coastwms', controller='coastwms') 
    21  
    2225    map.connect('/{fileoruri}/wms', controller='csmlwms', action='index') 
    2326    map.connect('/{fileoruri}/wms2', controller='csmlwms_csml', action='index') 
    2427     
    25     map.connect('wcsroute', ':fileoruri/wcs', controller='csmlwcs') #wcsroute is a named route. 
    26      
     28 
     29## NOTE: Should the following two have action='index'? 
     30    # "wcsroute" is a named route 
     31    map.connect('wcsroute', '{fileoruri}/wcs', controller='csmlwcs') 
     32    
     33    # Not sure about this route  
    2734    map.connect('{fileoruri}/wfs', controller='csmlwfs') 
    28     #filestore - used for fetching files referenced by (csml) StorageDescriptors (WFS), and  'store' in wcs if implemented 
     35 
     36    # "filestore" - used for fetching files referenced by (csml)  
     37    # StorageDescriptors (WFS), and  'store' in wcs if implemented 
    2938    map.connect('filestore/{file}', controller='fetch', action='fetchFile') 
    3039    map.connect('{fileoruri}/demo', controller='demo') 
    3140    map.connect('/', controller='catalogue', action='index') 
    3241 
    33  
    34     #map.connect('{controller}/{action}/{id}') 
    35     #map.connect('*url', controller='template', action='view') 
    36  
    3742    return map 
Note: See TracChangeset for help on using the changeset viewer.