AuditMapper.cs 544 B

12345678910111213141516
  1. using Furion.JsonSerialization;
  2. using YBEE.EQM.Core;
  3. namespace YBEE.EQM.Application;
  4. /// <summary>
  5. /// 审核记录映射
  6. /// </summary>
  7. public class AuditMapper : IRegister
  8. {
  9. public void Register(TypeAdapterConfig config)
  10. {
  11. config.ForType<ExamSpecialStudent, ExamSpecialStudentOutput>().Map(d => d.AuditList, s => JSON.Deserialize<List<AuditItem>>(s.Audits, null));
  12. config.ForType<ExamAbsentReplace, ExamAbsentReplaceOutput>().Map(d => d.AuditList, s => JSON.Deserialize<List<AuditItem>>(s.Audits, null));
  13. }
  14. }