Remove direct reservation management from web interface

PROBLEM:
Direct deletion/creation of reservations via web interface bypassed
POS business logic, creating data inconsistencies (orphaned showcase kits,
incorrect stock calculations).

SOLUTION:
Make reservations read-only in web interface. All reservation management
now happens only through:
- POS (showcase kits)
- Orders module

CHANGES:
- Remove reservation-create and reservation-update URL routes
- Delete ReservationCreateView and ReservationUpdateView
- Remove ReservationForm (no longer needed)
- Delete reservation_form.html and reservation_update.html templates
- Update reservation_list.html to read-only view with info banner
- Add showcase and order columns to reservation list
- Clean up imports in urls.py and views/__init__.py

Reservations are now read-only for monitoring purposes only.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
2025-11-20 13:17:04 +03:00
parent cd037e8f6b
commit 82261cbba7
7 changed files with 123 additions and 69 deletions

View File

@@ -16,7 +16,7 @@ from .views import (
# Transfer
TransferListView, TransferBulkCreateView, TransferDetailView, TransferDeleteView, GetProductStockView,
# Reservation
ReservationListView, ReservationCreateView, ReservationUpdateView,
ReservationListView,
# Stock
StockListView, StockDetailView,
# StockBatch
@@ -79,10 +79,8 @@ urlpatterns = [
path('transfers/<int:pk>/delete/', TransferDeleteView.as_view(), name='transfer-delete'),
path('api/product-stock/', GetProductStockView.as_view(), name='api-product-stock'), # API для получения количества товара
# ==================== RESERVATION ====================
# ==================== RESERVATION (READ ONLY) ====================
path('reservations/', ReservationListView.as_view(), name='reservation-list'),
path('reservations/create/', ReservationCreateView.as_view(), name='reservation-create'),
path('reservations/<int:pk>/update-status/', ReservationUpdateView.as_view(), name='reservation-update'),
# ==================== STOCK (READ ONLY) ====================
path('stock/', StockListView.as_view(), name='stock-list'),