51 lines
961 B
Python
51 lines
961 B
Python
from django.urls import path
|
|
|
|
from . import views
|
|
|
|
from .views import (
|
|
CreateCategory,
|
|
ViewCategory,
|
|
DeleteCategory,
|
|
EditCategory,
|
|
DeleteContent,
|
|
)
|
|
|
|
app_name = 'content'
|
|
urlpatterns = [
|
|
path(
|
|
'category/delete/<int:pk>',
|
|
DeleteCategory.as_view(),
|
|
name='category-delete'
|
|
),
|
|
path(
|
|
'category/new/',
|
|
CreateCategory.as_view(),
|
|
name='category-new'
|
|
),
|
|
path(
|
|
'category/<int:pk>',
|
|
ViewCategory.as_view(),
|
|
name='category',
|
|
),
|
|
path(
|
|
'category/<int:pk>/edit',
|
|
EditCategory.as_view(),
|
|
name='category-edit',
|
|
),
|
|
path(
|
|
'new/<int:school_pk>',
|
|
views.create_content,
|
|
name='content-new',
|
|
),
|
|
path(
|
|
'<int:pk>/delete',
|
|
DeleteContent.as_view(),
|
|
name="content-delete",
|
|
),
|
|
path(
|
|
'<int:pk>/edit',
|
|
views.edit_content,
|
|
name="content-edit",
|
|
),
|
|
|
|
]
|