using TakeoutSaaS.Domain.Tenants.Enums; using TakeoutSaaS.Shared.Abstractions.Entities; namespace TakeoutSaaS.Domain.Tenants.Entities; /// /// 平台提供的租户套餐定义。 /// public sealed class TenantPackage : AuditableEntityBase { /// /// 套餐名称,展示给租户的简称。 /// public string Name { get; set; } = string.Empty; /// /// 套餐描述,包含适用场景、权益等。 /// public string? Description { get; set; } /// /// 套餐分类(试用、标准、旗舰等)。 /// public TenantPackageType PackageType { get; set; } = TenantPackageType.Standard; /// /// 月付价格,单位:人民币元。 /// public decimal? MonthlyPrice { get; set; } /// /// 年付价格,单位:人民币元。 /// public decimal? YearlyPrice { get; set; } /// /// 允许的最大门店数。 /// public int? MaxStoreCount { get; set; } /// /// 允许创建的最大账号数。 /// public int? MaxAccountCount { get; set; } /// /// 存储容量上限(GB)。 /// public int? MaxStorageGb { get; set; } /// /// 每月短信额度上限。 /// public int? MaxSmsCredits { get; set; } /// /// 每月可调用的配送单数量上限。 /// public int? MaxDeliveryOrders { get; set; } /// /// 权益明细 JSON,记录自定义特性开关。 /// public string? FeaturePoliciesJson { get; set; } /// /// 是否仍启用(平台控制)。 /// public bool IsActive { get; set; } = true; /// /// 是否对外可见(展示页/套餐列表可见性)。 /// public bool IsPublicVisible { get; set; } = true; /// /// 是否允许新租户购买/选择(仅影响新购,不影响已订阅租户)。 /// public bool IsAllowNewTenantPurchase { get; set; } = true; /// /// 发布状态(草稿/已发布)。 /// public TenantPackagePublishStatus PublishStatus { get; set; } = TenantPackagePublishStatus.Draft; /// /// 是否推荐展示(运营推荐标识)。 /// public bool IsRecommended { get; set; } /// /// 套餐标签(用于展示与对比页,如:推荐/性价比/旗舰)。 /// public string[] Tags { get; set; } = []; /// /// 展示排序,数值越小越靠前。 /// public int SortOrder { get; set; } = 0; }