Esempio n. 1
0
urlpatterns = [
    path('', HomeView.as_view(), name='home'),
    
    path('about/', AboutView.as_view(), name='about'),
    path('contact/', ContactView.as_view(), name='contact'),
    path('error/', ErrorView.as_view(), name='error'),

    path('adaptive/', views.AdaptiveDetailView, name='adaptive'),
    path('takequiz/', views.AdaptiveQuizDetailView, name='takequiz'),

    url(r'^play/$', views.play, name='play'),
    url(r'^leaderboard/$', views.leaderboard, name='leaderboard'),
    url(r'^submission-result/(?P<attempted_question_pk>\d+)/', views.submission_result, name='submission_result'),

    path('courses/<int:category>', CourseListView, name='course_list'),
    path('courses/<slug>/', login_required(CourseDetailView.as_view()),
         name='course_detail'),
    path('courses/<course_slug>/<lesson_slug>/',
         login_required(LessonDetailView.as_view()), name='lesson_detail'),
    #path('search/', SearchView, name='search_course'),
    path('search/', SearchView, name='search_course'),
    path('create/klasa', create_class, name='create_class'),  # Create / class
    path('create/subject', create_subject, name='create_subject'),  # Create / subject
    path('create/lesson', create_lesson, name='create_lesson'),
    path('profile/', Profile, name='profile'),
    path('kerkesa/', kerkesa, name='kerkesa'),

    url(r'^category/$',
        view=CategoriesListView.as_view(),
        name='category'),
Esempio n. 2
0
from django.urls import path

from courses.views import CourseListView, CourseDetailView, LessonView

urlpatterns = [
    path('', CourseListView.as_view(), name='course'),
    path('detail/<int:pk>', CourseDetailView.as_view(), name='detail'),
    path('lesson/<int:pk>', LessonView.as_view(), name='lesson'),
]
Esempio n. 3
0
# encoding: utf-8
__author__ = 'mtianyan'
__date__ = '2018/1/13 0013 01:57'

# encoding: utf-8
from courses.views import CourseListView, CourseDetailView, CourseInfoView, CommentsView, AddCommentsView, VideoPlayView
from django.urls import path, re_path

app_name = "courses"
urlpatterns = [
    # 课程列表url
    path('list/', CourseListView.as_view(), name="list"),
    # 课程详情页
    re_path('detail/(?P<course_id>\d+)/', CourseDetailView.as_view(), name="course_detail"),
    # 课程章节信息页
    re_path('info/(?P<course_id>\d+)/', CourseInfoView.as_view(), name="course_info"),

# 课程章节信息页
    re_path('comments/(?P<course_id>\d+)/', CommentsView.as_view(), name="course_comments"),

    # 添加课程评论,已经把参数放到post当中了
    path('add_comment/', AddCommentsView.as_view(), name="add_comment"),

    # 课程视频播放页
    re_path('video/(?P<video_id>\d+)/', VideoPlayView.as_view(), name="video_play"),
]
Esempio n. 4
0
# encoding: utf-8
__author__ = 'mtianyan'
__date__ = '2018/1/13 0013 01:57'

# encoding: utf-8
from courses.views import CourseListView, CourseDetailView, CourseInfoView, CommentsView, AddCommentsView, \
    VideoPlayView
from django.urls import path, re_path

app_name = "courses"
urlpatterns = [
    # 课程列表url
    path('list/', CourseListView.as_view(), name="list"),
    # 课程详情页
    re_path('detail/(?P<course_id>\d+)/', CourseDetailView.as_view(), name="course_detail"),
    # 课程章节信息页
    re_path('info/(?P<course_id>\d+)/', CourseInfoView.as_view(), name="course_info"),

    # 课程章节信息页
    re_path('comments/(?P<course_id>\d+)/', CommentsView.as_view(), name="course_comments"),

    # 添加课程评论,已经把参数放到post当中了
    path('add_comment/', AddCommentsView.as_view(), name="add_comment"),

    # 课程视频播放页
    re_path('video/(?P<video_id>\d+)/', VideoPlayView.as_view(), name="video_play"),
]
Esempio n. 5
0
__author__ = 'Administrator'

from django.urls import path
from courses.views import CourseListView, CourseDetailView

app_name = 'courses'
urlpatterns = [
    path('list/', CourseListView.as_view(), name='course_list'),
    path('detail/<int:course_id>/', CourseDetailView.as_view(), name='course_detail'),
]

Esempio n. 6
0
from django.urls import path

from courses.views import CourseListView, CourseDetailView, LessonDetailView

app_name = "courses"

urlpatterns = [
    path('', CourseListView.as_view(), name='list'),
    path('<slug>', CourseDetailView.as_view(), name='detail'),
    path('<course_slug>/<lesson_slug>',
         LessonDetailView.as_view(),
         name='lesson-detail'),
]
Esempio n. 7
0
         name='course_module_update'),
    path('module/<int:module_id>/content/<model_name>/create/',
         ContentCreateUpdateView.as_view(),
         name='module_content_create'),
    path('module/<int:module_id>/content/<model_name>/<id>/',
         ContentCreateUpdateView.as_view(),
         name='module_content_update'),
    path('content/<int:id>/delete/',
         ContentDeleteView.as_view(),
         name='module_content_delete'),
    path('module/<int:module_id>/',
         ModuleContentListView.as_view(),
         name='module_content_list'),
    path('module/order/', ModuleOrderView.as_view(), name='module_order'),
    path('content/order/', ContentOrderView.as_view(), name='content_order'),
    path('subject/<slug:subject>/',
         CourseListView.as_view(),
         name='course_list_subject'),
    path('subject/', CourseListView.as_view(), name='course_list_subject'),
    path('courses/',
         StudentCourseListView.as_view(),
         name='student_course_list'),
    path('<slug:slug>/', CourseDetailView.as_view(), name='course_detail'),
    path('course/<pk>/',
         StudentCourseDetailView.as_view(),
         name='student_course_detail'),
    path('course/<pk>/<module_id>/',
         StudentCourseDetailView.as_view(),
         name='student_course_detail_module'),
]
Esempio n. 8
0
from django.conf.urls import patterns, include, url
from courses.models import Course
from courses.views import add_lesson
from courses.views import CourseDetailView, CourseCreateView, CourseUpdateView, CourseDeleteView


