ManiCandles/docs/PHASES.md

6.6 KiB
Raw Blame History

Frontend phases

Canonical implementation: this checkout from ssh://git@git.midastix.com:2212/internal/ManiCandles.git. The standalone frontend created earlier is superseded for ongoing development.

Phase Scope Acceptance gate
1 — Existing-site foundation Preserve branding, connect home/catalog/search/pagination/variants, staff login/me/logout/expiry, organization setup, health checks, API proxy and SPA routing Real published records and approved account; loading/empty/failure states; keyboard and responsive verification
2 — Commerce and administration Users/roles/audit, products/groups/variants/stock, addresses/cart/coupons/checkout/orders, recovery Permission failures, conflicts, exact totals and expiry; no simulated live payment
3 — Procurement and production Suppliers/materials, POs/receipts/QC, invoices/payments/documents, BOMs/batches/usage/packaging/costing, warehouse stock Supplier-to-finished-goods journey; independent review; partials/idempotency; stock invariants
4 — B2B Verification, price lists/MOQ, quotes/credit/samples/artwork, partner orders/payments, custom requests/reports Independent approvals, expiry, reversals and currency/account boundaries
5 — Growth and reporting Wishlist/reviews, campaigns/discounts, recovery/consent, blog/segments/forum, analytics/forecast/accounting Publication/moderation, consent, private data and report verification
6 — Complete UAT and release Dedicated deployment, disposable fixtures, role matrix, end-to-end scripts, accessibility/security review, defect retests and release/rollback runbook Critical journeys pass; no critical/high defects; owner acceptance

Phase 1 setup

No UAT organization/account has been provisioned in this session. On the deployed backend host with its intended UAT database, securely set ORGANIZATION_NAME, OWNER_NAME, OWNER_EMAIL and OWNER_PASSWORD (15–128 characters); run pnpm bootstrap:owner; record organizationId; remove bootstrap secrets. This is a one-time operation. If an owner already exists, retrieve that organization and provision approved staff instead. Never put database credentials or owner secrets in frontend environment files.

Enter the UUID at /connection, then credentials at /workspace. Published products and active variants are required for catalog checks. Phase 2 enables admin fixture setup. Live authenticated acceptance remains pending until provisioning.

Contract and quality

Reference: deployed /api/docs-json and backend source API guides. Storefront lists are arrays; detail includes decimal price strings, currency, attributes and nested groups. Zod validates returned shapes. Errors preserve code/requestId. React escapes API content; request timeout is 15 seconds. Session tokens/passwords are not persisted. UUID is configuration, not an authorization boundary; backend permissions remain authoritative.

Use existing MUI theme and React Query. Query keys include organization. Search is bounded to 100 characters; catalog pages contain 12 records and respect the API offset cap. No product-image mapping is invented. Nginx forwards /api/ to the known HTTPS upstream, verifies TLS and handles SPA deep links. No public owner/account creation is exposed.

Phase 2 implementation status — 12 October 2026

Customer and administration screens are implemented, with recovery, pricing, stock lifecycle and quality gates. See UAT-PHASE2.md and RELEASE-CHECKLIST.md. Authenticated UAT, container/ingress verification and production sign-off remain pending.

Phase 3 implementation status

  • Supplier and material directories support listing, creation and editing. Supplier material terms include SKU, lead time, minimum order quantity and unit price.
  • Staff can create a purchase order draft from supplier terms, review the backend price snapshots, then issue or cancel the draft.
  • Issued orders support partial goods receipts and final quality inspections, with exact accepted and rejected quantities and rejection reasons.
  • Inspected receipts support idempotent posting to a warehouse. Staff can review material balances and movement ledgers.
  • Issued orders support supplier invoices, payment records, reversals and voids. The backend enforces accepted quantities, outstanding balances and correction rules.
  • Private supplier PDFs support version uploads, independent review decisions, and authenticated downloads.
  • Production and packaging BOMs support separate revision histories, draft creation, material snapshots and confirmed activation.
  • Production batches support draft planning, start, completion, cancellation, and exact planned material quantities. Staff can log consumption and waste and reconcile the results against the plan.
  • Completed batches support packaging runs, production and packaging material debits, and receipt of good finished pieces into warehouse stock.
  • Costing, warehouse transfers and adjustments remain open.
  • Live acceptance requires an organization and procurement test users. Exercise read-only and manage roles, inactive suppliers and materials, mixed currencies, below-minimum quantities, price snapshots and purchase order state conflicts.
  • Supplier document UAT requires an uploader, an independent reviewer, and a read-only account. Through the deployed ingress, upload a valid PDF near the 2 MiB limit, verify that the uploader cannot decide on it, and check that a reader can download it only after approval.
  • BOM UAT should activate a second revision and confirm the previous revision becomes superseded. Repeat for the other BOM type and verify its active revision is independent. Check that inactive materials and stale drafts are rejected.