using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations.Schema; namespace Fitness_core_BE.Models { /// Many-to-many join: which FacilityClass(es) a CustomerPlan is sold against. A /// plan with no rows here is an ordinary gym plan, completely unaffected by the Classes /// feature -- CustomerPlan.GrantsGymAccess is never consulted for it. Structurally identical /// to CustomerPlanFacility. public class CustomerPlanClass { [Key] public Guid CustomerPlanClassId { get; set; } public Guid FKCustomerPlanId { get; set; } [ForeignKey(nameof(FKCustomerPlanId))] public CustomerPlan CustomerPlan { get; set; } = null!; public Guid FKFacilityClassId { get; set; } [ForeignKey(nameof(FKFacilityClassId))] public FacilityClass FacilityClass { get; set; } = null!; } }