feat(backend,terminal): online orders on the counter POS (platform-v2 step 3.3d)
- Counter POS gets an "Online" mode (module on + connect_orders.manage): New / In
progress / Finished, a chime on arrival (and every 30 s while one waits), badge,
toast in any mode; the order panel offers only the next step: accept / reject with
a reason, preparing, ready or out for delivery, then take the payment (shared
PaymentDialog, drawer, shift) and mark delivered/served.
- connect_orders router on v2 conventions: require(connect_orders.manage), error
codes online.not_found / online.status_changed, the cloud's step order enforced,
audit rows, GET /api/connect/orders/board. POS device scope gains connect_orders.*;
barista and barman get the key by default.
- Fixes: the KDS showed online orders before acceptance; accepting printed no
kitchen tickets; a pull whose synced mark failed stored the order twice
(store_online_orders skips known cloud ids); pulled orders lacked the business day
and delivery type; rejected orders kept active items; delivered sets closed_at/by.
- Online orders belong to holders of connect_orders.manage (_can_access_order), so
the counter pays them with POST /api/pos/orders/{id}/pay.
- Tests: test_pos_online.py (5), terminal unit +1, terminal.mjs +17 with a fake
cloud (pull, synced, status mirror); fixed a timing race in a 3.3c check.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -241,7 +241,8 @@
|
||||
"mode": {
|
||||
"label": "Λειτουργία ταμείου",
|
||||
"sale": "Πώληση",
|
||||
"tables": "Τραπέζια"
|
||||
"tables": "Τραπέζια",
|
||||
"online": "Online"
|
||||
},
|
||||
"tables": {
|
||||
"none": "Δεν έχετε τραπέζια",
|
||||
@@ -290,6 +291,64 @@
|
||||
"card": "πληρώθηκε · κάρτα"
|
||||
},
|
||||
"readyItem": "έτοιμο"
|
||||
},
|
||||
"online": {
|
||||
"arrived_one": "Νέα online παραγγελία",
|
||||
"arrived_other": "{{count}} νέες online παραγγελίες",
|
||||
"lists": {
|
||||
"incoming": "Νέες",
|
||||
"in_progress": "Σε εξέλιξη",
|
||||
"finished": "Ολοκληρωμένες"
|
||||
},
|
||||
"empty": {
|
||||
"incoming": "Δεν υπάρχουν νέες online παραγγελίες",
|
||||
"in_progress": "Τίποτα σε εξέλιξη",
|
||||
"finished": "Τίποτα ολοκληρωμένο ακόμη"
|
||||
},
|
||||
"emptyBody": "Οι παραγγελίες από το QR μενού σας εμφανίζονται εδώ αμέσως, με ήχο.",
|
||||
"pick": "Επιλέξτε μια παραγγελία για να τη δείτε",
|
||||
"type": {
|
||||
"delivery": "Διανομή",
|
||||
"dine_in": "Στο κατάστημα"
|
||||
},
|
||||
"status": {
|
||||
"pending_acceptance": "Περιμένει απάντηση",
|
||||
"accepted": "Αποδεκτή",
|
||||
"preparing": "Ετοιμάζεται",
|
||||
"ready": "Έτοιμη",
|
||||
"out_for_delivery": "Σε διανομή",
|
||||
"delivered": "Ολοκληρώθηκε",
|
||||
"rejected": "Απορρίφθηκε"
|
||||
},
|
||||
"waiting_one": "περιμένει {{count}} λεπτό",
|
||||
"waiting_other": "περιμένει {{count}} λεπτά",
|
||||
"accept": "Αποδοχή και αποστολή στην κουζίνα",
|
||||
"reject": "Απόρριψη",
|
||||
"to": {
|
||||
"preparing": "Έναρξη προετοιμασίας",
|
||||
"ready": "Έτοιμη",
|
||||
"out_for_delivery": "Σε διανομή"
|
||||
},
|
||||
"payAnd": {
|
||||
"delivered": "Είσπραξη {{amount}} · παραδόθηκε",
|
||||
"served": "Είσπραξη {{amount}} · σερβιρίστηκε"
|
||||
},
|
||||
"mark": {
|
||||
"delivered": "Παραδόθηκε",
|
||||
"served": "Σερβιρίστηκε"
|
||||
},
|
||||
"rejectTitle": "Απόρριψη αυτής της παραγγελίας;",
|
||||
"rejectBody": "Ο πελάτης βλέπει τον λόγο στη σελίδα της παραγγελίας του.",
|
||||
"reason": "Λόγος",
|
||||
"reasons": {
|
||||
"busy": "Έχουμε πολύ φόρτο αυτή τη στιγμή",
|
||||
"unavailable": "Κάποια είδη δεν είναι διαθέσιμα",
|
||||
"closing": "Κλείνουμε",
|
||||
"area": "Δεν κάνουμε διανομή σε αυτή τη διεύθυνση",
|
||||
"other": "Άλλος λόγος…"
|
||||
},
|
||||
"keep": "Να μείνει",
|
||||
"rejectConfirm": "Απόρριψη παραγγελίας"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user