bgneal@574
|
1 from django.conf.urls import patterns, url, include
|
bgneal@580
|
2 from django.conf.urls.static import static
|
bgneal@6
|
3 from django.conf import settings
|
gremmie@1
|
4 from django.contrib import admin
|
bgneal@177
|
5 from django.views.decorators.cache import cache_page
|
bgneal@170
|
6
|
bgneal@415
|
7 from haystack.views import search_view_factory
|
bgneal@219
|
8
|
gremmie@1
|
9 from news.feeds import LatestNewsFeed
|
bgneal@170
|
10 from forums.feeds import ForumsFeed
|
bgneal@469
|
11 from custom_search.forms import CustomModelSearchForm
|
gremmie@1
|
12
|
bgneal@141
|
13
|
gremmie@1
|
14 admin.autodiscover()
|
gremmie@1
|
15
|
gremmie@1
|
16 urlpatterns = patterns('',
|
bgneal@19
|
17 url(r'^$', 'views.home', name='home'),
|
gremmie@1
|
18 (r'^admin/doc/', include('django.contrib.admindocs.urls')),
|
bgneal@579
|
19
|
bgneal@579
|
20 url(r'^admin/password_reset/$', 'django.contrib.auth.views.password_reset', name='admin_password_reset'),
|
bgneal@579
|
21 (r'^admin/password_reset/done/$', 'django.contrib.auth.views.password_reset_done'),
|
bgneal@579
|
22 (r'^reset/(?P<uidb36>[0-9A-Za-z]+)-(?P<token>.+)/$', 'django.contrib.auth.views.password_reset_confirm'),
|
bgneal@579
|
23 (r'^reset/done/$', 'django.contrib.auth.views.password_reset_complete'),
|
bgneal@579
|
24
|
gremmie@1
|
25 (r'^admin/', include(admin.site.urls)),
|
gremmie@1
|
26 (r'^accounts/', include('accounts.urls')),
|
bgneal@215
|
27 (r'^antispam/', include('antispam.urls')),
|
gremmie@1
|
28 (r'^calendar/', include('gcalendar.urls')),
|
gremmie@1
|
29 (r'^comments/', include('comments.urls')),
|
gremmie@1
|
30 (r'^contact/', include('contact.urls')),
|
bgneal@540
|
31 (r'^contests/', include('contests.urls')),
|
bgneal@127
|
32 (r'^core/', include('core.urls')),
|
bgneal@35
|
33 (r'^donations/', include('donations.urls')),
|
gremmie@1
|
34 (r'^downloads/', include('downloads.urls')),
|
bgneal@176
|
35 url(r'^feeds/news/$',
|
bgneal@573
|
36 cache_page(6 * 60 * 60)(LatestNewsFeed()),
|
bgneal@176
|
37 name='feeds-news'),
|
bgneal@176
|
38 url(r'^feeds/forums/$',
|
bgneal@573
|
39 cache_page(5 * 60)(ForumsFeed()),
|
bgneal@176
|
40 {'forum_slug': None},
|
bgneal@176
|
41 'feeds-forum_combined'),
|
bgneal@176
|
42 url(r'^feeds/forums/(?P<forum_slug>[\w\d-]+)/$',
|
bgneal@573
|
43 cache_page(5 * 60)(ForumsFeed()),
|
bgneal@176
|
44 name='feeds-forum'),
|
bgneal@81
|
45 (r'^forums/', include('forums.urls')),
|
gremmie@1
|
46 (r'^irc/', include('irc.urls')),
|
gremmie@1
|
47 (r'^links/', include('weblinks.urls')),
|
gremmie@1
|
48 (r'^member_map/', include('membermap.urls')),
|
gremmie@1
|
49 (r'^messages/', include('messages.urls')),
|
gremmie@1
|
50 (r'^news/', include('news.urls')),
|
bgneal@285
|
51 (r'^oembed/', include('oembed.urls')),
|
bgneal@544
|
52 (r'^pb/', include('phantombrigade.urls')),
|
gremmie@1
|
53 (r'^podcast/', include('podcast.urls')),
|
gremmie@1
|
54 (r'^polls/', include('polls.urls')),
|
gremmie@1
|
55 (r'^potd/', include('potd.urls')),
|
gremmie@1
|
56 (r'^profile/', include('bio.urls')),
|
gremmie@1
|
57 (r'^shout/', include('shoutbox.urls')),
|
bgneal@12
|
58 (r'^smiley/', include('smiley.urls')),
|
bgneal@323
|
59 (r'^ygroup/', include('ygroup.urls')),
|
gremmie@1
|
60 )
|
gremmie@1
|
61
|
bgneal@219
|
62 # Haystack search views
|
bgneal@219
|
63 urlpatterns += patterns('haystack.views',
|
bgneal@415
|
64 url(r'^search/$',
|
bgneal@438
|
65 search_view_factory(form_class=CustomModelSearchForm, load_all=True),
|
bgneal@219
|
66 name='haystack_search'),
|
bgneal@219
|
67 )
|
bgneal@219
|
68
|
bgneal@580
|
69 # For serving media files in development only:
|
bgneal@580
|
70 urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
|