Browse Source

moved static view config to views package

php2python
Holger Frey 7 years ago
parent
commit
df13a65727
  1. 1
      ordr2/resources/__init__.py
  2. 4
      ordr2/views/__init__.py

1
ordr2/resources/__init__.py

@ -33,4 +33,3 @@ def includeme(config):
''' '''
config.set_root_factory(Root) config.set_root_factory(Root)
config.add_static_view('static', 'ordr2:static', cache_max_age=3600)

4
ordr2/views/__init__.py

@ -11,6 +11,8 @@ def flash(request, channel, message, description='', dismissable=True):
def includeme(config): def includeme(config):
''' adding a request helper for views ''' ''' adding request helpers and static views '''
config.add_request_method(flash, 'flash') config.add_request_method(flash, 'flash')
config.add_static_view('static', 'ordr2:static', cache_max_age=3600)