urlpatterns = patterns('',
    url(r'^(?P<pk>\d+)/$', CourseDetailView.as_view(), name='detail'),
    url(r'^add/$', CourseCreateView.as_view(), name='add'),
    url(r'^edit/(?P<pk>\d+)/$', CourseUpdateView.as_view(), name='edit'),
    url(r'^remove/(?P<pk>\d+)/$', CourseDeleteView.as_view(), name='remove'),
    url(r'^(?P<id_of_course>\d+)/add_lesson$', add_lesson, name='add-lesson'),
)
Esempio n. 9
0
from courses.views import CourseListView, CourseCreateView, CourseDetailView, CourseUpdateView, CourseDeleteView, \
    MessageView
from django.urls import path

app_name = 'courses'

urlpatterns = [
    path('', CourseListView.as_view(), name='list'),
    path('course/add/', CourseCreateView.as_view(), name='create'),
    path('course/<int:pk>/update/', CourseUpdateView.as_view(), name='update'),
    path('course/<int:pk>/delete/', CourseDeleteView.as_view(), name='delete'),
    path('course/<int:pk>/', CourseDetailView.as_view(), name='view'),
    path('message', MessageView.as_view(), name='send_message'),
]
Esempio n. 10
0
from django.conf.urls import patterns, include, url
from courses.models import Course
from courses.views import add_lesson
from courses.views import CourseDetailView, CourseCreateView, CourseUpdateView, CourseDeleteView

urlpatterns = patterns(
    '',
    url(r'^(?P<pk>\d+)/$', CourseDetailView.as_view(), name='detail'),
    url(r'^add/$', CourseCreateView.as_view(), name='add'),
    url(r'^edit/(?P<pk>\d+)/$', CourseUpdateView.as_view(), name='edit'),
    url(r'^remove/(?P<pk>\d+)/$', CourseDeleteView.as_view(), name='remove'),
    url(r'^(?P<id_of_course>\d+)/add_lesson$', add_lesson, name='add-lesson'),
)
Esempio n. 11
0
from django.urls import path
from django.conf.urls.static import static
from django.conf import settings

