Example #1
0
        name='groups_edit'),
    url(r'^groups/(?P<pk>\d+)/delete/$',
        GroupDeleteView.as_view(),
        name='groups_delete'),

    # Journal urls
    url(r'^journal/(?P<pk>\d+)?/?$', JournalView.as_view(), name='journal'),
    url(r'^journal/(?P<sid>\d+)/edit/$',
        'students.views.journal.journal_edit',
        name='journal_edit'),

    # Exam urls
    url(r'^exams/$', 'students.views.exams.exams_list', name='exams'),
    url(r'^exams/add/$', ExamCreateView.as_view(), name='exams_add'),
    url(r'^exams/(?P<pk>\d+)/edit/$',
        ExamUpdateView.as_view(),
        name='exams_edit'),
    url(r'^exams/(?P<pk>\d+)/delete/$',
        ExamDeleteView.as_view(),
        name='exams_delete'),
    url(r'^exam_results/$',
        'students.views.exam_results.exam_results',
        name='exam_results'),

    # Contact Admin Form
    url(r'^contact-admin/$', ContactView.as_view(), name='contact_admin'),
    url(r'^admin/', include(admin.site.urls)),
]

if DEBUG:
    # serve files from media folder
Example #2
0
from students.views.exams import ExamCreateView, ExamUpdateView, ExamDeleteView

urlpatterns = patterns('',
    # Examples:
    # url(r'^$', 'studentsdb.views.home', name='home'),
    # url(r'^blog/', include('blog.urls')),

    url(r'^admin/', include(admin.site.urls)),
    url(r'^$', 'students.views.students.students_list', name='home'),
    url(r'^students/add/$', StudentCreateView.as_view(), name='students_add'),
    url(r'^students/(?P<pk>\d+)/edit/$', StudentUpdateView.as_view(), name='students_edit'),
    url(r'^students/(?P<pk>\d+)/delete/$', StudentDeleteView.as_view(), name='students_delete'),
    url(r'^groups/$', 'students.views.groups.groups_list', name='groups'),
    url(r'^groups/add/$', GroupCreateView.as_view(), name='groups_add'),
    url(r'^groups/(?P<pk>\d+)/edit/$', GroupUpdateView.as_view(), name='groups_edit'),
    url(r'^groups/(?P<pk>\d+)/delete/$', GroupDeleteView.as_view(), name='groups_delete'),
    url(r'^journal/$', 'students.views.journal.journal_list', name='journal'),
    url(r'^exams/$', 'students.views.exams.exams_list', name='exams'),
    url(r'^exams/add/$', ExamCreateView.as_view(), name='exams_add'),
    url(r'^exams/(?P<pk>\d+)/edit/$', ExamUpdateView.as_view(), name='exams_edit'),
    url(r'^exams/(?P<pk>\d+)/delete/$', ExamDeleteView.as_view(), name='exams_delete'),
    url(r'^contact-admin/$', ContactView.as_view(), name='contact_admin'),
)

if DEBUG:
    # serve files from media folder
    urlpatterns += patterns('',
    url(r'^media/(?P<path>.*)$', 'django.views.static.serve', {
    'document_root': MEDIA_ROOT}))

Example #3
0
        login_required(GroupUpdateView.as_view()),
        name='groups_edit'),
    url(r'^groups/(?P<pk>\d+)/delete/$',
        login_required(GroupDeleteView.as_view()),
        name='groups_delete'),

    #Journal urls
    url(r'journal/(?P<pk>\d+)?/?$', JournalView.as_view(), name='journal'),

    #Exams urls
    url(r'^exams/$', login_required(exams_list),  name='exams'),
    url(r'^exams/add/$',
        login_required(ExamCreateView.as_view()),
        name='exams_add'),
    url(r'^exams/(?P<pk>\d+)/edit/$',
        login_required(ExamUpdateView.as_view()),
        name='exams_edit'),
    url(r'^exams/(?P<pk>\d+)/delete/$',
        login_required(ExamDeleteView.as_view()),
        name='exams_delete'),

    # User Related urls
    url(r'^users/profile/$', login_required(TemplateView.as_view(
        template_name='registration/profile.html')), name='profile'),
    url(r'^users/profile/(?P<pk>\d+)/edit/$',
        login_required(UserUpdateView.as_view()),
        name='profile_settings'),
    url(r'^profiles/$', 'stud_auth.views.users_list', name='profiles'),
    url(r'^users/logout/$', auth_views.logout, kwargs={'next_page': 'home'},
        name='auth_logout'),
    url(r'^register/complete/$', RedirectView.as_view(pattern_name='home'),
Example #4
0
        login_required(GroupDeleteView.as_view()),
        name='groups_delete'),
    url(r'^journal/(?P<pk>\d+)?/?$',
        login_required(JournalView.as_view()),
        name='journal'),
    url(r'^admin/', include(admin.site.urls)),

    # Exams urls
    url(r'^exams/$', login_required(exams_list), name='exams'),
    # url(r'^exams/add/$', 'students.views.exams.exams_add', name='exams_add'),
    url(r'^exams/add/$',
        login_required(ExamCreateView.as_view()),
        name='exams_add'),
    # url(r'^exams/(?P<eid>\d+)/edit/$', 'students.views.exams.exams_edit', name='exams_edit'),
    url(r'^exams/(?P<pk>\d+)/edit/$',
        login_required(ExamUpdateView.as_view()),
        name='exams_edit'),
    # url(r'^exams/(?P<eid>\d+)/delete/$', 'students.views.exams.exams_delete', name='exams_delete'),
    url(r'^exams/(?P<pk>\d+)/delete/$',
        login_required(ExamDeleteView.as_view()),
        name='exams_delete'),
    url(r'^admin/', include(admin.site.urls)),

    # Contact Admin Form
    url(r'^contact-admin/$',
        login_required(ContactView.as_view()),
        name='contact_admin'),

    # url for JS translation
    url(r'^jsi18n\.js$', 'django.views.i18n.javascript_catalog', js_info_dict),
