"""Back-office routes."""

from django.urls import path

from ..views import backoffice as views

app_name = "backoffice"

urlpatterns = [
    path("", views.index, name="index"),
    path("create/", views.create, name="create"),
    path("<int:pk>/edit/", views.edit, name="edit"),
    path("<int:pk>/delete/", views.delete, name="delete"),
    path("<int:pk>/manage/", views.manage, name="manage"),
    path("<int:pk>/manage/stockroom/add/", views.add_stockroom, name="add_stockroom"),
    path("<int:pk>/manage/stockroom/<int:source_id>/edit/", views.edit_stockroom, name="edit_stockroom"),
    path("<int:pk>/manage/stockroom/<int:source_id>/remove/", views.remove_stockroom, name="remove_stockroom"),
    path("<int:pk>/manage/hull/add/", views.add_hull, name="add_hull"),
    path("<int:pk>/manage/hull/<int:listing_id>/edit/", views.edit_hull, name="edit_hull"),
    path("<int:pk>/manage/hull/<int:listing_id>/remove/", views.remove_hull, name="remove_hull"),
    path("<int:pk>/manage/hull/<int:listing_id>/star/", views.toggle_featured, name="toggle_featured"),
]
