WFDASH-WEBAPP/docs/superpowers/specs
Dave 4babb893f4 docs(spec): giellie stock quantity update
Giellie can already reach stock_items, but only through ad-hoc
list+adjust loops: a signed delta instead of an absolute count, no
batch call, fuzzy SKU picks the model cannot see are wrong, and
stock_items.adjust throws the actor away so the ledger row has no
attribution.

Adds a stock_items.set_quantities MCP tool that resolves each pasted
line (exact SKU, then description fuzzy), computes the delta, and
writes through updateStockItemsQuantities so the ledger is audited
against the signed-in user. Also mirrors price_list.stock_qty, which
price-list-service.ts documents as a denormalised snapshot of
current_qty.

The live data makes this matter: 522 of the 4,083 sellable items carry
a negative tracked quantity and 2,901 sit at zero. That drift is by
design - the till oversells on purpose (pos-service.ts:603) and is
corrected at the next stocktake, which is what this feature is.

Nothing blocks on low stock. One service flag (allowNegativeQty)
lifts the non-negative floor for the agent's writes only, leaving the
/stock page untouched.
2026-11-05 06:46:19 +02:00
..
2026-07-07-collection-confirm-bulk-and-search-design.md
2026-07-07-collection-confirm-enhancements-design.md
2026-07-07-collection-confirm-fixes-design.md
2026-07-07-collection-confirm-page-design.md
2026-07-07-collection-confirm-selection-and-return-design.md
2026-07-07-collection-pool-cluster-sort-design.md
2026-07-07-collection-pool-redesign-design.md
2026-07-07-invoicing-page-design.md
2026-07-07-invoicing-print-and-quickbooks-design.md
2026-07-07-invoicing-quickbooks-customer-modal-design.md
2026-07-08-invoicing-quickbooks-writeback-design.md
2026-07-08-invoicing-redesign-and-pdf-upload-design.md
2026-07-09-collection-confirm-rewrite-design.md
2026-07-09-collection-map-date-filter-and-unassign-design.md
2026-07-09-collection-pool-mark-ready-notes-design.md
2026-07-09-collection-pool-nearby-sort-design.md
2026-07-09-customer-search-company-disambiguation-design.md
2026-07-09-invoice-bulk-print-tracking-design.md
2026-07-09-invoice-print-bundle-design.md
2026-07-09-new-quote-form-redesign-design.md
2026-07-09-order-color-stripe-design.md
2026-07-09-picking-slip-supplier-pickedby-design.md
2026-07-09-po-additional-attachments-design.md
2026-07-09-po-pdf-token-vs-filename-design.md
2026-07-10-collection-pool-supplier-groups-and-notes-design.md
2026-07-11-collection-map-simplify-pins-design.md
2026-07-12-collection-map-driver-cards-redesign-design.md
2026-07-12-collection-map-drop-date-filter-and-ready-gate-design.md
2026-07-29-buyer-tasks-design.md
2026-07-29-order-sprint-item-history-design.md
2026-07-29-orders-review-modal-design.md
2026-07-30-stock-quick-draft-design.md
2026-08-02-collection-confirm-revamp-design.md
2026-08-03-buyer-tasks-mail-failed-recovery-design.md
2026-08-03-stock-orders-total-value-design.md
2026-08-03-stock-orders-wrap-pdf-design.md docs(stock-orders): design spec for cell wrap + PDF downloads 2026-08-03 15:54:24 +02:00
2026-08-06-buyer-tasks-resend-button-design.md docs(spec): add Re-Send button on PO Sent tab of buyer-tasks 2026-08-06 17:33:25 +02:00
2026-08-06-supplier-po-pdf-vat-design.md docs(spec): clarify placement of vat computation 2026-08-06 11:45:11 +02:00
2026-08-07-order-item-context-block-design.md docs(spec): order-item context block (sprint modal + orders page) 2026-08-07 02:16:31 +02:00
2026-08-26-no-quote-design.md docs(quotes): add no-quote feature design spec 2026-08-26 23:08:08 +02:00
2026-08-27-approve-and-send-from-list-design.md docs(quotes): add approve-and-send-from-list design spec 2026-08-27 00:33:50 +02:00
2026-08-27-boss-phone-dashboard-design.md docs(boss-dashboard): add phone-first /m dashboard design spec 2026-08-27 23:36:32 +02:00
2026-08-29-order-delivery-note-match-design.md docs(orders): spec + plan for delivery-note repeat-order detection 2026-08-29 23:51:52 +02:00
2026-08-29-order-quote-linking-design.md docs(orders): spec order↔quote auto-linking and per-line quote context 2026-08-29 10:49:06 +02:00
2026-08-30-non-invoiceable-order-extras-design.md docs: non-invoiceable extras design + plan, quantity-handling audit 2026-08-30 18:28:44 +02:00
2026-08-30-quantity-handling-audit.md docs: non-invoiceable extras design + plan, quantity-handling audit 2026-08-30 18:28:44 +02:00
2026-08-30-wfsales-pos-design.md docs(pos): add design spec for WFSALES POS app 2026-08-30 23:50:56 +02:00
2026-08-31-stock-pricing-inline-edit-design.md docs(stock): reconcile spec with shipped design 2026-08-31 17:19:12 +02:00
2026-09-01-deliveries-dn-items-expand-design.md docs: clarify unit suffix handling in DN items panel header 2026-09-01 12:01:42 +02:00
2026-09-01-delivery-row-info-and-order-age-badge-design.md docs: spec for compact DN row + order age badge 2026-09-01 01:56:28 +02:00
2026-09-01-rep-dashboard-design.md docs: add design spec for rep dashboard (dashboard 2) 2026-09-01 01:25:53 +02:00
2026-09-04-pos-slip-layout-editor-design.md docs(pos): add design spec for the slip layout editor 2026-09-04 12:42:45 +02:00
2026-09-05-rep-visit-check-in-design.md feat(rep-visits): FleetAI tracker adapter, nearby-customer matching, stop detection 2026-09-06 14:22:28 +02:00
2026-09-30-giellie-agent-design.md docs(giellie): add agent design spec and implementation plan 2026-09-30 23:31:57 +02:00
2026-10-16-ai-quote-assistant-design.md feat(quote-assistant): fill service, tick, counts 2026-10-16 19:29:16 +02:00
2026-10-17-collection-confirm-ai-checks-design.md docs(collection-ai): runbook tick table, audit scope; spec content_hash index is non-unique 2026-10-17 10:21:25 +02:00
2026-10-24-ai-order-assistant-design.md docs(spec): AI order assistant — match orders to quotes, pre-fill lines 2026-10-24 11:37:34 +02:00
2026-10-30-delivery-pool-design.md feat(delivery-pool): assign invoiced deliveries to drivers, close with the signed copy 2026-10-31 09:55:35 +02:00
2026-11-02-order-item-payments-and-approvals-design.md refactor: simplify supplier payments to document checklist 2026-11-03 07:18:56 +02:00
2026-11-02-whats-new-release-ids-design.md docs: What's New release numbers and commit IDs instead of dates 2026-11-02 20:17:08 +02:00
2026-11-03-simplified-order-payments.md refactor: simplify supplier payments to document checklist 2026-11-03 07:18:56 +02:00
2026-11-05-giellie-stock-quantity-update-design.md docs(spec): giellie stock quantity update 2026-11-05 06:46:19 +02:00