-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathurls.py
39 lines (31 loc) · 1.49 KB
/
urls.py
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
from django.conf.urls import patterns, include, url
from django.contrib.staticfiles.urls import staticfiles_urlpatterns
# Uncomment the next two lines to enable the admin:
from django.contrib import admin
admin.autodiscover()
urlpatterns = patterns('',
# Examples:
# url(r'^$', 'django_blog.views.home', name='home'),
# url(r'^django_blog/', include('django_blog.foo.urls')),
# Uncomment the admin/doc line below to enable admin documentation:
url(r'^admin/doc/', include('django.contrib.admindocs.urls')),
# Uncomment the next line to enable the admin:
url(r'^admin/', include(admin.site.urls)),
# url(r'^$', contacts.views.ListContactView.as_view(),
# name='contacts-list',),
# url(r'^new$', contacts.views.CreateContactView.as_view(),
# name='contacts-new',),
url(r'^$', 'blog.views.index'),
url(r'^blog/$', 'blog.views.index'),
url(r'^blog/new$', 'blog.views.new', name='blog-new'),
url(r'^blog/create', 'blog.views.create'),
url(r'^blog/(?P<id>\w+)/', 'blog.views.show'),
url(r'^picture/$', 'picture.views.index'),
url(r'^picture/new$', 'picture.views.new', name='blog-new'),
url(r'^picture/create', 'picture.views.create'),
url(r'^picture/(?P<id>\w+)/$', 'picture.views.show'),
url(r'^picture/(?P<id>\w+)/delete/$', 'picture.views.delete'),
# url(r'^new$', blog.views.CreateContactView.as_view(),
# name='contacts-new',),
)
urlpatterns += staticfiles_urlpatterns()