using MediatR;

namespace MembershipService.API.Application.Queries;

/// <summary>
/// EN: Query to get all level definitions.
/// VI: Query để lấy tất cả level definitions.
/// </summary>
public class GetLevelDefinitionsQuery : IRequest<IEnumerable<LevelDefinitionDto>>
{
    /// <summary>
    /// EN: Whether to include inactive levels.
    /// VI: Có bao gồm levels không active không.
    /// </summary>
    public bool IncludeInactive { get; set; } = false;
}

/// <summary>
/// EN: Level definition DTO.
/// VI: DTO level definition.
/// </summary>
public class LevelDefinitionDto
{
    public Guid Id { get; set; }
    public int LevelNumber { get; set; }
    public string Name { get; set; } = null!;
    public int RequiredExp { get; set; }
    public string? Description { get; set; }
    public string? IconUrl { get; set; }
    public string? BadgeColor { get; set; }
    public bool IsActive { get; set; }
    public IEnumerable<LevelBenefitDto> Benefits { get; set; } = Enumerable.Empty<LevelBenefitDto>();
}

/// <summary>
/// EN: Level benefit DTO.
/// VI: DTO level benefit.
/// </summary>
public class LevelBenefitDto
{
    public Guid Id { get; set; }
    public string BenefitType { get; set; } = null!;
    public string BenefitValue { get; set; } = null!;
    public string? Description { get; set; }
    public bool IsActive { get; set; }
}
