Club come entità principale, branding e fix infrastruttura streaming.
Introduce clubs con abbonamento, branding Active Storage e flusso registrazione società; corregge healthcheck MediaMTX (immagine distroless) e allinea dominio produzione matchlivetv.it. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -1,8 +1,8 @@
|
||||
module Billing
|
||||
class AssignPlan
|
||||
def self.call(team:, plan_slug:, status: "active", stripe_attrs: {})
|
||||
def self.call(club:, plan_slug:, status: "active", stripe_attrs: {})
|
||||
plan = Plan[plan_slug]
|
||||
sub = team.subscription || team.build_subscription
|
||||
sub = club.subscription || club.build_subscription
|
||||
attrs = { plan: plan, status: status }.merge(stripe_attrs.symbolize_keys)
|
||||
sub.assign_attributes(attrs)
|
||||
sub.save!
|
||||
|
||||
Reference in New Issue
Block a user