feat(web): checkout and order confirmation pages (#41) #126
No reviewers
Labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
primatekuntech/kws!126
Loading…
Reference in a new issue
No description provided.
Delete branch "feat/41-checkout-page"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
What
Checkout for the ticket site (web only, no Go changes). Refs #41.
/checkout: shows the server-priced cart lines, a required Promo code field, and Place order. Promo code is the only "payment" for now (payment_method: "wallet"), so Place order stays disabled until a code is entered. Other payment methods are parked./orders/:id: confirmation read fromGET /v1/me/transactions/{id}. A free sale shows as completed. A pending sale shows a fixed "cannot take payment yet" message with the Nairobi expiry. Expired, unknown-currency and not-found cases have their own texts.useCheckout: oneIdempotency-Keyper trimmed code, kept for retries and replaced after a 201. Cancels in-flight cart queries and empties the cart cache after a 201. Every non-201 outcome invalidates["cart"], so a stale cart cannot place a second order.cart/LineInfo.tsx, a Checkout link on the cart page,nairobiDateTimeindates.ts.deploy/dev-idp/seed-promo.sql(codeE2E-FREE, 100%) and a real-IdP test ine2e-idp/cart.spec.ts. The API needsKWS_RATE_LIMIT=offfor it. README and CLAUDE.md Layout updated.e2e-idp; focus moves to the pending status; navigation usesreplace; an unmount guard (StrictMode-safe) stops state updates after leaving.Not included (agreed): seats, tickets/QR, promo preview, customer cancel, other payment methods.
Reviews
Per-task reviews approved. Whole-branch dual pass: Pass 1 (ponytail) and Pass 2 (correctness, opus). Pass 2's main finding (stale cart after a refusal could allow a second order) is fixed. Pass 1 re-check after the fix rounds: no Must fix.
Results
make cover: 91.3% (minimum 80%). Go is unchanged, so this is the same figure as on main.scripts/web-e2e.sh: 124 passed, 46 skipped (run before the last test-only commit).pnpm --filter @kws/ticket e2e:idp: 7 passed against a local API (rate limit off). Not in CI.Known / accepted
expires_at./checkoutand/orders/x(320px / 44px targets).E2E-FREEseed is dev-only and has no database guard.Not verified
Real phones, Safari/Firefox, Zitadel, and the real-IdP journey in CI.
🤖 Generated with Claude Code