using TakeoutSaaS.Shared.Abstractions.Entities;
namespace TakeoutSaaS.Domain.Membership.Entities;
///
/// 会员等级定义。
///
public sealed class MemberTier : MultiTenantEntityBase
{
///
/// 等级名称。
///
public string Name { get; set; } = string.Empty;
///
/// 所需成长值。
///
public int RequiredGrowth { get; set; }
///
/// 图标键。
///
public string IconKey { get; set; } = "user";
///
/// 主题色。
///
public string ColorHex { get; set; } = "#999999";
///
/// 升级规则类型(none/amount/count/both)。
///
public string UpgradeRuleType { get; set; } = "none";
///
/// 升级累计消费门槛。
///
public decimal? UpgradeAmountThreshold { get; set; }
///
/// 升级消费次数门槛。
///
public int? UpgradeOrderCountThreshold { get; set; }
///
/// 降级观察窗口天数。
///
public int DowngradeWindowDays { get; set; } = 90;
///
/// 是否默认等级。
///
public bool IsDefault { get; set; }
///
/// 等级权益(JSON)。
///
public string BenefitsJson { get; set; } = string.Empty;
///
/// 排序值。
///
public int SortOrder { get; set; } = 100;
}