feat(admin): move the /pricing publish switch into the Stripe tier catalog mapping (BUNYIP-524) #520
Loading…
Reference in a new issue
No description provided.
Delete branch "feat/BUNYIP-524-pricing-switch-in-catalog-mapping"
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
Moves the public
/pricingpublish switch (pricing_enabled) out of the Pricing tiers page and into the Tier catalog mapping on the Stripe page, so the switch lives with the price bindings it depends on. Finishes the BUNYIP-417 consolidation of all Stripe config under one nav entry.Why
The publish switch sat on
/admin/tier-settings, while the price-to-tier bindings that decide what/pricingcan even advertise sit on/admin/stripe. An admin who had just mapped prices had to leave for another page to turn the page on, and the switch was nowhere near what it controlled.Changes
pricing_enabledso it survives save + reload, plus the live pricing status directly under it (published tiers in a success box, or one error box per reason it is not publishing, or a load-failure note). One Save catalog mapping persists the price bindings and the publish switch together. The checkbox is authoritative (absent = off), so it is always sent, unlike the price ids whose omission means "keep".pricing_enabled, so saving slots/trials there can no longer silently turn the pricing page off. No second toggle for the same field remains.pricing_status_blockmoves fromtier_settings.rstostripe.rsnext to the switch it now describes. The tier-settings resolved-amount block and its Stripe-price fetch are removed (the catalog dropdowns already show each tier's resolved amount). Switch + status tests move to exercisestripe_catalog_section.Verification
just check-containergreen (fmt + clippy -D warnings + workspace tests, 248 web tests pass).Out of scope
The public
/pricingpage layout/content and any Products/Prices list behaviour.🤖 Generated with Claude Code
https://claude.ai/code/session_01GkNbvEq6awuMRULFCiYKe3