feat(backend,waiter,manager): moves between tables and orders on the record

Owner 2026-11-23 (plan 6F.4). services/moves.py: every table transfer, lines moved and orders merged
is an order_moves row with its lines (order_move_items: line, quantity then); OrderItem.split_from_id
links a split part to its line, so a part carries the moves made before the split; combining moves
the removed lines' moves to the kept one. Alembic 0048: the tables, the column, and a backfill from
the audit notes written before (note='backfill'). A split part now also keeps the line's price change,
kitchen state, course, cost and names (it used to restart as pending at the menu price).
GET /api/orders/{id}/moves (the order's path, each line's); GET /api/reports/moves (+ export).
Waiter: a moved order's banner (T2 -> T5), moved lines marked, a line's Move history. Manager: the
order's Moves tab, each moved line's path, Reports -> Moves.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-23 08:03:11 +02:00
co-authored by Claude Opus 5.5
parent f87f9ff23c
commit 0a353c5f97
27 changed files with 903 additions and 18 deletions
+34 -3
View File
@@ -50,7 +50,8 @@
"media": "Media",
"signage": "Signage",
"main": "Main menu",
"scenes": "Scenes"
"scenes": "Scenes",
"reportsMoves": "Moves"
},
"profile": {
"edit": "Edit profile",
@@ -3286,7 +3287,8 @@
"tabs": {
"order": "Order",
"prices": "Price changes",
"history": "History"
"history": "History",
"moves": "Moves"
},
"payAll": "Pay everything",
"close": "Close",
@@ -3454,7 +3456,19 @@
"saved": "Flags saved",
"sent": "Flags saved and message sent"
},
"printHelp": "Tickets are tried again every 8 seconds until they print. If a printer is off or out of paper, send them to another one, or mark them handled once the kitchen knows."
"printHelp": "Tickets are tried again every 8 seconds until they print. If a printer is off or out of paper, send them to another one, or mark them handled once the kitchen knows.",
"moves": {
"none": "Nothing moved on this order.",
"wholeOrder": "The whole order: {{path}}",
"linePath": "moved: {{path}}",
"lines_one": "{{count}} line",
"lines_other": "{{count}} lines",
"kind": {
"table_transfer": "Whole table",
"items_moved": "Lines moved",
"orders_merged": "Tables joined"
}
}
},
"printing": {
"back": "Back",
@@ -4195,6 +4209,23 @@
"dueDate": "Due by {{date}}",
"payments": "Payments",
"noPayments": "Nothing paid yet."
},
"moves": {
"title": "Moves between tables",
"kind": "What",
"from": "From",
"to": "To",
"lines": "Lines",
"by": "By",
"allKinds": "Every kind",
"count": "Moves",
"list": "Every move",
"listTip": "A whole table moved to a free one, lines moved to another table, or two tables joined. Each line keeps its moves wherever it ends up, even split or moved again.",
"kinds": {
"table_transfer": "Whole table",
"items_moved": "Lines moved",
"orders_merged": "Tables joined"
}
}
},
"finance": {
+16
View File
@@ -880,5 +880,21 @@
"served": "after serving"
},
"approvedBy": "approved by {{name}}"
},
"moves": {
"orderCame": "Moved here: {{path}}",
"details": "Details",
"orderTitle": "This order's moves",
"lineTitle": "Move history",
"lineSub": "The tables this line went through",
"lineMoved": "Moved here from another table",
"movedShort": "moved",
"lines_one": "{{count}} line",
"lines_other": "{{count}} lines",
"kind": {
"table_transfer": "Whole table",
"items_moved": "Lines moved",
"orders_merged": "Tables joined"
}
}
}