feat: bump client-services (accumulated feature work + deploy fixes)

Snapshot of in-progress work across local_backend, manager_dashboard,
and waiter_pwa (pricing, chat, fiscal, prep zones, recovery codes, CRM,
inventory, permissions), plus the nginx/docker-compose deploy fixes for
the Unraid + NPM reverse-proxy setup.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
2026-07-19 10:00:14 +03:00
co-authored by Claude Sonnet 5
parent 02ec1aa28f
commit 34ae328b0d
182 changed files with 34874 additions and 3556 deletions
+8 -7
View File
@@ -238,7 +238,7 @@ function PayersModal({ order, waiterMap, onClose }) {
</div>
<div className="overflow-y-auto flex-1 px-6 py-4 space-y-5">
{paymentGroups.map((g, i) => {
const groupTotal = g.items.reduce((s, it) => s + it.unit_price * it.quantity, 0)
const groupTotal = g.items.reduce((s, it) => s + ((it.unit_price ?? 0) + (it.price_adjustment ?? 0)) * it.quantity, 0)
const waiterName = waiterMap[g.waiter_id] || `#${g.waiter_id}`
return (
<div key={i} className="space-y-1">
@@ -257,7 +257,7 @@ function PayersModal({ order, waiterMap, onClose }) {
{g.items.map(it => (
<li key={it.id} className="flex justify-between text-sm text-gray-600">
<span>{it.product?.name ?? `#${it.product_id}`}{it.quantity > 1 ? ` ×${it.quantity}` : ''}</span>
<span>€{(it.unit_price * it.quantity).toFixed(2)}</span>
<span>€{(((it.unit_price ?? 0) + (it.price_adjustment ?? 0)) * it.quantity).toFixed(2)}</span>
</li>
))}
</ul>
@@ -281,14 +281,15 @@ function OrderDetailsModal({ order, tableMap, waiterMap, onClose, printers, onPr
if (!order) return null
const activeItems = order.items.filter(i => i.status !== 'cancelled')
const total = activeItems.reduce((s, i) => s + i.unit_price * i.quantity, 0)
const effPrice = i => (i.unit_price ?? 0) + (i.price_adjustment ?? 0)
const total = activeItems.reduce((s, i) => s + effPrice(i) * i.quantity, 0)
// Per-waiter subtotals for paid items
const waiterTotals = {}
for (const item of activeItems.filter(i => i.status === 'paid' && i.paid_by)) {
const wid = item.paid_by
if (!waiterTotals[wid]) waiterTotals[wid] = 0
waiterTotals[wid] += item.unit_price * item.quantity
waiterTotals[wid] += effPrice(item) * item.quantity
}
const waiterTotalEntries = Object.entries(waiterTotals)
@@ -327,8 +328,8 @@ function OrderDetailsModal({ order, tableMap, waiterMap, onClose, printers, onPr
<tr key={item.id} className={item.status === 'cancelled' ? 'opacity-40 line-through' : ''}>
<td className="px-4 py-2.5 text-gray-800">{item.product?.name ?? `#${item.product_id}`}</td>
<td className="px-4 py-2.5 text-center text-gray-700">{item.quantity}</td>
<td className="px-4 py-2.5 text-right text-gray-700">€{item.unit_price.toFixed(2)}</td>
<td className="px-4 py-2.5 text-right font-semibold text-gray-800">€{(item.unit_price * item.quantity).toFixed(2)}</td>
<td className="px-4 py-2.5 text-right text-gray-700">€{effPrice(item).toFixed(2)}</td>
<td className="px-4 py-2.5 text-right font-semibold text-gray-800">€{(effPrice(item) * item.quantity).toFixed(2)}</td>
<td className="px-4 py-2.5"><Badge status={item.status} /></td>
<td className="px-4 py-2.5 text-gray-500 whitespace-nowrap">{item.paid_at ? fmtDt(item.paid_at) : '—'}</td>
<td className="px-4 py-2.5 text-gray-500">{item.payment_method ? pmLabel(item.payment_method) : '—'}</td>
@@ -836,7 +837,7 @@ function HistoryTab({ filters, setFilters }) {
{visibleOrders.map(o => {
const total = o.items
.filter(i => i.status !== 'cancelled')
.reduce((s, i) => s + i.unit_price * i.quantity, 0)
.reduce((s, i) => s + ((i.unit_price ?? 0) + (i.price_adjustment ?? 0)) * i.quantity, 0)
// Opener / closer
const openerName = waiterMap[o.opened_by] || `#${o.opened_by}`