Mercurial > public > sg101
diff user_photos/urls.py @ 696:b2a8fde3173a
Got the image resizing and uploading working. It needs a lot of work though.
This commit is just to capture something that works.
author | Brian Neal <bgneal@gmail.com> |
---|---|
date | Sun, 08 Sep 2013 19:06:54 -0500 |
parents | 2d35e5f97a99 |
children | 809d27b385f2 |
line wrap: on
line diff
--- a/user_photos/urls.py Sat Sep 07 20:50:46 2013 -0500 +++ b/user_photos/urls.py Sun Sep 08 19:06:54 2013 -0500 @@ -1,6 +1,13 @@ """URLs for the user_photos application.""" from django.conf.urls import patterns, url +from django.views.generic import DetailView + +from user_photos.models import Photo + urlpatterns = patterns('user_photos.views', url(r'^upload/$', 'upload', name='user_photos-upload'), + url(r'^photo/(?P<pk>\d+)/$', + DetailView.as_view(model=Photo), + name='user_photos-detail') )