feat(backend,waiter,terminal,manager): +1 on a sent line and changing a line's quantity

Owner 2026-11-23 (plan 6F.5). Product flag one_more_enabled (off by default; product editor).
POST /api/orders/{id}/items/{item}/again: a new line like the old one (choices, removed, note,
course), priced now, sent to the kitchen like any new line. Waiter app and the counter's table
panel: +1 beside such lines; the first tap arms it, more taps count up, 'Send +N' sends, 4 s idle
disarms (no stray sends).
POST /api/orders/{id}/items/{item}/quantity: venue setting orders.quantity_change (off | add_only |
add_and_remove, default off), key ordering.items.change_quantity (owner, store manager; Alembic 0049
grants it); up only changes the line, down cuts a cancelled part ('quantity lowered', split_from_id)
and prints a cancellation only when asked (the dialog presets yes while the kitchen hasn't finished).
Waiter: 'Change quantity' in a line's actions (now -> new, -/+). cut_part() now shared with split.
GET /api/orders/{id} items carry the product's one_more_enabled / unit_type, deal ids, split_from_id,
cancel_reason.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-23 08:26:46 +02:00
co-authored by Claude Opus 5.5
parent 0a353c5f97
commit 72e175ab73
35 changed files with 813 additions and 35 deletions
+7 -1
View File
@@ -105,7 +105,13 @@
"product_unavailable": "Product {{product_id}} isn't available.",
"price_change_off": "Changing prices by hand is turned off for this venue.",
"price_change_sent_off": "Prices can only be changed before the items are sent.",
"price_reason_required": "Say why the price changes."
"price_reason_required": "Say why the price changes.",
"one_more_off": "\"One more\" isn't turned on for this product.",
"one_more_line": "This line can't be ordered again with one tap.",
"quantity_change_off": "Changing quantities is turned off for this venue.",
"quantity_remove_off": "Quantities can only go up at this venue.",
"quantity_invalid": "Choose a whole number from 1 to {{max}}.",
"quantity_line": "This line's quantity can't be changed here."
},
"notification": {
"not_found": "Notification {{notification_id}} not found."
+19 -2
View File
@@ -759,6 +759,18 @@
"reasonsHint": "Offered with one tap; staff can still type their own. None: the built-in ones.",
"reasonItem": "Quick reason",
"newReason": "A new quick reason…"
},
"quantity": {
"title": "Changing a sent line's quantity",
"intro": "Staff correct how many of a line there are without sending it to the kitchen again. Every change is kept in the order's history.",
"when": "Staff may",
"whenHint": "Who may: \"What each role may do\" and each person's permissions.",
"whenTip": "Only add: the quantity can go up (a beer taken from the fridge), nothing is printed. Add and remove: lowering it also cancels the difference as its own cancelled line, and asks whether to send a cancellation to the kitchen. Removing needs the permission to cancel too.",
"modes": {
"off": "Not at all",
"add_only": "Only add",
"add_and_remove": "Add and remove"
}
}
},
"logs": {
@@ -2813,7 +2825,10 @@
"availableTip": "Off: it disappears from the waiters' and the counter's menus until you switch it back on (sold out today). Nothing else about it changes.",
"quickAddTip": "On: one tap in the waiter's product list adds it straight to the order without opening its choices. Leave it off for products whose choices must be picked (cooking, sides).",
"vatGroupTip": "The VAT rate the fiscal receipt uses for this product. Needed before it can be paid while the fiscal device is on.",
"costTip": "What one unit costs you (ingredients, packaging). Reports use it for the profit; products without a cost make the profit a lower estimate."
"costTip": "What one unit costs you (ingredients, packaging). Reports use it for the profit; products without a cost make the profit a lower estimate.",
"oneMore": "One more (+1)",
"oneMoreHint": "A sent line of this product gets a +1 button on the phones and the counter.",
"oneMoreTip": "For what tables keep ordering again (beers, coffees). +1 orders the same again, with the same choices and note, at today's price, and sends it to the kitchen or bar like any new order. Off by default."
}
},
"menuTabletSettings": {
@@ -3392,7 +3407,9 @@
"ORDER_CANCELLED": "Cancelled",
"ITEM_CANCELLED": "Line cancelled",
"PRICE_CHANGED": "Price changed",
"PRICE_SET_BY_HAND": "Price set by hand (approved)"
"PRICE_SET_BY_HAND": "Price set by hand (approved)",
"QUANTITY_CHANGED": "Quantity changed",
"ITEM_REORDERED": "One more"
},
"price": {
"modifier_applied": "Price rule",
+3
View File
@@ -464,6 +464,9 @@
"refunds": "Refund payments from other shifts",
"payments": {
"revert": "Turn paid items back to unpaid"
},
"items": {
"change_quantity": "Change a sent line's quantity (no new ticket)"
}
}
},
+5
View File
@@ -466,6 +466,11 @@
},
"dialog": {
"close": "Close"
},
"oneMore": {
"send": "Send +{{count}}",
"label": "One more",
"sent": "{{count}} more {{name}} sent"
}
},
"display": {
+23 -1
View File
@@ -529,7 +529,9 @@
"moveItems": "Couldn't move the items",
"flags": "Couldn't save the flags",
"combine": "Couldn't combine the lines",
"price": "The price didn't change."
"price": "The price didn't change.",
"again": "One more wasn't sent.",
"quantity": "The quantity didn't change."
},
"openOrder": "Open an order",
"noPaid": "No paid items",
@@ -896,5 +898,25 @@
"items_moved": "Lines moved",
"orders_merged": "Tables joined"
}
},
"oneMore": {
"label": "One more",
"send": "Send +{{count}}"
},
"quantity": {
"title": "Change quantity",
"actionSub": "Correct how many; nothing is sent to the kitchen again",
"now": "Now",
"new": "New",
"less": "One less",
"more": "One more",
"save": "Save",
"upNote_one": "{{count}} more, without a new ticket",
"upNote_other": "{{count}} more, without a new ticket",
"downNote_one": "{{count}} will be cancelled",
"downNote_other": "{{count}} will be cancelled",
"noChange": "Use − and + to change it",
"onlyUp": "At this venue quantities only go up.",
"sendCancel": "Send a cancellation to the kitchen"
}
}