-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathurls.py
More file actions
74 lines (63 loc) · 2.36 KB
/
urls.py
File metadata and controls
74 lines (63 loc) · 2.36 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
# -*- coding: utf-8 -*-
# Copyright 2008 - 2009, Niels Sandholt Busch <niels.busch@gmail.com>. All rights reserved.
from django.conf.urls.defaults import *
from django.conf import settings
from django.contrib.auth import views as auth_views
from django.views.generic.simple import direct_to_template
# Uncomment the next two lines to enable the admin:
from django.contrib import admin
admin.autodiscover()
urlpatterns = patterns('',
# Example:
# (r'^imagedb/', include('imagedb.foo.urls')),
# Uncomment the admin/doc line below and add 'django.contrib.admindocs'
# to INSTALLED_APPS to enable admin documentation:
# (r'^admin/doc/', include('django.contrib.admindocs.urls')),
url(r'admin/([^/]+)/([^/]+)/bulk_caption/$', 'files.views.bulk_caption'),
# Uncomment the next line to enable the admin:
(r'^admin/(.*)', admin.site.root),
url(r'^login/$',
auth_views.login,
{'template_name': 'login.html'},
name='auth_login'),
url(r'^$',
auth_views.login,
{'template_name': 'login.html'},
name='auth_login'),
url(r'^logout/$',
auth_views.logout_then_login,
{ 'login_url': '/' }, name='auth_logout'),
url(r'^password/change/$',
auth_views.password_change,
name='auth_password_change'),
url(r'^password/change/done/$',
auth_views.password_change_done,
name='auth_password_change_done'),
url(r'^password/reset/$',
auth_views.password_reset,
name='auth_password_reset'),
url(r'^password/reset/confirm/(?P<uidb36>[0-9A-Za-z]+)-(?P<token>.+)/$',
auth_views.password_reset_confirm,
name='auth_password_reset_confirm'),
url(r'^password/reset/complete/$',
auth_views.password_reset_complete,
name='auth_password_reset_complete'),
url(r'^password/reset/done/$',
auth_views.password_reset_done,
name='auth_password_reset_done'),
url(r'^contact/$',
direct_to_template,
{'template':'contact.html'},
name='contact'),
url(r'^howto/$',
direct_to_template,
{'template':'howto.html'},
name='howto'),
(r'^', include('files.urls')),
)
if settings.DEBUG:
urlpatterns += patterns('',
(r'^static/(?P<path>.*)$',
'django.views.static.serve',
{'document_root': settings.MEDIA_ROOT, 'show_indexes': True}),
)