Statistics
| Branch: | Tag: | Revision:

root / urls.py.dist @ d0777394

History | View | Annotate | Download (1.8 kB)

1 caa2fd80 Leonidas Poulopoulos
from django.conf.urls.defaults import *
2 caa2fd80 Leonidas Poulopoulos
from django.conf import settings
3 caa2fd80 Leonidas Poulopoulos
# Uncomment the next two lines to enable the admin:
4 caa2fd80 Leonidas Poulopoulos
from django.contrib import admin
5 caa2fd80 Leonidas Poulopoulos
admin.autodiscover()
6 caa2fd80 Leonidas Poulopoulos
7 caa2fd80 Leonidas Poulopoulos
urlpatterns = patterns('',
8 caa2fd80 Leonidas Poulopoulos
    # Example:
9 caa2fd80 Leonidas Poulopoulos
    # (r'^fod/flowspy/', include('flowspy.foo.urls')),
10 caa2fd80 Leonidas Poulopoulos
    (r'^fod/poll/', include('flowspy.poller.urls')),
11 caa2fd80 Leonidas Poulopoulos
#    url(r'^fod/?$', 'flowspy.flowspec.views.user_routes', name="user-routes"),
12 caa2fd80 Leonidas Poulopoulos
    url(r'^fod/?$', 'flowspy.flowspec.views.group_routes', name="group-routes"),
13 caa2fd80 Leonidas Poulopoulos
    url(r'^fod/profile/?$', 'flowspy.flowspec.views.user_profile', name="user-profile"),
14 caa2fd80 Leonidas Poulopoulos
    url(r'^fod/add/?$', 'flowspy.flowspec.views.add_route', name="add-route"),
15 caa2fd80 Leonidas Poulopoulos
    #url(r'^fod/addrl/?$', 'flowspy.flowspec.views.add_rate_limit', name="add-rate-limit"),
16 caa2fd80 Leonidas Poulopoulos
    url(r'^fod/addport/?$', 'flowspy.flowspec.views.add_port', name="add-port"),
17 caa2fd80 Leonidas Poulopoulos
    url(r'^fod/edit/(?P<route_slug>[\w\-]+)/$', 'flowspy.flowspec.views.edit_route', name="edit-route"),
18 caa2fd80 Leonidas Poulopoulos
    url(r'^fod/delete/(?P<route_slug>[\w\-]+)/$', 'flowspy.flowspec.views.delete_route', name="delete-route"),
19 caa2fd80 Leonidas Poulopoulos
    url(r'^fod/login/?', 'flowspy.flowspec.views.user_login', name="login"),
20 caa2fd80 Leonidas Poulopoulos
    url(r'^fod/welcome/?', 'flowspy.flowspec.views.welcome', name="welcome"),
21 caa2fd80 Leonidas Poulopoulos
    url(r'^fod/logout/?', 'flowspy.flowspec.views.user_logout', name="logout"),
22 caa2fd80 Leonidas Poulopoulos
    (r'^fod/setlang/?$', 'django.views.i18n.set_language'),
23 caa2fd80 Leonidas Poulopoulos
    # Uncomment the admin/doc line below to enable admin documentation:
24 caa2fd80 Leonidas Poulopoulos
    (r'^fod/admin/doc/', include('django.contrib.admindocs.urls')),
25 caa2fd80 Leonidas Poulopoulos
    url(r'^fod/load_js/(?P<file>[\w\s\d_-]+)/$', 'flowspy.flowspec.views.load_jscript', name="load-js"), 
26 caa2fd80 Leonidas Poulopoulos
27 caa2fd80 Leonidas Poulopoulos
    # Uncomment the next line to enable the admin:
28 caa2fd80 Leonidas Poulopoulos
    (r'^fod/admin/', include(admin.site.urls)),
29 caa2fd80 Leonidas Poulopoulos
)
30 caa2fd80 Leonidas Poulopoulos
31 caa2fd80 Leonidas Poulopoulos
32 caa2fd80 Leonidas Poulopoulos
if settings.DEBUG:
33 caa2fd80 Leonidas Poulopoulos
    urlpatterns += patterns('',
34 caa2fd80 Leonidas Poulopoulos
        (r'^fod/static/(?P<path>.*)', 'django.views.static.serve',\
35 caa2fd80 Leonidas Poulopoulos
            {'document_root':  settings.STATIC_URL}),
36 caa2fd80 Leonidas Poulopoulos
    )