Ejemplo n.º 1
0
    (r'smoketest/', include('smoketest.urls')),
    (r'infranil/', include('infranil.urls')),
    (r'^uploads/(?P<path>.*)$',
     'django.views.static.serve', {'document_root': settings.MEDIA_ROOT}),
    (r'^pagetree/', include('pagetree.urls')),
    (r'^quizblock/', include('quizblock.urls')),
    (r'^pages/edit/(?P<path>.*)$', login_required(EditView.as_view(
        hierarchy_name="main",
        hierarchy_base="/pages/")),
     {}, 'edit-page'),
    (r'^pages/instructor/(?P<path>.*)$',
        login_required(InstructorView.as_view(
            hierarchy_name="main",
            hierarchy_base="/pages/"))),
    (r'^pages/(?P<path>.*)$', PageView.as_view(
        hierarchy_name="main",
        hierarchy_base="/pages/")),

    url(r'^wagtail/admin/', include(wagtailadmin_urls)),
    url(r'^wagtail/documents/', include(wagtaildocs_urls)),
    url(r'search/$', views.search, name='search'),


    # For anything not caught by a more specific rule above, hand over to
    # Wagtail's serving mechanism
    url(r'^wagtail/', include(wagtail_urls)),
)

if settings.DEBUG:
    import debug_toolbar
    urlpatterns += patterns(
Ejemplo n.º 2
0
    url(r'^registration/', include('registration.backends.default.urls')),
    url(r'^$', views.IndexView.as_view()),
    url(r'^admin/', include(admin.site.urls)),
    url(r'^_impersonate/', include('impersonate.urls')),
    url(r'^stats/$', TemplateView.as_view(template_name="stats.html")),
    url(r'smoketest/', include('smoketest.urls')),
    url(r'infranil/', include('infranil.urls')),
    url(r'^uploads/(?P<path>.*)$', serve,
        {'document_root': settings.MEDIA_ROOT}),
    url(r'^pagetree/', include('pagetree.urls')),
    url(r'^quizblock/', include('quizblock.urls')),
    url(
        r'^pages/edit/(?P<path>.*)$',
        login_required(
            EditView.as_view(hierarchy_name="main", hierarchy_base="/pages/")),
        {}, 'edit-page'),
    url(
        r'^pages/instructor/(?P<path>.*)$',
        login_required(
            InstructorView.as_view(hierarchy_name="main",
                                   hierarchy_base="/pages/"))),
    url(r'^pages/(?P<path>.*)$',
        PageView.as_view(hierarchy_name="main", hierarchy_base="/pages/")),
]

if settings.DEBUG:
    import debug_toolbar
    urlpatterns += [
        url(r'^__debug__/', include(debug_toolbar.urls)),
    ]
Ejemplo n.º 3
0
from django.conf.urls import patterns, include
from pagetree.generic.views import EditView, InstructorView, PageView

