using YBEE.EQM.Core;

namespace YBEE.EQM.Application;

/// <summary>
/// 添加抽样方案输入参数
/// </summary>
public class AddExamSampleInput
{
    /// <summary>
    /// 监测计划ID
    /// </summary>
    [Required]
    public int ExamPlanId { get; set; }

    /// <summary>
    /// 备注
    /// </summary>
    [StringLength(200)]
    public string Remark { get; set; } = "";


    /// <summary>
    /// 抽样配置
    /// {
    ///     percent: 40,
    ///     onlyOneClassStudentMin: 40,
    ///     gradeNoSampleStudentMin: 20,
    ///     classStudentMin: 25,
    ///     startPosition： 1,
    ///     interval: 2,
    ///     isExcludeSpecialStudent: true,
    ///     isGradeSeatNumberRandom: true,
    /// }
    /// </summary>
    [Required]
    public ExamSampleConfig Config { get; set; }
}
/// <summary>
/// 更新抽样方案输入参数
/// </summary>
public class UpdateExamSampleInput : AddExamSampleInput
{
    /// <summary>
    /// 主键
    /// </summary>
    [Required]
    public int Id { get; set; }
    /// <summary>
    /// 名称
    /// </summary>
    [Required, StringLength(100)]
    public string Name { get; set; }
    /// <summary>
    /// 全称
    /// </summary>
    [Required, StringLength(200)]
    public string FullName { get; set; }
    /// <summary>
    /// 简称
    /// </summary>
    [Required, StringLength(50)]
    public string ShortName { get; set; }
}
/// <summary>
/// 保存全抽班级ID输入参数
/// </summary>
public class SaveExamSampleAllClasses
{
    /// <summary>
    /// 主键
    /// </summary>
    [Required]
    public int Id { get; set; }
    /// <summary>
    /// 班级ID列表
    /// </summary>
    [Required]
    public List<long> ClassIds { get; set; } = new();
}
/// <summary>
/// 切换全抽班级输入参数
/// </summary>
public class SwitchExamSampleAllClassInput
{
    /// <summary>
    /// 抽样方案主键
    /// </summary>
    [Required]
    public int Id { get; set; }
    /// <summary>
    /// 班级ID
    /// </summary>
    [Required]
    public long SchoolClassId { get; set; }
    /// <summary>
    /// true增加，false取消
    /// </summary>
    [Required]
    public bool IsAdd { get; set; }
}
