WFDASH-WEBAPP/docs/superpowers/specs
Dave f1c07e8682 docs(orders): spec order↔quote auto-linking and per-line quote context
Design for closing three gaps in the existing order↔quote matcher:

  - The matcher only runs when an operator clicks it, so the ~85% of
    orders that arrive against a quote stay unlinked. Adds a call from
    createOrder plus a catch-up sweep for the backlog.
  - order_items.quote_item is only written when an order is created
    from a quote, so post-hoc links never pair lines. Adds persistence
    for confident pairs.
  - findMatchedQuoteItem re-guesses the pairing at render time using
    exact/substring matching, so buyer notes and per-line attachments
    silently vanish on any wording difference. Replaced with the
    tokenised matcher already in the repo.

Fuzzy candidates are windowed to 90 days before the order's own date
(widening to 12 months only when nothing clears the threshold);
exact-identifier lookups stay unwindowed.

No PocketBase schema changes required.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-29 10:49:06 +02:00
..
2026-07-07-collection-confirm-bulk-and-search-design.md feat(collection-confirm): add full collection confirm workflow 2026-07-08 01:35:00 +02:00
2026-07-07-collection-confirm-enhancements-design.md feat(collection-confirm): add full collection confirm workflow 2026-07-08 01:35:00 +02:00
2026-07-07-collection-confirm-fixes-design.md feat(collection-confirm): add full collection confirm workflow 2026-07-08 01:35:00 +02:00
2026-07-07-collection-confirm-page-design.md feat(collection-confirm): add full collection confirm workflow 2026-07-08 01:35:00 +02:00
2026-07-07-collection-confirm-selection-and-return-design.md feat(collection-confirm): add full collection confirm workflow 2026-07-08 01:35:00 +02:00
2026-07-07-collection-pool-cluster-sort-design.md
2026-07-07-collection-pool-redesign-design.md
2026-07-07-invoicing-page-design.md feat(collection-confirm): add full collection confirm workflow 2026-07-08 01:35:00 +02:00
2026-07-07-invoicing-print-and-quickbooks-design.md feat(invoicing): add QuickBooks invoicing flow and print functionality 2026-07-09 09:44:55 +02:00
2026-07-07-invoicing-quickbooks-customer-modal-design.md feat(invoicing): add QuickBooks invoicing flow and print functionality 2026-07-09 09:44:55 +02:00
2026-07-08-invoicing-quickbooks-writeback-design.md feat(invoicing): add QuickBooks invoicing flow and print functionality 2026-07-09 09:44:55 +02:00
2026-07-08-invoicing-redesign-and-pdf-upload-design.md feat(invoicing): add QuickBooks invoicing flow and print functionality 2026-07-09 09:44:55 +02:00
2026-07-09-collection-confirm-rewrite-design.md Add collection confirm rewrite spec 2026-07-10 00:59:26 +02:00
2026-07-09-collection-map-date-filter-and-unassign-design.md Add collection map date filter and unassign spec 2026-07-10 00:47:42 +02:00
2026-07-09-collection-pool-mark-ready-notes-design.md Add collection pool mark-ready notes spec 2026-07-10 00:00:40 +02:00
2026-07-09-collection-pool-nearby-sort-design.md test(collection-pool): simplify operational sort test + correct spec reasoning 2026-07-10 00:38:31 +02:00
2026-07-09-customer-search-company-disambiguation-design.md Add customer search company-disambiguation spec 2026-07-09 21:31:45 +02:00
2026-07-09-invoice-bulk-print-tracking-design.md feat: add picking slips, bulk print tracking, supplier map 2026-07-10 10:47:11 +02:00
2026-07-09-invoice-print-bundle-design.md feat: add picking slips, bulk print tracking, supplier map 2026-07-10 10:47:11 +02:00
2026-07-09-new-quote-form-redesign-design.md Add new quote form redesign spec 2026-07-09 17:53:44 +02:00
2026-07-09-order-color-stripe-design.md Add order color stripe spec 2026-07-10 02:03:16 +02:00
2026-07-09-picking-slip-supplier-pickedby-design.md feat: add picking slips, bulk print tracking, supplier map 2026-07-10 10:47:11 +02:00
2026-07-09-po-additional-attachments-design.md Add PO additional attachments spec 2026-07-09 22:55:16 +02:00
2026-07-09-po-pdf-token-vs-filename-design.md Add PO PDF token-vs-filename spec 2026-07-09 22:13:53 +02:00
2026-07-10-collection-pool-supplier-groups-and-notes-design.md feat: add tangerine theme, new docs and plugin stubs 2026-07-14 11:48:10 +02:00
2026-07-11-collection-map-simplify-pins-design.md docs(collection-map): tighten Refresh-button open question wording 2026-07-11 23:31:41 +02:00
2026-07-12-collection-map-driver-cards-redesign-design.md feat: add tangerine theme, new docs and plugin stubs 2026-07-14 11:48:10 +02:00
2026-07-12-collection-map-drop-date-filter-and-ready-gate-design.md feat: add tangerine theme, new docs and plugin stubs 2026-07-14 11:48:10 +02:00
2026-07-29-buyer-tasks-design.md docs: buyer tasks page design spec 2026-07-29 19:35:44 +02:00
2026-07-29-order-sprint-item-history-design.md docs(spec): item history popover redesign — build both data sources, compare for 1 week 2026-07-29 13:51:25 +02:00
2026-07-29-orders-review-modal-design.md docs: clarify customer non-nullable, full-order scope, collision link, partial-fail UX 2026-07-29 13:54:21 +02:00
2026-07-30-stock-quick-draft-design.md docs(specs): stock quick-draft modal design 2026-07-30 21:26:47 +02:00
2026-08-02-collection-confirm-revamp-design.md docs(specs): add collection confirm revamp design 2026-08-02 23:23:11 +02:00
2026-08-03-buyer-tasks-mail-failed-recovery-design.md docs(buyer-tasks): design for mail-failed PO recovery in PO Draft tab 2026-08-03 10:25:51 +02:00
2026-08-03-stock-orders-total-value-design.md docs(stock-orders): design total-value columns on list table 2026-08-03 14:09:10 +02:00
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-quote-linking-design.md docs(orders): spec order↔quote auto-linking and per-line quote context 2026-08-29 10:49:06 +02:00