from courses.views import CourseView, CourseDetailView, CourseVideoView

app_name = "courses"
urlpatterns = [
    path('', CourseView.as_view(), name='course_list'),
    path('detail/<int:course_id>', CourseDetailView.as_view(), name='course_detail'),
    path('detail/<int:course_id>/video/', CourseVideoView.as_view(), name='course_video'),
]+ static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
Esempio n. 12
0
from django.contrib import admin
from django.urls import path

from courses.views import (CourseDetailView, CourseListView, CourseCreateView,
                           CourseUpdateView, CourseDeleteView)

app_name = 'courses'
urlpatterns = [
    path('<int:id>/', CourseDetailView.as_view(), name='course-detail'),
    path('', CourseListView.as_view(), name='course-list'),
    path('create/', CourseCreateView.as_view(), name='course-create'),
    path('<int:id>/update/', CourseUpdateView.as_view(), name='course-update'),
    path('<int:id>/delete/', CourseDeleteView.as_view(), name='course-delete')
]
Esempio n. 13
0
from django.urls import re_path, path
from courses.views import CourseListView, CourseDetailView, CourseLessonView, CourseCommentsView, VideoView

urlpatterns = [
    re_path(r"^list/$", CourseListView.as_view(), name="list"),
    path("<int:course_id>/", CourseDetailView.as_view(), name="detail"),
    path("<int:course_id>/lesson/", CourseLessonView.as_view(), name="lesson"),
    path("<int:course_id>/comments/",
         CourseCommentsView.as_view(),
         name="comments"),
    path("<int:course_id>/video/<int:video_id>/",
         VideoView.as_view(),
         name="video"),
]
Esempio n. 14
0
        success_url=reverse_lazy('golfstats-courses-baskets'),
    ), name="golfstats-courses-baskets-delete"),

    # Course
    url(r'^courses/$', ListView.as_view(
        model=Course,
        context_object_name="courses",
    ), name="golfstats-courses-courses"),

    url(r'^courses/create/$', CreateView.as_view(
        model=Course,
        success_url=reverse_lazy('golfstats-courses-courses'),
    ), name="golfstats-courses-course-create"),

    url(r'^courses/(?P<pk>\d+)/$', CourseDetailView.as_view(
        model=Course,
        context_object_name="course",
    ), name="golfstats-courses-course-detail"),

    url(r'^courses/(?P<pk>\d+)/edit/', UpdateView.as_view(
        model=Course,
        context_object_name="course",
        success_url=reverse_lazy('golfstats-courses-courses'),
    ), name="golfstats-courses-course-edit"),

    url(r'^courses/(?P<pk>\d+)/delete/$', DeleteView.as_view(
        model=Course,
        context_object_name="course",
        success_url=reverse_lazy('golfstats-courses-courses'),
    ), name="golfstats-courses-course-delete"),

    # Coursehole
Esempio n. 15
0
# *_* coding:utf-8 _*_
__auth__ = 'psj'
__date__ = '2018/6/14 15:27'

from courses.views import CourseListView, CourseDetailView, CourseInfoView, CommentsView, AddCommentsView, VideoPlayView


from django.conf.urls import url

urlpatterns = [
    # 课程列表url
    url(r'^list/$', CourseListView.as_view(), name="course_list"),
    # 课程详情页
    url(r'^course/(?P<course_id>\d+)/$', CourseDetailView.as_view(), name="course_detail"),

    # 课程章节信息页
    url(r'^info/(?P<course_id>\d+)/$', CourseInfoView.as_view(), name="course_info"),

    # 课程评论页
    url(r'^comments/(?P<course_id>\d+)/$', CommentsView.as_view(), name="course_comments"),

    # 添加课程评论,已经把参数放到post当中了
    url('add_comment/', AddCommentsView.as_view(), name="add_comment"),

    # 课程视频播放页
    url(r'^video/(?P<video_id>\d+)/$', VideoPlayView.as_view(), name="video_play"),


]

Esempio n. 16
0
from django.contrib.auth.decorators import login_required
from django.urls import path

