Exemplo n.º 1
0
from django.conf.urls.defaults import *
from django.conf import settings
from django.contrib import admin

from haystack.forms import SearchForm
from haystack.views import SearchView

import nexus

admin.autodiscover()
nexus.autodiscover()

urlpatterns = patterns('activity_feed.views',
    url(r'^$', 'index'),

    url(r'^feed/(?P<page>\d+)/$', 'activity'),
)

urlpatterns += patterns('haystack.views',
    url(r'^movies/search/$', SearchView(template='movie_search.html',
        form_class=SearchForm), name='movie-search')
)

urlpatterns += patterns('user_profile.views',
    url(r'^users/(?P<user_id>\d+)/$', 'profile', name='user-profile'),

    url(r'^users/(?P<user_id>\d+)/raves/(?P<page>\d+)/$', 'activity'),
    url(r'^users/(?P<user_id>\d+)/marks/(?P<page>\d+)/$', 'bookmarks'),
    url(r'^users/(?P<user_id>\d+)/following/(?P<page>\d+)/$', 'following'),
    url(r'^users/(?P<user_id>\d+)/followers/(?P<page>\d+)/$', 'followers'),
)
Exemplo n.º 2
0
from django.conf.urls.defaults import *

import nexus

nexus.autodiscover()

urlpatterns = patterns(
    '',
    url(r'', include(nexus.site.urls)),
)