- codeIndex
- 400 · count · small · urgent
- Rule
- SalesOrder.status = SUBMITTED, deliveryDate ≤ today, no fulfilment ≥ DISPATCHED
- Source
- SUMMARY
- Drill
- Fulfilments ?due=today
Wholesale dashboard
Module 180 · new landing page (today the module root redirects to Branding)
provideModuleDashboard, Mise widget host and shell). Each widget is backed by a field module 180 already has.
Use MVP / Phase 2 / Drop under each card to make your picks, then answer the questions at the bottom and copy your decisions.
wholesale/dashboard/summary call
NEW own new report endpoint
Act now
Operations: the current state, not affected by the period- codeIndex
- 401 · breakdown · medium
- Rule
- Fulfilment.status counts RESERVED→PACKED (open), plus DISPATCHED where Dispatch.collectedAt is today
- Source
- SUMMARY
- Drill
- each part → Fulfilments ?status=…
- Restaurang Lyktan ABSO-10482 · held 2 h18 420 kr
- Café SmultronSO-10477 · held 1 d4 960 kr
- Hotell NorrskenSO-10469 · held 2 d32 115 kr
- codeIndex
- 402 · item-list · small · urgent
- Rule
- creditHeldAt set, creditReleasedAt null
- Source
- EXISTS GET wholesale-sales-orders/credit-held
- Drill
- row → sales order (release action lives there)
- Bistro AnkaretSO-10401 · delivery 3 Oct9 d over
- Skolköket VästSO-10388 · delivery 6 Oct6 d over
- Pizzeria MonteSO-10412 · delivery 8 Octauto-cancel in 2 d
- codeIndex
- 403 · item-list · small
- Rule
- past grace days; shows the auto-cancel countdown when the action is AUTO_CANCEL
- Source
- EXISTS GET wholesale-sales-orders/stale
- Drill
- row → sales order
- Burrata 125 gOut of stock7 waiting
- Pecorino Romano 1 kgOut of stock4 waiting
- Guanciale ca 1,2 kgLow stock2 waiting
- codeIndex
- 404 · item-list · small
- Rule
- StockNotificationRequest: notifiedAt null, not cancelled, grouped by product, ordered by count
- Source
- NEW grouped read
- Drill
- row → Availability ?product=
- Why
- lost sales you can still recover with a purchase order
- codeIndex
- 405 · count · small
- Rule
- Return.disposition = UNSPECIFIED, or creditApplied = false
- Source
- SUMMARY
- Drill
- Returns ?open=true
Money
Receivables and invoicing: the current state- codeIndex
- 406 · count (currency) · small
- Rule
- Invoice.status ISSUED/SENT, paidAt null; credit notes net off
- Source
- SUMMARY
- Drill
- Invoices ?unpaid=true
- codeIndex
- 407 · chart (bar) · medium
- Rule
- unpaid invoices by days past dueDate
- Source
- SUMMARY
- Drill
- bar → Invoices ?overdue=31-60
- codeIndex
- 409 · count · small · urgent
- Rule
- Fulfilment.status = DISPATCHED (not INVOICED) for more than 24 h
- Source
- SUMMARY
- Drill
- Fulfilments ?status=dispatched
- Why
- revenue leak: the goods have left and no invoice exists
- codeIndex
- 408 · chart (bar-h) · medium
- Rule
- customers with credit control on, exposure / creditLimit ≥ 70 %
- Source
- NEW company-wide list (per-customer
customers/:id/credit-exposureexists) - Drill
- bar → customer, credit tab
- codeIndex
- 410 · count · small
- Rule
- InvoiceDelivery.status = FAILED, latest attempt per invoice
- Source
- SUMMARY
- Drill
- Invoices ?delivery=failed
Sales
Follows the period switch · net of VAT · compared with the previous period- codeIndex
- 411 · count (currency) + delta · small
- Rule
- SUBMITTED orders by submittedAt, sum netAmount, cancelled excluded
- Source
- SUMMARY
- Drill
- Sales orders ?from&to
- codeIndex
- 412 · count + delta · small
- Source
- SUMMARY
- Drill
- Sales orders
- codeIndex
- 413 · count (currency) + delta · small
- Source
- SUMMARY
- Note
- the "below free freight" line uses the storefront thresholds; drop it if it is too much
- codeIndex
- 414 · chart (line) · medium · uses the header actions slot (#9908)
- Source
- NEW time series endpoint
- Drill
- point → Sales orders for that week
- codeIndex
- 415 · chart (bar-h) · small
- Source
- NEW top-N endpoint
- Drill
- bar → customer
- codeIndex
- 416 · chart (bar-h) · small
- Rule
- SalesOrderDetail net by product
- Source
- NEW top-N endpoint (same endpoint as 415, different grouping)
- Drill
- bar → catalogue product
- codeIndex
- 417 · chart (donut) · small
- Rule
- customerUserId set → webshop; sourceOrderId set → handed over from a linked buyer's ordering module; otherwise → staff
- Source
- SUMMARY
- Why
- shows how many customers have moved onto self-service
- Trattoria Soleusually weekly · last 26 Sep16 d
- Kafé Linnéusually 2×/week · last 1 Oct11 d
- Grill 27usually weekly · last 15 Sep27 d
- codeIndex
- 418 · item-list · small
- Rule
- customer's gap since the last order > 2× their median gap over 90 days
- Source
- NEW
- Drill
- row → customer
- Höstpasta −15 %ends 15 Oct · 214 lines sold3 d
- Köp 10 få 1 – Burrataends 19 Oct7 d
- codeIndex
- 419 · item-list · small
- Rule
- published + active, validTo within 7 days
- Source
- campaigns list + filter (lines sold = NEW)
Catalogue & compliance
Setup problems that cost money or break the webshop- codeIndex
- 420 · count · small
- Source
- EXISTS per list:
wholesale-price-lists/:id/price-coverage/summary; one company-wide roll-up wanted - Drill
- Price lists
- Reverse charge, VAT no. not verifiedEU business customers4 orders
- Cross-border consumer salesOSS threshold watch1 customer
- codeIndex
- 421 · breakdown · small
- Source
- EXISTS wholesale-vat-risks/unverified-reverse-charge + /cross-border-consumer-sales
- Drill
- the two VAT-risk reports (#8699)
Open questions
1 · Module landing. Should the Wholesale root open the dashboard instead of Branding?
2 · Several currencies. Orders and invoices carry their own currency, and the model has no FX rates. How should money widgets show totals?
3 · What counts as a sale?
4 · Amounts net or with VAT?
5 · Who sees what? Widget visibility per role goes through the existing dashboard-widget-roles.
Summary & build split
| codeIndex | Widget | Group | Body | Source | Your pick |
|---|
API.v2: one bazaro-report wholesale controller (dashboard/summary with all the counts, plus a time series and top-N) and a migration that seeds Application.DashboardWidgets rows (codeIndex 400–421, module 180). The schema is code-first, so there is no DB repo story.
WEB.v3: features/wholesale/pages/dashboard, a wholesale-widget-registry.ts and provideModuleDashboard({ moduleCodeIndex: 180 }), and the root redirect pointed at the dashboard.
DS: MiseModule has no wholesale accent yet (it has invoice, kitchen, supplier, esign and support), so Mise needs a release before v3 can use one.
The codeIndex range 400–421 is free in v3 today; it is only a proposal.