feat(backend,waiter,manager): prices changed by hand are on the record

Owner 2026-11-23 (plan 6F.3). services/price_changes.py: the venue's switch orders.price_change
(off | before_sending | anytime, default anytime as before), orders.price_change_reason and its
quick reasons; keys ordering.prices.modify (the cart), new modify_sent (a sent or served line) and
view_changes (who sees them). Every by-hand price (waiter cart, a sent line, the counter's %
discount) writes a manual_price PriceEventLog row (before, after, quantity, who, approving manager,
stage, reason) plus a PRICE_CHANGED audit row; before, the sent-line change overwrote the price with
no record. Alembic 0047: event columns; modify_sent for everyone holding modify (and the venues'
role overrides), view_changes for owners and store managers.
Waiter: the reason picker when the venue asks, a sent line's price on modify_sent and the venue's
switch, the line's price history. Manager: Settings -> Operation 'Prices changed by hand', the
changes on the order's lines and history, Reports -> Cancellations, discounts and price changes
(+ export). Counter: no discount when the venue turned price changes off.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-23 07:41:43 +02:00
co-authored by Claude Opus 5.5
parent e3f4f3eeee
commit f87f9ff23c
40 changed files with 1044 additions and 73 deletions
+24 -1
View File
@@ -528,7 +528,8 @@
"merge": "Σφάλμα συγχώνευσης",
"moveItems": "Σφάλμα μεταφοράς αντικειμένων",
"flags": "Σφάλμα αποθήκευσης σημαιών",
"combine": "Σφάλμα συνδυασμού"
"combine": "Σφάλμα συνδυασμού",
"price": "Η τιμή δεν άλλαξε."
},
"openOrder": "Άνοιγμα Παραγγελίας",
"noPaid": "Δεν υπάρχουν πληρωμένα αντικείμενα",
@@ -857,5 +858,27 @@
"accepted": "Στάλθηκε στην κουζίνα",
"declined": "Απορρίφθηκε",
"note": "Σημείωση: {{note}}"
},
"price": {
"reason": "Γιατί αλλάζει η τιμή;",
"reasonMissing": "Γράψτε γιατί αλλάζει η τιμή",
"reasons": {
"regular": "Τακτικός πελάτης",
"mistake": "Λάθος τιμή στο μενού",
"compensation": "Αποζημίωση για πρόβλημα",
"manager": "Απόφαση υπευθύνου",
"happyHour": "Προσφορά ημέρας",
"other": "Άλλο"
},
"history": "Ιστορικό τιμής",
"historySub": "Ποιος την άλλαξε, πότε και γιατί",
"historyNone": "Καμία αλλαγή τιμής σε αυτή τη γραμμή.",
"historyFailed": "Το ιστορικό τιμής δεν φόρτωσε.",
"stage": {
"cart": "πριν την αποστολή",
"sent": "μετά την αποστολή",
"served": "μετά το σερβίρισμα"
},
"approvedBy": "με έγκριση {{name}}"
}
}