1 # -*- coding: utf-8 -*-
3 from django.conf.urls.defaults import *
4 from django.contrib import admin
5 from django.conf import settings
11 urlpatterns = patterns('',
13 url(r'^accounts/login/$', 'django_cas.views.login', name='login'),
14 url(r'^accounts/logout/$', 'django_cas.views.logout', name='logout'),
17 (r'^admin/filebrowser/', include('filebrowser.urls')),
18 url(r'^admin/doc/', include('django.contrib.admindocs.urls')),
19 (r'^admin/', include(admin.site.urls)),
21 url(r'^$', 'django.views.generic.simple.redirect_to', {'url': '/documents/'}),
22 url(r'^documents/', include('wiki.urls')),
24 # Static files (should be served by Apache)
25 url(r'^%s(?P<path>.+)$' % settings.MEDIA_URL[1:], 'django.views.static.serve',
26 {'document_root': settings.MEDIA_ROOT, 'show_indexes': True}),
27 url(r'^%s(?P<path>.+)$' % settings.ADMIN_MEDIA_PREFIX[1:], 'django.views.static.serve',
28 {'document_root': settings.MEDIA_ROOT, 'show_indexes': True}),
29 url(r'^%s(?P<path>.+)$' % settings.STATIC_URL[1:], 'django.views.static.serve',
30 {'document_root': settings.STATIC_ROOT, 'show_indexes': True}),
31 (r'^documents/', include(wiki.urls)),
32 url(r'^$', 'django.views.generic.simple.redirect_to', {'url': '/documents/'}),