예제 #1
0
from django.conf.urls import url, patterns, include
from views import PublicUserProfile, ProfileListView, login_view, login_redirect

profile_list = ProfileListView.as_view()
user_public_profile = PublicUserProfile.as_view(
    template_name='user/public_profile.html')
user_tagged_items = PublicUserProfile.as_view(
    template_name='user/tagged_items.html')
user_annotated_items = PublicUserProfile.as_view(
    template_name='user/annotated_items.html')
user_followed_topics = PublicUserProfile.as_view(
    template_name='user/followed_topics.html')

# views coded in this app
urlpatterns = patterns(
    'user.views', url(r'^create/$', 'create_user', name='register'),
    url(r'^edit-profile/$', 'edit_profile', name='edit-profile'),
    url(r'^follow/$', 'user_follow_unfollow', name='user-follow-unfollow'),
    url(r'^follow-query/$', 'user_is_following', name='user-is-following'))

# auth views
urlpatterns += patterns(
    'django.contrib.auth.views',
    url(r'^logout/$', 'logout_then_login', name='logout'),
    url(r'^password_reset/$',
        'password_reset', {'template_name': 'user/password_reset_form.html'},
        name='password_reset'),
    url(r'^password_reset/done/$',
        'password_reset_done',
        {'template_name': 'user/password_reset_done.html'},
        name='password_reset_done'),
예제 #2
0
from django.conf.urls.defaults import *
from views import PublicUserProfile, ProfileListView

profile_list = ProfileListView.as_view()
user_public_profile = PublicUserProfile.as_view(template_name='user/public_profile.html')
user_tagged_items = PublicUserProfile.as_view(template_name='user/tagged_items.html')
user_annotated_items = PublicUserProfile.as_view(template_name='user/annotated_items.html')

# views coded in this app
urlpatterns = patterns('knesset.user.views',
    url(r'^create/$', 'create_user', name ='register'),
    url(r'^members/$', 'follow_members', name ='follow-members'),
    url(r'^bills/$', 'follow_bills', name='follow-bills'),
    url(r'^agendas/$', 'follow_agendas', name ='follow-agendas'),
    url(r'^edit-profile/$', 'edit_profile', name='edit-profile'),
    url(r'^unfollow/$', 'user_unfollows', name='user-unfollows'),
    )

# auth views
urlpatterns += patterns('django.contrib.auth.views',
    url(r'^login/$', 'login', {'template_name': 'user/login.html'}, name='login'),
    url(r'^logout/$', 'logout_then_login', name='logout'),
    url(r'^password_reset/$', 'password_reset', {'template_name': 'user/password_reset_form.html'}, name='password_reset'),
    url(r'^password_reset/done/$', 'password_reset_done', {'template_name': 'user/password_reset_done.html'}),
    url(r'^reset/(?P<uidb36>[0-9A-Za-z]+)-(?P<token>.+)/$', 'password_reset_confirm', {'template_name': 'user/password_reset_confirm.html'}),
    url(r'^reset/done/$', 'password_reset_complete', {'template_name': 'user/password_reset_complete.html'}),
    )

urlpatterns += patterns('',
    (r'^registration/', include('knesset.accounts.urls')),
    url(r'^(?P<pk>\d+)/$', user_public_profile, name='public-profile'),
예제 #3
0
from django.conf.urls.defaults import *
from views import PublicUserProfile, ProfileListView

profile_list = ProfileListView()
user_public_profile = PublicUserProfile.as_view(template_name='user/public_profile.html')
user_tagged_items = PublicUserProfile.as_view(template_name='user/tagged_items.html')
user_annotated_items = PublicUserProfile.as_view(template_name='user/annotated_items.html')

# views coded in this app
urlpatterns = patterns('knesset.user.views',
    url(r'^create/$', 'create_user', name ='register'),
    url(r'^members/$', 'follow_members', name ='follow-members'),
    url(r'^bills/$', 'follow_bills', name='follow-bills'),
    url(r'^agendas/$', 'follow_agendas', name ='follow-agendas'),
    url(r'^edit-profile/$', 'edit_profile', name='edit-profile'),
    url(r'^unfollow/$', 'user_unfollows', name='user-unfollows'),
    )

# auth views
urlpatterns += patterns('django.contrib.auth.views',
    url(r'^login/$', 'login', {'template_name': 'user/login.html'}, name='login'),
    url(r'^logout/$', 'logout_then_login', name='logout'),
    url(r'^password_reset/$', 'password_reset', {'template_name': 'user/password_reset_form.html'}, name='password_reset'),
    url(r'^password_reset/done/$', 'password_reset_done', {'template_name': 'user/password_reset_done.html'}),
    url(r'^reset/(?P<uidb36>[0-9A-Za-z]+)-(?P<token>.+)/$', 'password_reset_confirm', {'template_name': 'user/password_reset_confirm.html'}),
    url(r'^reset/done/$', 'password_reset_complete', {'template_name': 'user/password_reset_complete.html'}),
    )

urlpatterns += patterns('',
    (r'^registration/', include('knesset.accounts.urls')),
    url(r'^(?P<pk>\d+)/$', user_public_profile, name='public-profile'),
예제 #4
0
        ConfigListView.as_view(),
        name='gnmgridintegration_admin_meta'),
    url(
        r'^admin/metadata$',
        RedirectView.as_view(url=reverse_lazy('gnmgridintegration_admin_meta'),
                             permanent=True)),
    url(r'^admin/enable/new$',
        ProfileCreateView.as_view(),
        name='gnmgridintegration_new_profile'),
    url(r'^admin/enable/test/(?P<vs_item_id>\w{2}-\d+)/iteminfo$',
        MDItemInfoView.as_view(),
        name='gnmgridintegration_enable_item_meta'),
    url(r'^admin/enable/test/(?P<vs_item_id>\w{2}-\d+)$',
        ProfileTestView.as_view(),
        name='gnmgridintegation_test_profile'),
    url(r'^admin/enable/(?P<pk>\d+)/edit$',
        ProfileEditView.as_view(),
        name='gnmgridintegration_edit_profile'),
    url(r'^admin/enable/(?P<pk>\d+)/delete$',
        ProfileDeleteView.as_view(),
        name='gnmgridintegration_delete_profile'),
    url(r'^admin/enable/$',
        ProfileListView.as_view(),
        name='gnmgridintegration_admin_enable'),
    url(
        r'^admin/enable$',
        RedirectView.as_view(
            url=reverse_lazy('gnmgridintegration_admin_enable'),
            permanent=True)),
)
예제 #5
0
from django.conf.urls.defaults import patterns,url
from views import VSCallbackView, ConfigListView, MDEditView, MDDeleteView, MDCreateView, MDTestView, MDItemInfoView
from views import ProfileCreateView, ProfileDeleteView, ProfileEditView, ProfileListView, ProfileTestView
from django.views.generic.base import RedirectView
from django.core.urlresolvers import reverse_lazy
# This new app handles the request to the URL by responding with the view which is loaded 
# from portal.plugins.gnmgridintegration.views.py. Inside that file is a class which responsedxs to the 
# request, and sends in the arguments template - the html file to view.
# name is shortcut name for the urls.

urlpatterns = patterns('portal.plugins.gnmgridintegration.views',
    url(r'^$', 'GenericAppView', kwargs={'template': 'gnmgridintegration/index.html'}, name='index'),
    url(r'^callback/jobnotification$',VSCallbackView.as_view(), name='gridintegration_callback_url'),

    url(r'^admin/metadata/(?P<pk>\d+)/edit$', MDEditView.as_view(), name='gnmgridintegration_edit_meta'),
    url(r'^admin/metadata/(?P<pk>\d+)/delete$', MDDeleteView.as_view(), name='gnmgridintegration_delete_meta'),
    url(r'^admin/metadata/new$', MDCreateView.as_view(), name='gnmgridintegration_new_meta'),
    url(r'^admin/metadata/test/(?P<vs_item_id>\w{2}-\d+)/iteminfo$', MDItemInfoView.as_view(), name='gnmgridintegration_item_meta'),
    url(r'^admin/metadata/test/(?P<vs_item_id>\w{2}-\d+)$', MDTestView.as_view(), name='gnmgridintegration_test_meta'),
    url(r'^admin/metadata/$', ConfigListView.as_view(), name='gnmgridintegration_admin_meta'),
    url(r'^admin/metadata$', RedirectView.as_view(url=reverse_lazy('gnmgridintegration_admin_meta'), permanent=True)),

    url(r'^admin/enable/new$', ProfileCreateView.as_view(), name='gnmgridintegration_new_profile'),
    url(r'^admin/enable/test/(?P<vs_item_id>\w{2}-\d+)/iteminfo$', MDItemInfoView.as_view(), name='gnmgridintegration_enable_item_meta'),
    url(r'^admin/enable/test/(?P<vs_item_id>\w{2}-\d+)$', ProfileTestView.as_view(), name='gnmgridintegation_test_profile'),
    url(r'^admin/enable/(?P<pk>\d+)/edit$', ProfileEditView.as_view(), name='gnmgridintegration_edit_profile'),
    url(r'^admin/enable/(?P<pk>\d+)/delete$', ProfileDeleteView.as_view(), name='gnmgridintegration_delete_profile'),
    url(r'^admin/enable/$', ProfileListView.as_view(), name='gnmgridintegration_admin_enable'),
    url(r'^admin/enable$', RedirectView.as_view(url=reverse_lazy('gnmgridintegration_admin_enable'), permanent=True)),
)