ModelVoAdapt.cs 754 B

123456789101112131415161718192021
  1. namespace Util
  2. {
  3. public class ModelVoAdapt
  4. {
  5. public static void Map()
  6. {
  7. // TypeAdapterConfig<AppModule, GetAppModuleListVo>.NewConfig()
  8. // .Map(dest => dest.systemSupport, src => string.IsNullOrEmpty(src.systemSupport)
  9. // ? Array.Empty<string>()
  10. // : src.systemSupport.Split(',', StringSplitOptions.RemoveEmptyEntries));
  11. // TypeAdapterConfig<AddApiInfoDto, ApiInfo>.NewConfig()
  12. // .Map(dest => dest.apiParam, src => src.apiParam == null
  13. // ? new List<ApiParamObject>()
  14. // : Newtonsoft.Json.JsonConvert.DeserializeObject<List<ApiParamObject>>(src.apiParam));
  15. }
  16. }
  17. }