namespace YesChef.Api.Entities; /// /// A family's override of a global . Each non-null field /// replaces the global value when the family views the catalog. Composite key /// (, ) — at most one override /// per family per product. /// public class FamilyProductOverride { public int FamilyId { get; set; } public Family Family { get; set; } = null!; public int ProductId { get; set; } public Product Product { get; set; } = null!; public string? Name { get; set; } public string? Brand { get; set; } public string? Notes { get; set; } // Nullable so "inherit global" (null) is distinguishable from // "explicitly None / any unit" (UnitCategoryFlags.None). public UnitCategoryFlags? AllowedUnitCategories { get; set; } // Null = inherit Product.DefaultSection. Non-null = family override of // the recommended section name. public string? DefaultSection { get; set; } public DateTime UpdatedAt { get; set; } = DateTime.UtcNow; }