urlpatterns = patterns(
    '',
    (r'^pagetree/', include('pagetree.urls')),

    # instantiate generic views using a template that doesn't
    # extend/depend on base.html
    (r'^pages/edit/(?P<path>.*)$',
     EditView.as_view(template_name="pagetree/test_page.html"),
     {}, 'edit-page'),
    (r'^pages/instructor/(?P<path>.*)$',
     InstructorView.as_view(template_name="pagetree/test_page.html")),
    (r'^pages/(?P<path>.*)$',
     PageView.as_view(template_name="pagetree/test_page.html")),

    # a second set to make sure non-default hierarchies
    # get handled as well
    (r'^pages2/edit/(?P<path>.*)$',
     EditView.as_view(
         hierarchy_name="two",
         hierarchy_base="/pages2",
         template_name="pagetree/test_page.html"),
     {}, 'edit-page'),
    (r'^pages2/instructor/(?P<path>.*)$',
     InstructorView.as_view(
         hierarchy_name="two",
         hierarchy_base="/pages2",
         template_name="pagetree/test_page.html")),
    (r'^pages2/(?P<path>.*)$',
Ejemplo n.º 4
0
    url(r'^participant/archive/$', ArchiveParticipantView.as_view()),
    url(r'^participant/clear/$', ClearParticipantView.as_view()),
    url(r'^participant/create/$', CreateParticipantView.as_view()),
    url(r'^participant/language/$', ParticipantLanguageView.as_view(),
        name='participant-language'),
    url(r'^participant/login/$', LoginParticipantView.as_view()),
    url(r'^participant/note/$', ParticipantNoteView.as_view()),
    url(r'^participant/print/$', ParticipantPrintView.as_view(),
        {}, 'participant-print-view'),
    url(r'^participant/track/$', TrackParticipantView.as_view()),

    # English
    url(r'^pages/en/edit/(?P<path>.*)$', RestrictedEditView.as_view(
        hierarchy_name="en", hierarchy_base="/pages/en/")),
    url(r'^pages/en/(?P<path>.*)$', login_required(PageView.as_view(
        hierarchy_name="en", hierarchy_base="/pages/en/", gated=True)),
        {}, 'view-english-page'),

    # Spanish
    url(r'^pages/es/edit/(?P<path>.*)$', RestrictedEditView.as_view(
        hierarchy_name="es", hierarchy_base="/pages/es/")),
    url(r'^pages/es/(?P<path>.*)$', login_required(PageView.as_view(
        hierarchy_name="es", hierarchy_base="/pages/es/", gated=True)),
        {}, 'view-spanish-page')
]


if settings.DEBUG:
    urlpatterns += [
        url(r'^__debug__/', include(debug_toolbar.urls)),
    ]
Ejemplo n.º 5
0
from django.conf.urls import include, url
from pagetree.generic.views import EditView, InstructorView, PageView

urlpatterns = [
    url(r'^pagetree/', include('pagetree.urls')),

    # instantiate generic views using a template that doesn't
    # extend/depend on base.html
    url(r'^pages/edit/(?P<path>.*)$',
        EditView.as_view(template_name="pagetree/test_page.html"), {},
        'edit-page'),
    url(r'^pages/instructor/(?P<path>.*)$',
        InstructorView.as_view(template_name="pagetree/test_page.html")),
    url(r'^pages/(?P<path>.*)$',
        PageView.as_view(template_name="pagetree/test_page.html")),

    # a second set to make sure non-default hierarchies
    # get handled as well
    url(
        r'^pages2/edit/(?P<path>.*)$',
        EditView.as_view(hierarchy_name="two",
                         hierarchy_base="/pages2",
                         template_name="pagetree/test_page.html"), {},
        'edit-page'),
    url(
        r'^pages2/instructor/(?P<path>.*)$',
        InstructorView.as_view(hierarchy_name="two",
                               hierarchy_base="/pages2",
                               template_name="pagetree/test_page.html")),
    url(
Ejemplo n.º 6
0
        capsim.sim.views.ParameterEditView.as_view()),
    url(r'^calibrate/parameter/add/$',
        capsim.sim.views.ParameterAddView.as_view()),
    url(r'^calibrate/parameter/(?P<pk>\d+)/delete/$',
        DeleteView.as_view(
            model=Parameter,
            success_url="/calibrate/parameter/")),

    url(r'^admin/', admin.site.urls),
    url(r'^_impersonate/', include('impersonate.urls')),
    url(r'^stats/', TemplateView.as_view(template_name="stats.html")),
    url(r'^model/', TemplateView.as_view(template_name="main/model.html")),
    url(r'smoketest/', include('smoketest.urls')),
    url(r'^infranil/(?P<path>.*)$', InfranilView.as_view()),
    url(r'^uploads/(?P<path>.*)$', django.views.static.serve,
        {'document_root': settings.MEDIA_ROOT}),
    url(r'^pagetree/', include('pagetree.urls')),
    url(r'^quizblock/', include('quizblock.urls')),
    url(r'^pages/edit/(?P<path>.*)$', capsim.main.views.EditPage.as_view(),
        {}, 'edit-page'),
    url(r'^pages/instructor/(?P<path>.*)$',
        capsim.main.views.InstructorPage.as_view()),
    url(r'^pages/(?P<path>.*)$', PageView.as_view(
        hierarchy_name="main",
        hierarchy_base="/pages/")),
]

if settings.DEBUG:
    import debug_toolbar
    urlpatterns += [url(r'^__debug__/', include(debug_toolbar.urls))]