feat(waiter): close with unpaid items as a setting, combine lines, seats (platform-v2 step 4.8a)

The owner's choices for 4.8 (2026-11-18), all configurable:
- Setting orders.close_with_unpaid (default off): when off, the server refuses to close
  an order with unpaid items (pos.order_unpaid) and the phone's CLOSE takes the payment
  first ("instant-pay close"); when on, CLOSE confirms and the items stay unpaid. Manager
  Settings → Operation, next to "auto-close after full payment" (unchanged).
- POST /api/orders/{id}/items/combine: unpaid lines of the same item (choices, note,
  price, course, kitchen state; no discount / deal / tab) become one line; the phone
  offers "Combine into one line" for selected lines or a grouped line. The grouping
  views (identical / same item) stay as they were.
- Seats: the table's seats next to its name on the cards (waiter Settings → Layout, on by
  default) and in the guests dialog, where more guests than seats only shows a hint.
- The table screen's last English-only labels (ADD, PAY, CLOSE, ACTIONS, SERVED, CLEAR,
  ALL) are keys too.
- Tests: test_close_and_combine.py (5), waiter e2e +5.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-17 09:54:37 +02:00
co-authored by Claude Opus 5.5
parent beb53c65bb
commit 198f8ff571
18 changed files with 376 additions and 39 deletions
+2 -1
View File
@@ -71,7 +71,8 @@
"quantity": "«{{name}}»: αυτή η ποσότητα δεν επιτρέπεται (γραμμή {{line}}).",
"price": "«{{name}}»: αυτή η αλλαγή τιμής δεν επιτρέπεται (γραμμή {{line}}).",
"client_price": "«{{name}}»: η εφαρμογή έστειλε δικές της τιμές, ενώ οι τιμές έρχονται από τον server (γραμμή {{line}}). Ενημερώστε την εφαρμογή."
}
},
"items_not_combinable": "Αυτές οι γραμμές δεν συνδυάζονται: μόνο απλήρωτες γραμμές του ίδιου είδους, με ίδιες επιλογές, σημείωση, τιμή και κατάσταση κουζίνας, χωρίς έκπτωση, προσφορά ή καρτέλα."
},
"notification": {
"not_found": "Η ειδοποίηση {{notification_id}} δεν βρέθηκε."
+4
View File
@@ -378,6 +378,10 @@
"never": "Μόνο όταν εγκαταλειφθεί",
"after_one": "Μετά από {{count}} αποτυχία",
"after_other": "Μετά από {{count}} αποτυχίες"
},
"operation": {
"closeUnpaid": "Κλείσιμο τραπεζιού με απλήρωτα",
"closeUnpaidHint": "Ανενεργό: το κλείσιμο τραπεζιού με απλήρωτα ζητά πρώτα την πληρωμή και μετά το κλείνει. Ενεργό: κλείνει και τα απλήρωτα καταγράφονται ως απλήρωτα."
}
},
"logs": {
+29 -4
View File
@@ -311,7 +311,12 @@
"operation": "Λειτουργία",
"favorites": "Αγαπημένα"
},
"max": "μέγιστο"
"max": "μέγιστο",
"seats": {
"title": "Θέσεις",
"label": "Εμφάνιση θέσεων τραπεζιού",
"desc": "Στις κάρτες τραπεζιών, δίπλα στο όνομα (τις ορίζει ο διαχειριστής ανά τραπέζι)"
}
},
"venues": {
"active": "ΕΝΕΡΓΟ",
@@ -457,7 +462,10 @@
"moveSub": "Μεταφορά επιλεγμένων αντικειμένων",
"splitSub": "Χώρισμα σε δύο γραμμές",
"cancel": "Ακύρωση παραγγελίας",
"cancelSub": "Ακύρωση επιλεγμένων αντικειμένων"
"cancelSub": "Ακύρωση επιλεγμένων αντικειμένων",
"combine": "Συνδυασμός σε μία γραμμή",
"combineSub_one": "{{count}} γραμμή του ίδιου είδους",
"combineSub_other": "{{count}} γραμμές του ίδιου είδους"
},
"withApproval": "Με έγκριση διαχειριστή (PIN)",
"cancelNotAllowed": "Δεν επιτρέπεται η ακύρωση",
@@ -517,7 +525,8 @@
"noTargetOrder": "Δεν βρέθηκε παραγγελία στο τραπέζι",
"merge": "Σφάλμα συγχώνευσης",
"moveItems": "Σφάλμα μεταφοράς αντικειμένων",
"flags": "Σφάλμα αποθήκευσης σημαιών"
"flags": "Σφάλμα αποθήκευσης σημαιών",
"combine": "Σφάλμα συνδυασμού"
},
"openOrder": "Άνοιγμα Παραγγελίας",
"noPaid": "Δεν υπάρχουν πληρωμένα αντικείμενα",
@@ -540,7 +549,9 @@
},
"close": {
"title": "Κλείσιμο παραγγελίας;",
"body": "Αυτή η ενέργεια δεν αναιρείται."
"body": "Αυτή η ενέργεια δεν αναιρείται.",
"unpaid_one": "{{count}} αντικείμενο είναι απλήρωτο: θα κλείσει ως απλήρωτο.",
"unpaid_other": "{{count}} αντικείμενα είναι απλήρωτα: θα κλείσουν ως απλήρωτα."
},
"move": {
"pickFree": "Επιλέξτε κενό τραπέζι",
@@ -574,6 +585,15 @@
"tabs": {
"unpaid": "Εκκρεμή",
"paid": "Πληρωμένα"
},
"btn": {
"close": "ΚΛΕΙΣΙΜΟ",
"add": "ΠΡΟΣΘΗΚΗ",
"pay": "€ ΠΛΗΡΩΜΗ",
"served": "ΣΕΡΒΙΡΙΣΤΗΚΕ",
"actions": "ΕΝΕΡΓΕΙΕΣ",
"clear": "ΚΑΘΑΡΙΣΜΟΣ",
"all": "ΟΛΑ"
}
},
"add": {
@@ -779,5 +799,10 @@
"cancelled": "ΑΚΥΡΩΜΕΝΗ",
"limit_one": "Το πακέτο σας δείχνει την τελευταία {{count}} ημέρα",
"limit_other": "Το πακέτο σας δείχνει τις τελευταίες {{count}} ημέρες"
},
"seats": {
"table_one": "Τραπέζι για {{count}}",
"table_other": "Τραπέζι για {{count}}",
"over": "{{count}} άτομα σε τραπέζι για {{seats}}: εντάξει, είναι μόνο ένδειξη"
}
}
+2 -1
View File
@@ -71,7 +71,8 @@
"quantity": "{{name}}: that quantity isn't allowed (line {{line}}).",
"price": "{{name}}: that price change isn't allowed (line {{line}}).",
"client_price": "{{name}}: the app sent its own prices, but prices come from the server (line {{line}}). Update the app."
}
},
"items_not_combinable": "These lines can't be combined: only unpaid lines of the same item, with the same choices, note, price and kitchen state, and no discount, deal or tab."
},
"notification": {
"not_found": "Notification {{notification_id}} not found."
+4
View File
@@ -378,6 +378,10 @@
"never": "Only when it is given up",
"after_one": "After {{count}} failed attempt",
"after_other": "After {{count}} failed attempts"
},
"operation": {
"closeUnpaid": "Close a table with unpaid items",
"closeUnpaidHint": "Off: closing a table with unpaid items asks for the payment first, then closes it. On: it closes and the unpaid items are recorded as unpaid."
}
},
"logs": {
+29 -4
View File
@@ -311,7 +311,12 @@
"operation": "Operation",
"favorites": "Favourites"
},
"max": "maximum"
"max": "maximum",
"seats": {
"title": "Seats",
"label": "Show each table's seats",
"desc": "On the table cards, next to the name (set by the manager per table)"
}
},
"venues": {
"active": "ACTIVE",
@@ -457,7 +462,10 @@
"moveSub": "Move the selected items",
"splitSub": "Split into two lines",
"cancel": "Cancel",
"cancelSub": "Cancel the selected items"
"cancelSub": "Cancel the selected items",
"combine": "Combine into one line",
"combineSub_one": "{{count}} line of the same item",
"combineSub_other": "{{count}} lines of the same item"
},
"withApproval": "With a manager's approval (PIN)",
"cancelNotAllowed": "Cancelling is not allowed",
@@ -517,7 +525,8 @@
"noTargetOrder": "No order found on that table",
"merge": "Couldn't merge",
"moveItems": "Couldn't move the items",
"flags": "Couldn't save the flags"
"flags": "Couldn't save the flags",
"combine": "Couldn't combine the lines"
},
"openOrder": "Open an order",
"noPaid": "No paid items",
@@ -540,7 +549,9 @@
},
"close": {
"title": "Close the order?",
"body": "This can't be undone."
"body": "This can't be undone.",
"unpaid_one": "{{count}} item is unpaid: it will be closed as unpaid.",
"unpaid_other": "{{count}} items are unpaid: they will be closed as unpaid."
},
"move": {
"pickFree": "Choose a free table",
@@ -574,6 +585,15 @@
"tabs": {
"unpaid": "Unpaid",
"paid": "Paid"
},
"btn": {
"close": "CLOSE",
"add": "ADD",
"pay": "€ PAY",
"served": "SERVED",
"actions": "ACTIONS",
"clear": "CLEAR",
"all": "ALL"
}
},
"add": {
@@ -779,5 +799,10 @@
"cancelled": "CANCELLED",
"limit_one": "Your plan shows the last {{count}} day",
"limit_other": "Your plan shows the last {{count}} days"
},
"seats": {
"table_one": "Table for {{count}}",
"table_other": "Table for {{count}}",
"over": "{{count}} guests at a table for {{seats}}: fine, it is only a suggestion"
}
}