ExamCourseAppService.cs 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. using YBEE.EQM.Core;
  2. namespace YBEE.EQM.Application;
  3. /// <summary>
  4. /// 监测科目管理服务
  5. /// </summary>
  6. public class ExamCourseAppService : IDynamicApiController
  7. {
  8. private readonly IExamCourseService _examCourseService;
  9. public ExamCourseAppService(IExamCourseService examCourseService)
  10. {
  11. _examCourseService = examCourseService;
  12. }
  13. /// <summary>
  14. /// 添加监测科目
  15. /// </summary>
  16. /// <param name="input"></param>
  17. /// <returns></returns>
  18. public async Task Add(AddExamCourseInput input)
  19. {
  20. await _examCourseService.Add(input);
  21. }
  22. /// <summary>
  23. /// 更新监测科目
  24. /// </summary>
  25. /// <param name="input"></param>
  26. /// <returns></returns>
  27. public async Task Update(UpdateExamCourseInput input)
  28. {
  29. await _examCourseService.Update(input);
  30. }
  31. /// <summary>
  32. /// 删除监测科目
  33. /// </summary>
  34. /// <param name="input"></param>
  35. /// <returns></returns>
  36. public async Task Del(BaseId input)
  37. {
  38. await _examCourseService.Del(input);
  39. }
  40. /// <summary>
  41. /// 根据ID获取监测科目信息
  42. /// </summary>
  43. /// <param name="id"></param>
  44. /// <returns></returns>
  45. public async Task<ExamCourseOutput> GetById(int id)
  46. {
  47. return await _examCourseService.GetById(id);
  48. }
  49. /// <summary>
  50. /// 查询监测年级列表
  51. /// </summary>
  52. /// <param name="input"></param>
  53. /// <returns></returns>
  54. public async Task<List<ExamCourseOutput>> QueryList(QueryExamCourseInput input)
  55. {
  56. return await _examCourseService.QueryList(input);
  57. }
  58. }