2023-03-15 22:32:33 +03:00
|
|
|
from django.urls import path
|
|
|
|
|
2023-03-27 16:15:03 +03:00
|
|
|
from akarpov.files.views import (
|
2023-04-24 15:26:59 +03:00
|
|
|
ChunkedUploadCompleteView,
|
|
|
|
ChunkedUploadView,
|
2023-04-06 14:41:10 +03:00
|
|
|
TopFolderView,
|
2023-04-13 00:54:44 +03:00
|
|
|
delete_file_view,
|
2023-04-26 13:47:02 +03:00
|
|
|
delete_folder_view,
|
2023-06-21 17:02:53 +03:00
|
|
|
file_download_view,
|
2023-04-24 15:26:59 +03:00
|
|
|
file_report_list,
|
2023-04-24 14:48:15 +03:00
|
|
|
file_table,
|
2023-04-15 12:02:37 +03:00
|
|
|
file_update,
|
2023-03-27 16:15:03 +03:00
|
|
|
files_view,
|
2023-04-24 14:48:15 +03:00
|
|
|
folder_create,
|
2023-04-26 13:47:02 +03:00
|
|
|
folder_update,
|
2023-03-27 16:15:03 +03:00
|
|
|
folder_view,
|
2023-04-24 15:26:59 +03:00
|
|
|
report_file,
|
2023-03-27 16:15:03 +03:00
|
|
|
)
|
2023-03-15 22:32:33 +03:00
|
|
|
|
|
|
|
app_name = "files"
|
|
|
|
urlpatterns = [
|
2023-04-06 14:41:10 +03:00
|
|
|
path("", TopFolderView.as_view(), name="main"),
|
2023-04-24 14:48:15 +03:00
|
|
|
path("table/", file_table, name="table"),
|
2023-04-24 15:26:59 +03:00
|
|
|
path("reports/", file_report_list, name="reports"),
|
2023-03-27 16:15:03 +03:00
|
|
|
path(
|
|
|
|
"api/chunked_upload_complete/",
|
2023-04-24 15:26:59 +03:00
|
|
|
ChunkedUploadCompleteView.as_view(),
|
2023-03-27 16:15:03 +03:00
|
|
|
name="api_chunked_upload_complete",
|
|
|
|
),
|
2023-04-24 01:07:11 +03:00
|
|
|
path(
|
|
|
|
"api/chunked_upload_complete/<str:slug>",
|
2023-04-24 15:26:59 +03:00
|
|
|
ChunkedUploadCompleteView.as_view(),
|
2023-04-24 01:07:11 +03:00
|
|
|
name="api_chunked_upload_complete_folder",
|
|
|
|
),
|
2023-04-24 15:26:59 +03:00
|
|
|
path("api/chunked_upload/", ChunkedUploadView.as_view(), name="api_chunked_upload"),
|
2023-04-24 14:48:15 +03:00
|
|
|
path("api/folder/create/", folder_create, name="folder_create"),
|
2023-04-24 15:26:59 +03:00
|
|
|
path("api/file/report/<str:slug>", report_file, name="file_report"),
|
2023-06-21 17:02:53 +03:00
|
|
|
path("api/file/download/<str:slug>", file_download_view, name="file_download"),
|
2023-04-26 13:47:02 +03:00
|
|
|
path("api/file/delete/<str:slug>", delete_file_view, name="delete"),
|
2023-04-24 14:48:15 +03:00
|
|
|
path("api/folder/create/<str:slug>", folder_create, name="sub_folder_create"),
|
2023-04-26 13:47:02 +03:00
|
|
|
path("api/folder/delete/<str:slug>", delete_folder_view, name="folder_delete"),
|
2023-03-15 22:32:33 +03:00
|
|
|
path("<str:slug>", files_view, name="view"),
|
2023-04-15 12:02:37 +03:00
|
|
|
path("<str:slug>/update", file_update, name="update"),
|
2023-03-15 22:32:33 +03:00
|
|
|
path("f/<str:slug>", folder_view, name="folder"),
|
2023-04-26 13:47:02 +03:00
|
|
|
path("f/<str:slug>/update", folder_update, name="folder_update"),
|
2023-03-15 22:32:33 +03:00
|
|
|
]
|