Mercurial > public > madeira
annotate gigs/urls.py @ 183:3ecc1fb1e8b9
Update copyright for 2016.
author | Brian Neal <bgneal@gmail.com> |
---|---|
date | Fri, 15 Jan 2016 22:17:58 -0600 |
parents | 312f198e8958 |
children |
rev | line source |
---|---|
bgneal@44 | 1 """ |
bgneal@44 | 2 Urls for the gigs application. |
bgneal@44 | 3 |
bgneal@44 | 4 """ |
bgneal@180 | 5 from django.conf.urls import url |
bgneal@44 | 6 from django.views.generic import ListView |
bgneal@44 | 7 |
bgneal@44 | 8 from gigs.models import Gig |
bgneal@180 | 9 import gigs.views |
bgneal@44 | 10 |
bgneal@44 | 11 |
bgneal@180 | 12 urlpatterns = [ |
bgneal@180 | 13 url(r'^$', gigs.views.gigs, name='gigs-index'), |
bgneal@44 | 14 url(r'^flyers/$', |
bgneal@44 | 15 ListView.as_view( |
bgneal@44 | 16 queryset=Gig.objects.exclude(flyer__isnull=True).select_related('flyer'), |
bgneal@44 | 17 template_name='gigs/flyers.html', |
bgneal@111 | 18 paginate_by=10, |
bgneal@44 | 19 context_object_name='gig_list'), |
bgneal@44 | 20 name='gigs-flyers') |
bgneal@180 | 21 ] |