Complete Catalogs with code refactoring

This commit is contained in:
2024-12-22 18:53:47 +01:00
parent 64f616d89f
commit cbf6c942b9
10 changed files with 118 additions and 59 deletions

View File

@@ -14,9 +14,8 @@ from portal.views import (
Scales,
Types,
Books,
GetBook,
Catalogs,
GetCatalog,
GetBookCatalog,
SearchObjects,
)
@@ -99,7 +98,11 @@ urlpatterns = [
Books.as_view(template="bookshelf/books.html"),
name="books_pagination"
),
path("bookshelf/book/<uuid:uuid>", GetBook.as_view(), name="book"),
path(
"bookshelf/<str:selector>/<uuid:uuid>",
GetBookCatalog.as_view(),
name="bookshelf_item"
),
path(
"bookshelf/catalogs",
Catalogs.as_view(template="bookshelf/books.html"),
@@ -110,11 +113,6 @@ urlpatterns = [
Catalogs.as_view(template="bookshelf/books.html"),
name="catalogs_pagination"
),
path(
"bookshelf/catalog/<uuid:uuid>",
GetCatalog.as_view(),
name="catalog"
),
path(
"search",
SearchObjects.as_view(http_method_names=["post"]),