site_tps/content/urls.py

52 lines
961 B
Python
Raw Normal View History

2018-01-24 10:33:05 +00:00
from django.urls import path
2018-03-09 12:18:03 +00:00
from . import views
from .views import (
CreateCategory,
ViewCategory,
2018-01-30 21:47:47 +00:00
DeleteCategory,
2018-01-30 22:04:06 +00:00
EditCategory,
2018-02-28 20:25:44 +00:00
DeleteContent,
)
2018-01-24 10:33:05 +00:00
2018-01-24 10:44:54 +00:00
app_name = 'content'
2018-01-24 10:33:05 +00:00
urlpatterns = [
2018-01-30 21:47:47 +00:00
path(
'category/delete/<int:pk>',
DeleteCategory.as_view(),
name='category-delete'
),
path(
'category/new/',
CreateCategory.as_view(),
name='category-new'
),
2018-01-30 22:04:06 +00:00
path(
'category/<int:pk>',
ViewCategory.as_view(),
name='category',
),
path(
'category/<int:pk>/edit',
2018-01-30 22:04:06 +00:00
EditCategory.as_view(),
name='category-edit',
2018-02-28 20:25:44 +00:00
),
path(
2018-03-09 12:18:03 +00:00
'new/<int:school_pk>',
views.create_content,
2018-02-28 20:25:44 +00:00
name='content-new',
),
path(
'<int:pk>/delete',
DeleteContent.as_view(),
name="content-delete",
),
path(
'<int:pk>/edit',
2018-03-10 08:28:50 +00:00
views.edit_content,
2018-02-28 20:25:44 +00:00
name="content-edit",
),
2018-01-24 10:33:05 +00:00
]