summaryrefslogtreecommitdiff
path: root/apps/blog/urls.py
blob: 57a3e7a5c294954a594e5cd52bf6a25bea5bcc0f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
from django.conf.urls.defaults import *
from django.views.generic.list_detail import object_list
from django.views.generic.simple import redirect_to

from blog.models import Entry



urlpatterns = patterns('',
    
    (r'(?P<slug>[-\w]+)/(?P<page>\d+)/$', 'blog.views.entry_list_by_area'),
    (r'(?P<page>\d+)/$', 'blog.views.entry_list'),
    (r'(?P<slug>[-\w]+)/$', redirect_to, {'url': '/writing/%(slug)s/1/'}),
    (r'', redirect_to, {'url': '/writing/1/'}),
)