namespace HoneyBox.Model.Entities;

/// <summary>
/// 兑换码实体
/// </summary>
public class RedeemCode
{
    /// <summary>
    /// 主键ID
    /// </summary>
    public int Id { get; set; }

    /// <summary>
    /// 兑换码
    /// </summary>
    public string Code { get; set; } = string.Empty;

    /// <summary>
    /// 奖励类型: money=余额, integral=吧唧币, score=积分
    /// </summary>
    public string RewardType { get; set; } = string.Empty;

    /// <summary>
    /// 奖励数量
    /// </summary>
    public decimal RewardAmount { get; set; }

    /// <summary>
    /// 状态: 0=未使用, 1=已使用
    /// </summary>
    public byte Status { get; set; }

    /// <summary>
    /// 使用者用户ID
    /// </summary>
    public int? UsedByUserId { get; set; }

    /// <summary>
    /// 使用时间
    /// </summary>
    public DateTime? UsedAt { get; set; }

    /// <summary>
    /// 过期时间
    /// </summary>
    public DateTime? ExpiredAt { get; set; }

    /// <summary>
    /// 创建时间
    /// </summary>
    public DateTime CreatedAt { get; set; }

    /// <summary>
    /// 备注
    /// </summary>
    public string? Remark { get; set; }
}
