diff options
Diffstat (limited to 'yaksh/urls.py')
-rw-r--r-- | yaksh/urls.py | 33 |
1 files changed, 16 insertions, 17 deletions
diff --git a/yaksh/urls.py b/yaksh/urls.py index d7b56e4..7a41f95 100644 --- a/yaksh/urls.py +++ b/yaksh/urls.py @@ -4,6 +4,7 @@ from django.contrib.auth.views import password_reset, password_reset_confirm,\ password_reset_done, password_reset_complete, password_change,\ password_change_done +# app_name = 'yaksh' urlpatterns = [ url(r'^forgotpassword/$', password_reset, name="password_reset"), url(r'^password_reset/(?P<uidb64>[0-9A-Za-z]+)-(?P<token>.+)/$', @@ -19,8 +20,8 @@ urlpatterns = [ ] urlpatterns += [ url(r'^$', views.index), - url(r'^login/$', views.user_login), - url(r'^quizzes/$', views.quizlist_user), + url(r'^login/$', views.user_login, name='login'), + url(r'^quizzes/$', views.quizlist_user, name='quizlist_user'), url(r'^results/$', views.results_user), url(r'^start/$', views.start), url(r'^start/(?P<questionpaper_id>\d+)/$', views.start), @@ -37,13 +38,13 @@ urlpatterns += [ views.skip), url(r'^(?P<q_id>\d+)/skip/(?P<next_q>\d+)/(?P<attempt_num>\d+)/(?P<questionpaper_id>\d+)/$', views.skip), - url(r'^enroll_request/(?P<course_id>\d+)/$', views.enroll_request), - url(r'^self_enroll/(?P<course_id>\d+)/$', views.self_enroll), - url(r'^manage/$', views.prof_manage), + url(r'^enroll_request/(?P<course_id>\d+)/$', views.enroll_request, name='enroll_request'), + url(r'^self_enroll/(?P<course_id>\d+)/$', views.self_enroll, name='self_enroll'), + url(r'^manage/$', views.prof_manage, name='manage'), url(r'^manage/addquestion/$', views.add_question), url(r'^manage/addquestion/(?P<question_id>\d+)/$', views.edit_question), - url(r'^manage/addquiz/$', views.add_quiz), - url(r'^manage/addquiz/(?P<quiz_id>\d+)/$', views.add_quiz), + url(r'^manage/addquiz/$', views.add_quiz, name='add_quiz'), + url(r'^manage/addquiz/(?P<quiz_id>\d+)/$', views.add_quiz, name='edit_quiz'), url(r'^manage/gradeuser/$', views.grade_user), url(r'^manage/gradeuser/(?P<quiz_id>\d+)/$',views.grade_user), url(r'^manage/gradeuser/(?P<quiz_id>\d+)/(?P<user_id>\d+)/$',views.grade_user), @@ -57,7 +58,7 @@ urlpatterns += [ url(r'^manage/user_data/(?P<user_id>\d+)/(?P<questionpaper_id>\d+)/$', views.user_data), url(r'^manage/user_data/(?P<user_id>\d+)/$', views.user_data), - url(r'^manage/designquestionpaper/$', views.design_questionpaper), + url(r'^manage/designquestionpaper/$', views.design_questionpaper, name='design_questionpaper'), url(r'^manage/designquestionpaper/(?P<questionpaper_id>\d+)/$',\ views.design_questionpaper), url(r'^manage/statistics/question/(?P<questionpaper_id>\d+)/$', @@ -66,9 +67,9 @@ urlpatterns += [ views.show_statistics), url(r'^manage/monitor/download_csv/(?P<questionpaper_id>\d+)/$', views.download_csv), - url(r'manage/courses/$', views.courses), - url(r'manage/add_course/$', views.add_course), - url(r'manage/course_detail/(?P<course_id>\d+)/$', views.course_detail), + url(r'manage/courses/$', views.courses, name='courses'), + url(r'manage/add_course/$', views.add_course, name='add_course'), + url(r'manage/course_detail/(?P<course_id>\d+)/$', views.course_detail, name='course_detail'), url(r'manage/enroll/(?P<course_id>\d+)/(?P<user_id>\d+)/$', views.enroll), url(r'manage/enroll/rejected/(?P<course_id>\d+)/(?P<user_id>\d+)/$', views.enroll, {'was_rejected': True}), @@ -78,20 +79,18 @@ urlpatterns += [ url(r'manage/toggle_status/(?P<course_id>\d+)/$', views.toggle_course_status), url(r'^ajax/questionpaper/(?P<query>.+)/$', views.ajax_questionpaper), url(r'^ajax/questions/filter/$', views.ajax_questions_filter), - url(r'^editprofile/$', views.edit_profile), - url(r'^viewprofile/$', views.view_profile), + url(r'^editprofile/$', views.edit_profile, name='edit_profile'), + url(r'^viewprofile/$', views.view_profile, name='view_profile'), url(r'^manage/enroll/(?P<course_id>\d+)/$', views.enroll), url(r'manage/enroll/rejected/(?P<course_id>\d+)/$', views.enroll, {'was_rejected': True}), url(r'manage/enrolled/reject/(?P<course_id>\d+)/$', views.reject, {'was_enrolled': True}), url(r'^manage/searchteacher/(?P<course_id>\d+)/$', views.search_teacher), - url(r'^manage/addteacher/(?P<course_id>\d+)/$', views.add_teacher), + url(r'^manage/addteacher/(?P<course_id>\d+)/$', views.add_teacher, name='add_teacher'), url(r'^manage/allotted_course/$', views.allotted_courses), - url(r'^manage/remove_teachers/(?P<course_id>\d+)/$', views.remove_teachers), + url(r'^manage/remove_teachers/(?P<course_id>\d+)/$', views.remove_teachers, name='remove_teacher'), url(r'^manage/download_questions/$', views.show_all_questions), url(r'^manage/upload_questions/$', views.show_all_questions), url(r'^manage/(?P<mode>[\w\-]+)/(?P<quiz_id>\d+)/$', views.test_quiz) ] - - |