comparison forums/urls.py @ 581:ee87ea74d46b

For Django 1.4, rearranged project structure for new manage.py.
author Brian Neal <bgneal@gmail.com>
date Sat, 05 May 2012 17:10:48 -0500
parents gpp/forums/urls.py@ddd69a8e07c7
children 5ba2508939f7
comparison
equal deleted inserted replaced
580:c525f3e0b5d0 581:ee87ea74d46b
1 """
2 URLs for the forums application.
3 """
4 from django.conf.urls import patterns, url
5
6 urlpatterns = patterns('forums.views.main',
7 url(r'^$', 'index', name='forums-index'),
8 url(r'^catchup/$', 'catchup_all', name='forums-catchup_all'),
9 url(r'^new-topic-success/(?P<tid>\d+)$', 'new_topic_thanks', name='forums-new_topic_thanks'),
10 url(r'^topic/(?P<id>\d+)/$', 'topic_index', name='forums-topic_index'),
11 url(r'^topic/(?P<id>\d+)/unread/$', 'topic_unread', name='forums-topic_unread'),
12 url(r'^topic/(?P<id>\d+)/latest/$', 'topic_latest', name='forums-topic_latest'),
13 url(r'^topic/active/(\d+)/$', 'active_topics', name='forums-active_topics'),
14 url(r'^delete-post/$', 'delete_post', name='forums-delete_post'),
15 url(r'^edit/(?P<id>\d+)/$', 'edit_post', name='forums-edit_post'),
16 url(r'^flag-post/$', 'flag_post', name='forums-flag_post'),
17 url(r'^forum/(?P<slug>[\w\d-]+)/$', 'forum_index', name='forums-forum_index'),
18 url(r'^forum/(?P<slug>[\w\d-]+)/catchup/$', 'forum_catchup', name='forums-catchup'),
19 url(r'^forum/(?P<slug>[\w\d-]+)/new-topic/$', 'new_topic', name='forums-new_topic'),
20 url(r'^mod/forum/(?P<slug>[\w\d-]+)/$', 'mod_forum', name='forums-mod_forum'),
21 url(r'^mod/topic/delete/(\d+)/$', 'mod_topic_delete', name='forums-mod_topic_delete'),
22 url(r'^mod/topic/lock/(\d+)/$', 'mod_topic_lock', name='forums-mod_topic_lock'),
23 url(r'^mod/topic/move/(\d+)/$', 'mod_topic_move', name='forums-mod_topic_move'),
24 url(r'^mod/topic/split/(\d+)/$', 'mod_topic_split', name='forums-mod_topic_split'),
25 url(r'^mod/topic/stick/(\d+)/$', 'mod_topic_stick', name='forums-mod_topic_stick'),
26 url(r'^my-posts/$', 'my_posts', name='forums-my_posts'),
27 url(r'^post/(\d+)/$', 'goto_post', name='forums-goto_post'),
28 url(r'^post/ip/(\d+)/$', 'post_ip_info', name='forums-post_ip_info'),
29 url(r'^post/new/(?P<topic_id>\d+)/$', 'new_post', name='forums-new_post'),
30 url(r'^posts/(?P<username>[\w.@+-]{1,30})/$', 'posts_for_user', name='forums-posts_for_user'),
31 url(r'^quick-reply/$', 'quick_reply_ajax', name='forums-quick_reply'),
32 url(r'^unanswered/$', 'unanswered_topics', name='forums-unanswered_topics'),
33 url(r'^unread/$', 'unread_topics', name='forums-unread_topics'),
34 )
35
36 urlpatterns += patterns('forums.views.favorites',
37 url(r'^favorite/(\d+)/$', 'favorite_topic', name='forums-favorite_topic'),
38 url(r'^favorites/$', 'manage_favorites', name='forums-manage_favorites'),
39 url(r'^favorites/(\d+)/$', 'favorites_status', name='forums-favorites_status'),
40 url(r'^unfavorite/(\d+)/$', 'unfavorite_topic', name='forums-unfavorite_topic'),
41 )
42
43 urlpatterns += patterns('forums.views.subscriptions',
44 url(r'^subscribe/(\d+)/$', 'subscribe_topic', name='forums-subscribe_topic'),
45 url(r'^subscriptions/$', 'manage_subscriptions', name='forums-manage_subscriptions'),
46 url(r'^subscriptions/(\d+)/$', 'subscription_status', name='forums-subscription_status'),
47 url(r'^unsubscribe/(\d+)/$', 'unsubscribe_topic', name='forums-unsubscribe_topic'),
48 )
49
50 urlpatterns += patterns('forums.views.spam',
51 url(r'^spammer/(\d+)/$', 'spammer', name='forums-spammer'),
52 url(r'^spammer/nailed/(\d+)/$', 'spammer_nailed', name='forums-spammer_nailed'),
53 url(r'^stranger/(\d+)/$', 'stranger', name='forums-stranger'),
54 )
55
56 urlpatterns += patterns('forums.views.attachments',
57 url(r'^fetch_attachments/$', 'fetch_attachments', name='forums-fetch_attachments'),
58 )