Example #5
0
	url(r'^students/(?P<pk>\d+)/edit/$', login_required(StudentUpdateView.as_view()), name='students_edit'),
	url(r'^students/(?P<pk>\d+)/delete/$', login_required(StudentDeleteView.as_view()), name='students_delete'),

	# Groups urls
	url(r'^groups/$', login_required(students.views.groups.groups_list), name='groups'),
	url(r'^groups/add/$', login_required(GroupCreateView.as_view()), name='groups_add'),
	url(r'^groups/(?P<pk>\d+)/edit/$', login_required(GroupUpdateView.as_view()), name='groups_edit'),
	url(r'^groups/(?P<pk>\d+)/delete/$', login_required(GroupDeleteView.as_view()), name='groups_delete'),

	# Journal urls
	url(r'^journal/(?P<pk>\d+)?/?$', login_required(JournalView.as_view()), name='journal'),

	# Exams urls
	url(r'^exams/$', login_required(students.views.exams.exams_page), name='exams'),
	url(r'^exams/add/$', login_required(ExamCreateView.as_view()), name='exams_add'),
	url(r'^exams/(?P<pk>\d+)/edit/$', login_required(ExamUpdateView.as_view()), name='exams_edit'),
	url(r'^exams/(?P<pk>\d+)/delete/$', login_required(ExamDeleteView.as_view()), name='exams_delete'),

	# Contact Admin Form Class & Function
	# url(r'^contact-admin/$', ContactView.as_view(), name='contact_admin'),

    url(r'^contact-admin/$', login_required(students.views.contact_admin.contact_admin), name='contact_admin'),

	# JavaScript Code Translation
	url(r'^jsi18n\.js$', django.views.i18n.javascript_catalog, js_info_dict, name='jstranslate'),

	# set_language view
    url('^set-language/$', students.views.set_language.set_language, name='set_language'),

	# User Related urls
	url(r'^users/profile/$', login_required(TemplateView.as_view(template_name='registration/profile.html')), name='profile'),
Example #6
0
    #Groups urls
    url(r'^groups/$', login_required(groups.groups_list), name='groups'),
    url(r'^groups/add/(?P<lang>\S+)?$', login_required(GroupAddView.as_view()), name='groups_add'),
    url(r'^groups/(?P<pk>\d+)/edit/(?P<lang>\S+)?$', login_required(GroupUpdateView.as_view()),
        name='groups_edit'),
    url(r'^groups/(?P<pk>\d+)/delete', login_required(GroupDeleteView.as_view()),
        name='groups_delete'),

    # Journal url
    url(r'^journal/(?P<pk>\d+)?/?$', login_required(JournalView.as_view()), name='journal'),

    # Exams urls
    url(r'^exams/$', login_required(exams.exams_list), name='exams'),
    url(r'^exams/add/$', login_required(ExamAddView.as_view()), name='exams_add'),
    url(r'^exams/(?P<pk>\d+)/edit', login_required(ExamUpdateView.as_view()),
        name='exams_edit'),
    url(r'^exams/(?P<pk>\d+)/delete', login_required(ExamDeleteView.as_view()),
        name='exams_delete'),

    # Results urls
    url(r'^results/$', login_required(results.results_list), name='results'),
    url(r'^results/add/$', login_required(results.results_add), name='results_add'),
    url(r'^results/(?P<rid>\d+)?/edit', login_required(results.results_edit),
        name='results_edit'),
    url(r'^results/(?P<rid>\d+)/delete', login_required(results.results_delete),
        name='results_delete'),
    url(r'^results/(?P<rid>\d+)/list', login_required(results.exam_results),
        name='exam_results'),

    # Logs urls
Example #7
0
    url(r'^groups/add/$', login_required(GroupAddView.as_view()),
        name='groups_add'),
    url(r'^groups/(?P<pk>\d+)/edit/$',
        login_required(GroupUpdateView.as_view()),
        name='groups_edit'),
    url(r'^groups/(?P<pk>\d+)/delete/$',
        login_required(GroupDeleteView.as_view()),
        name='groups_delete'),

    # Exams urls
    url(r'^exams/$', 'students.views.exams.exams_list',
        name='exams'),
    url(r'^exams/add/$', login_required(ExamAddView.as_view()),
        name='exams_add'),
    url(r'^exams/(?P<pk>\d+)/edit/$', login_required(
        ExamUpdateView.as_view()),
        name='exams_edit'),
    url(r'^exams/(?P<pk>\d+)/delete/$', login_required(
        ExamDeleteView.as_view()),
        name='exams_delete'),

    # Results urls
    url(r'^exams/results/$', login_required(exams_results),
        name='results'),
    url(r'^exams/results/add/$', login_required(
        ResultAddView.as_view()),
        name='results_add'),
    url(r'^exams/results/(?P<pk>\d+)/edit/$', login_required(
        ResultUpdateView.as_view()),
        name='results_edit'),
    url(r'^exams/results/(?P<pk>\d+)/delete/$', login_required(