annotate bns_website/urls.py @ 8:92537b487942
Saving initial band data as a fixture.
author |
Brian Neal <bgneal@gmail.com> |
date |
Sat, 29 Oct 2011 21:07:53 -0500 |
parents |
48ff23eab86a |
children |
f2cb9b2ec552 |
rev |
line source |
bgneal@0
|
1 from django.conf.urls.defaults import patterns, include, url
|
bgneal@6
|
2 from django.contrib import admin
|
bgneal@3
|
3 from django.views.generic.base import TemplateView
|
bgneal@6
|
4 from django.views.generic import ListView
|
bgneal@0
|
5
|
bgneal@6
|
6 from bands.models import Band
|
bgneal@3
|
7
|
bgneal@6
|
8 admin.autodiscover()
|
bgneal@0
|
9
|
bgneal@0
|
10 urlpatterns = patterns('',
|
bgneal@6
|
11 url(r'^$',
|
bgneal@3
|
12 TemplateView.as_view(template_name="home.html"),
|
bgneal@3
|
13 name="home"),
|
bgneal@6
|
14 url(r'^bands/$',
|
bgneal@6
|
15 ListView.as_view(model=Band),
|
bgneal@6
|
16 name="bands"),
|
bgneal@3
|
17
|
bgneal@0
|
18 # Examples:
|
bgneal@0
|
19 # url(r'^$', 'bns_website.views.home', name='home'),
|
bgneal@0
|
20 # url(r'^bns_website/', include('bns_website.foo.urls')),
|
bgneal@0
|
21
|
bgneal@6
|
22 url(r'^admin/doc/', include('django.contrib.admindocs.urls')),
|
bgneal@6
|
23 url(r'^admin/', include(admin.site.urls)),
|
bgneal@0
|
24 )
|