MembershipAddOns table

The MembershipAddOns table in the FitStack - V2 schema has 12 columns, keyed by Id, with 3 foreign keys to GymClientSubscriptions, GymProducts and GymProductVariants.

Glossary: Add-on. A locker rental attached to a Membership.

Columns (12)

Columns of the MembershipAddOns table
ColumnTypeConstraintsDescription
Iduuidprimary key, not null
MembershipIduuidnot null, references GymClientSubscriptions.IdCASCADE.
ProductIduuidnot null, references GymProducts.IdKind Rental or Service with a RecurringInterval.
VariantIduuidnot null, references GymProductVariants.Id
PriceCentsSnapshotintegernot null
StripeSubscriptionItemIdtextAn item on the Membership's Stripe subscription, so it bills together.
StartedAttimestamp with time zonenot null
EndedAttimestamp with time zone
CreatedAttimestamp with time zonenot null
ModifiedAttimestamp with time zone
IsDeletedbooleannot null
DeletedAttimestamp with time zone

Indexes (1)

  • (MembershipId, EndedAt) (IX_MembershipAddOns_MembershipId_EndedAt)

Relationships