Files
sure/test/models
Juan José Mata e0fb585bda Hide contribution payments from demo user(s) (#738)
* Hide payment contribution options from demo and manually created users

Demo data users and manually created users don't have stripe_customer_id
set on their family, so they should not see payment/contribution options.

Changes:
- Add can_manage_subscription? method to Family::Subscribeable that checks
  for presence of stripe_customer_id
- Guard Settings::PaymentsController to return 403 for users without
  stripe_customer_id
- Guard SubscriptionsController#show action (Stripe portal redirect) for
  users without stripe_customer_id
- Update settings navigation to hide the payment link when
  stripe_customer_id is not present
- Add tests for the new behavior

* Fix broken test

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-01-23 12:35:49 +01:00
..
2025-12-07 18:11:34 +01:00
2025-10-28 19:32:27 +01:00
2025-10-28 19:32:27 +01:00
2026-01-22 20:37:07 +01:00
2026-01-10 15:43:07 +01:00
2026-01-15 13:14:10 +01:00
2025-11-11 19:51:07 +01:00
2026-01-08 15:20:14 +01:00
2025-11-11 19:51:07 +01:00
2025-05-24 17:58:17 -04:00