refactor(backend): drop the legacy products.printer_zone_id and its print fallbacks

Routing has been by prep zone only since v1, which nulled this column on every start, so the four fallbacks in printer_service.py never ran. Revision 0012 drops the column (its unnamed FK goes with the batch rebuild). The unused legacy GET /api/kds/items keeps its single 'no zone' group. Product create/update/export/import no longer mention it. Scheduled in plan step 1.0 for the catalogue rework (1.13).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-13 12:28:13 +02:00
co-authored by Claude Opus 5.5
parent 82c6ca4e0a
commit 3c5751025c
8 changed files with 37 additions and 57 deletions
-2
View File
@@ -360,8 +360,6 @@ def update_product(product_id: int, body: ProductUpdate, db: Session = Depends(g
)
for field, value in scalar_fields.items():
setattr(product, field, value)
# Always clear legacy per-product printer — routing is now via prep zones only
product.printer_zone_id = None
# Update prep zones if provided
if body.prep_zone_ids is not None:
zones = db.query(PrepZone).filter(PrepZone.id.in_(body.prep_zone_ids)).all()