Previously two hand-maintained price lists (API COMPLIANCE_SERVICES + site SERVICE_META) drifted apart -- that is how the healthcare +$200 raise charged $399 while displaying $599. Eliminate the drift class entirely: - Move the catalog to api/src/service-catalog.ts (the authority; checkout charges from it). compliance-orders.ts imports it. - scripts/gen-service-catalog.mjs generates site/src/lib/service-catalog.generated.ts from the API source. intake_manifest.ts re-exports SERVICE_META from it, so all ~60 site pages keep working unchanged. - deploy.sh regenerates + drift-checks before building (site build context is ./site only and cannot read ../api, so generation happens host-side). - scripts/check-service-catalog-drift.mjs fails the build if the generated file ever diverges from the API (verified: passes aligned, fails on mismatch). To change a price now, edit ONE file: api/src/service-catalog.ts. |
||
|---|---|---|
| .. | ||
| lib | ||
| middleware | ||
| routes | ||
| config.ts | ||
| create-admin.ts | ||
| db.ts | ||
| email.ts | ||
| erpnext-client.ts | ||
| fx.ts | ||
| index.ts | ||
| sanctions.ts | ||
| service-catalog.ts | ||