frogress/frog_api/urls.py

34 lines
866 B
Python
Raw Normal View History

2022-08-21 11:25:44 +00:00
from django.urls import path, re_path
from frog_api.views import data, structure
2022-08-19 10:35:05 +00:00
urlpatterns = [
# structure (/project)
path(
"projects/",
structure.ProjectStructureView.as_view(),
),
re_path(
"projects/(?P<project_slug>.+)/(?P<version_slug>.+)/$",
structure.CategoryStructureView.as_view(),
name="category-structure",
),
# data (/data)
2022-08-24 01:58:55 +00:00
re_path(
"data/(?P<project_slug>.+)/(?P<version_slug>.+)/(?P<category_slug>.+)/$",
data.CategoryDataView.as_view(),
2022-08-24 01:58:55 +00:00
),
2022-08-22 08:54:38 +00:00
re_path(
"data/(?P<project_slug>.+)/(?P<version_slug>.+)/$",
data.VersionDataView.as_view(),
name="version-data",
2022-08-21 11:25:44 +00:00
),
re_path(
"data/(?P<project_slug>.+)/$",
data.ProjectDataView.as_view(),
2022-08-21 11:25:44 +00:00
),
2022-08-22 08:54:38 +00:00
path(
"data/",
data.RootDataView.as_view(),
2022-08-22 08:54:38 +00:00
),
2022-08-19 10:35:05 +00:00
]