backend phase 14 & frontend phase 7
This commit is contained in:
@@ -12,6 +12,36 @@ for awareness.
|
||||
- **Requests filed:** frontend/requests/for-backend.md (yes/no)
|
||||
-->
|
||||
|
||||
## frontend-phase-7-b8 — Booking request flow (customer request + nurse inbox) — 2026-07-09
|
||||
- **Shipped:** the money-free request phase — `services/bookingRequests` (types/keys/constants/apis[client+
|
||||
mock]/hooks + barrel) and screens **C4** `/bookings/request` (patient/variant/address/date+time + a
|
||||
first-class 3-way caregiver-gender toggle + stage-1 notes; client-side validation gates the CTA; domain
|
||||
400s surface as field/form errors; reuses f2 patients, f3 addresses + map preview, f4/search variants),
|
||||
**C5** `/bookings/request/[id]` (summary card + 3-step tracker + polled status; response countdown →
|
||||
accept flips to a 30-min payment countdown + checkout CTA / reject/expire/cancel/converted terminal
|
||||
cards; cancel-with-confirm), the **nurse inbox** `/nurse/requests` (+ nurse nav item) and **detail**
|
||||
`/nurse/requests/[id]` (only `customerNotes` + masked city/district; accept / reject-with-reason
|
||||
invalidate inbox+detail), and a `/bookings/checkout` f9 stub. Two shared tested composites:
|
||||
`CountdownTimer` (owns its 1s tick — only it re-renders; stops at zero), `BookingRequestSummaryCard`.
|
||||
i18n `booking` (fully fleshed) + `nav.requests` in both locales.
|
||||
- **Load-bearing rules honored:** deadlines are **server-frozen UTC** (client renders, never recomputes);
|
||||
`required_caregiver_gender` is explicit + client-blocks a same-gender mismatch; two-stage disclosure (the
|
||||
nurse UI never renders address/clinical fields — `get(id,'nurse')` masks); polling **stops** on a
|
||||
terminal/`converted` status.
|
||||
- **Consumes:** dev/contracts/domains/booking-requests.md (b8) — routes `booking_requests/{create,accept/{id},
|
||||
reject/{id},cancel/{id},list,get/{id}}`, wire camelCase, action-style. `services/bookingRequests/types.ts`
|
||||
derives from it.
|
||||
- **Mocked client-side:** `services/bookingRequests` via `bookingRequestsMockApi` (**USE_BOOKING_REQUESTS_MOCK
|
||||
=true, primary**) — a shared in-memory state machine so create → nurse inbox → accept/reject → C5-poll →
|
||||
lazy expiry all demo end-to-end (b8 is live, but its inputs — search/patients/addresses — are themselves
|
||||
mock-primary; and the DTO omits `variantPrice`, REQ-013). Real `bookingRequestsClientApi` maps the b8
|
||||
contract 1:1; swap is one flag. Recorded in the phase report (not mocks-registry — backend DI seams only).
|
||||
- **Gate:** npm run check green · npm run test:ci green (173 tests, +8) · npm run build green with
|
||||
NEXT_PUBLIC_API_URL set (the only prerender failure without env is the pre-existing "Missing .env
|
||||
variable!" — hits the existing `/fa/search` too, unrelated to f7).
|
||||
- **Requests filed:** frontend/requests/for-backend.md — yes (REQ-013 variantPrice on the DTO + nurse avatar;
|
||||
REQ-014 inbox list-item variantLabel + patient age).
|
||||
|
||||
## frontend-phase-6-b7 — Search & discovery (find a verified, same-gender nurse) — 2026-07-09
|
||||
- **Shipped:** the family discovery slice — `services/search` (types/keys/constants/apis/hooks + a shared
|
||||
`filterParams.ts` C1↔C2 URL serializer) and screens **C1** `/search` (reused category grid + f3 region
|
||||
|
||||
Reference in New Issue
Block a user