from courses.views import HomeView, AboutView, ContactView, CourseListView, CourseDetailView, LessonDetailView, \
    SearchView, krijo_klase, krijo_lende, krijo_mesim

app_name = 'courses'

urlpatterns = [
    path('', HomeView.as_view(), name='home'),
    path('about/', AboutView.as_view(), name='about'),
    path('contact/', ContactView.as_view(), name='contact'),
    path('courses/<int:category>', CourseListView, name='course_list'),
    path('courses/<slug>/',
         login_required(CourseDetailView.as_view()),
         name='course_detail'),
    path('courses/<course_slug>/<lesson_slug>/',
         login_required(LessonDetailView.as_view()),
         name='lesson_detail'),
    path('search/', SearchView, name='kerko_kurs'),
    path('krijo/klase', krijo_klase, name='krijo_klase'),
    path('krijo/lende', krijo_lende, name='krijo_lende'),
    path('krijo/mesim', krijo_mesim, name='krijo_mesim')
]
Esempio n. 17
0
# coding:utf-8
from courses.views import CourseListView, CourseDetailView, CourseVideoView, CourseCommentView, AddComment

__author__ = 'nina'
__date__ = '2018/1/17 14:14'

from django.conf.urls import url

urlpatterns = [
    url(r'^list/$', CourseListView.as_view(), name='courselist'),
    url(r'^detail/(?P<course_id>\d+)/$', CourseDetailView.as_view(), name='coursedetail'),
    url(r'^video/(?P<course_id>\d+)/$', CourseVideoView.as_view(), name='video'),
    url(r'^comment/(?P<course_id>\d+)/$', CourseCommentView.as_view(), name='comment'),
    url(r'^addcomment/$', AddComment.as_view(), name='addcomment'),
]
Esempio n. 18
0
File: urls.py Progetto: vlctt/YDX
# _*_ encoding:utf-8 _*_
from django.conf.urls import url
from courses.views import CourseProgessView, SearchView, FightDetailView, CourseListView, CourseDetailView, AddFavoriteView, VideoPlayView, CommentsView, AddCommentsView
__author__ = 'YZF'
__date__ = '2018/3/26,9:09'
urlpatterns = [
    url(r'^list', CourseListView.as_view(), name="courser_list"),
    url(r'^detail/(?P<course_id>\d+)/',
        CourseDetailView.as_view(),
        name='course_detail'),
    url(r'^fightdetail/(?P<course_id>\d+)/',
        FightDetailView.as_view(),
        name='fight_detail'),
    url(r'^addfav/', AddFavoriteView.as_view(), name="addfav_course"),
    url(r'^video/(?P<video_id>\d+)/', VideoPlayView.as_view(), name="video"),
    url(r'^progess/', CourseProgessView.as_view(), name="progess"),
    url(r'^comments/(?P<course_id>\d+)/',
        CommentsView.as_view(),
        name="comments"),
    url(r'^addcomments/', AddCommentsView.as_view(), name="addcomments"),
    url(r'^search/', SearchView.as_view(), name="search"),
]
Esempio n. 19
0
from courses.views import (
    CourseListView,
    CourseDetailView,
    ChapterDetailView,
    CourseCreateView,
    CoursePurchaseRedirectView,
)

from django.urls import re_path

app_name = 'courses'

urlpatterns = [
    re_path(r'^$', CourseListView.as_view(), name='list'),
    re_path(r'create/$', CourseCreateView.as_view(), name='create'),
    re_path(r'^(?P<slug>\w.+)/$',
            ChapterDetailView.as_view(),
            name='chapter_detail'),  #need a lecture slug
    re_path(r'(?P<slug>\w.+)/purchase$',
            CoursePurchaseRedirectView.as_view(),
            name='purchase'),
    re_path(r'(?P<slug>\w.+)$', CourseDetailView.as_view(), name='detail'),
]

#trail
# re_path(r'^(?P<slug>\w.+)$', CourseDetailView.as_view(), name='detail'),
# re_path(r'(?P<pk>\d+)$',ChapterDetailView.as_view(),name='chapter_detail'),
# re_path(r'^(?P<course_slug>\w.+)/(?P<slug>\w.+)$',
#                      ChapterDetailView.as_view(),name='chapter_detail'),