aboutsummaryrefslogtreecommitdiffstats
path: root/ctrack/caf/urls.py
blob: 557c2f0515b9d71f3c2874a63391cf5f045cff31 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
from django.urls import path
from django.views.decorators.cache import cache_page

from ctrack.caf.views import (
    ListCAF,
    ListApplicableSystem,
    caf_detail_view,
    ApplicableSystemDetail,
    ApplicableSystemCreateFromOrg,
    applicable_system_create_from_caf,
)

app_name = "caf"

urlpatterns = [
    path("", view=ListCAF.as_view(), name="caf_list"),
    path(
        "applicablesystems",
        cache_page(60 * 60)(ListApplicableSystem.as_view()),
        name="es_list",
    ),
    path(
        "applicablesystems/<int:pk>",
        ApplicableSystemDetail.as_view(),
        name="ass_detail",
    ),
    path(
        "applicablesystem/<slug:slug>",
        ApplicableSystemCreateFromOrg.as_view(),
        name="as_create_from_org",
    ),
    path(
        "applicablesystem/create-from-caf/<int:caf_id>",
        applicable_system_create_from_caf,
        name="as_create_from_caf",
    ),
    path("<int:pk>", caf_detail_view, name="detail"),
]