namespace YBEE.EQM.Application;

/// <summary>
/// 高中选科组合管理服务
/// </summary>
[ApiDescriptionSettings(Name = "base-course-comb")]
[Route("base/course/comb")]
public class CourseCombAppService : IDynamicApiController
{
    private readonly ICourseCombService _courseCombService;
    public CourseCombAppService(ICourseCombService courseCombService)
    {
        _courseCombService = courseCombService;
    }

    /// <summary>
    /// 根据ID获取高中选科组合
    /// </summary>
    /// <param name="id"></param>
    /// <returns></returns>
    public async Task<CourseCombOutput> GetById([FromQuery][Required] short id)
    {
        return await _courseCombService.GetById(id);
    }
    /// <summary>
    /// 获取所有高中选科组合
    /// </summary>
    /// <returns></returns>
    [AllowAnonymous]
    public async Task<List<CourseCombOutput>> GetAllList()
    {
        return await _courseCombService.GetAllList();
    }
}
