namespace HoneyBox.Admin.Business.Models.Goods;

/// <summary>
/// 奖品等级列表请求
/// </summary>
public class PrizeLevelListRequest : PagedRequest
{
    /// <summary>
    /// 等级名称（模糊搜索）
    /// </summary>
    public string? Title { get; set; }
}

/// <summary>
/// 奖品等级响应
/// </summary>
public class PrizeLevelResponse
{
    /// <summary>
    /// 等级ID
    /// </summary>
    public int Id { get; set; }

    /// <summary>
    /// 等级标题
    /// </summary>
    public string Title { get; set; } = string.Empty;

    /// <summary>
    /// 概率
    /// </summary>
    public decimal Pro { get; set; }

    /// <summary>
    /// 等级图片URL
    /// </summary>
    public string? ImgUrl { get; set; }

    /// <summary>
    /// 等级颜色
    /// </summary>
    public string? Color { get; set; }

    /// <summary>
    /// 特殊图片URL
    /// </summary>
    public string? SpecialImgUrl { get; set; }

    /// <summary>
    /// 排序值
    /// </summary>
    public int Sort { get; set; }

    /// <summary>
    /// 更新时间
    /// </summary>
    public DateTime? UpdatedAt { get; set; }

    /// <summary>
    /// 关联奖品数量
    /// </summary>
    public int PrizeCount { get; set; }
}

/// <summary>
/// 创建奖品等级请求
/// </summary>
public class PrizeLevelCreateRequest
{
    /// <summary>
    /// 等级标题
    /// </summary>
    public string Title { get; set; } = string.Empty;

    /// <summary>
    /// 概率
    /// </summary>
    public decimal Pro { get; set; }

    /// <summary>
    /// 等级图片URL
    /// </summary>
    public string? ImgUrl { get; set; }

    /// <summary>
    /// 等级颜色
    /// </summary>
    public string? Color { get; set; }

    /// <summary>
    /// 特殊图片URL
    /// </summary>
    public string? SpecialImgUrl { get; set; }

    /// <summary>
    /// 排序值
    /// </summary>
    public int Sort { get; set; }
}

/// <summary>
/// 更新奖品等级请求
/// </summary>
public class PrizeLevelUpdateRequest
{
    /// <summary>
    /// 等级标题
    /// </summary>
    public string Title { get; set; } = string.Empty;

    /// <summary>
    /// 概率
    /// </summary>
    public decimal Pro { get; set; }

    /// <summary>
    /// 等级图片URL
    /// </summary>
    public string? ImgUrl { get; set; }

    /// <summary>
    /// 等级颜色
    /// </summary>
    public string? Color { get; set; }

    /// <summary>
    /// 特殊图片URL
    /// </summary>
    public string? SpecialImgUrl { get; set; }

    /// <summary>
    /// 排序值
    /// </summary>
    public int Sort { get; set; }
}

/// <summary>
/// 奖品等级简单选项（用于下拉选择）
/// </summary>
public class PrizeLevelOptionResponse
{
    /// <summary>
    /// 等级ID
    /// </summary>
    public int Id { get; set; }

    /// <summary>
    /// 等级标题
    /// </summary>
    public string Title { get; set; } = string.Empty;

    /// <summary>
    /// 等级颜色
    /// </summary>
    public string? Color { get; set; }
}

/// <summary>
/// 根据盒子类型获取奖品等级选项请求
/// </summary>
public class PrizeLevelOptionsByTypeRequest
{
    /// <summary>
    /// 盒子类型
    /// 1=一番赏, 2=无限赏, 3=擂台赏, 5=积分赏, 6=限时活动, 8=领主赏, 9=连击赏, 10=商城赏, 11=自制赏, 15=福利屋, 16=翻倍赏, 17=外卖盒子
    /// </summary>
    public int GoodsType { get; set; }

    /// <summary>
    /// 是否为子奖品（宝箱内奖品）
    /// </summary>
    public bool IsChildPrize { get; set; } = false;
}
