from django.conf.urls.defaults import * from django.views.generic.list_detail import object_list from django.views.generic.simple import redirect_to,direct_to_template from django.views.generic import list_detail from projects.models.base import Project projects = { 'queryset': Project.objects.filter(status__exact=1).order_by('-pub_date'), } urlpatterns = patterns('', (r'data/(?P\d+)/$', 'projects.views.data_json'), (r'(?P[-\w]+)/$', 'projects.views.detail'), (r'^$',list_detail.object_list, dict(projects, template_name='archives/projects.html')), )