Screens / Order queue (kitchen)
Order queue (kitchen)
Polls the kitchen queue with If-None-Match (304 keeps the last snapshot) and re-polls on FCM nudges. Each line has a Ready tick (kitchen, `orders.prepare`) and, for roles that serve, a Served tick (`orders.serve`); tickets show a progress bar, and owner, manager and cashier get the filter chips All, Ready to serve and Preparing (PAN-87). The queue also sits as a segment of Orders for anyone with `orders.view`. Back on the tab (PAN-59) the data shows at once and refreshes quietly.
- App routes
/order-queue- Access
- orders.queue
- Screen code
lib/screens/order_queue/order_queue_page.dartlib/screens/order_queue/order_queue_controller.dartlib/data/queue/polling_kitchen_queue_source.dartlib/screens/order_queue/widgets/queue_tick_box.dartlib/screens/order_queue/widgets/queue_filter_chips.dartlib/screens/order_queue/widgets/ticket_progress.dartlib/screens/order_queue/ticks_copy.dart- Source
- elmermj/panly-app @ pre-staging-test (72aaffd)
API calls (3)
| Call | Why the screen makes it | Where in the app code |
|---|---|---|
GET /v1/kitchen/queueRead-only queue of open order rounds |
Poll every page (limit=100); If-None-Match on page 1 | lib/screens/order_queue/order_queue_bindings.dart:19lib/data/queue/polling_kitchen_queue_source.dart:54lib/data/repositories/queue_repository.dart:58 |
POST /v1/devices/fcmRegister this device's FCM token for kitchen queue nudges |
Register this browser for queue nudges (on open, or the Enable button) | lib/screens/order_queue/order_queue_bindings.dart:24lib/screens/order_queue/order_queue_page.dart:408lib/data/push/kitchen_live_updates.dart:167lib/data/push/fcm_device_api.dart:14 |
PATCH /v1/orders/{orderId}/items/{orderItemId}Update a placed item, tick it ready / served, or move it to preparing / served / cancelled |
Tick a line Ready or Served, or undo it, with {"ready"} or {"served"} (PAN-87). The tick is idempotent 409 item_cancelled, order_not_open, item_already_served, item_not_ready and item_not_confirmed are answered with the app's own words (ticks_copy.dart). |
lib/screens/order_queue/order_queue_controller.dart:210lib/domain/usecases/orders/orders_usecase.dart:60lib/data/repositories/orders_repository.dart:63lib/data/datasources/orders_remote.dart:87 |
Each call links to its operation in the API reference. Code locations are file:line in panly-app at 72aaffd, listed from the screen down to the line that sends the request.