• 默认情况下,AutoMapper 基于相同的字段名映射,并且是 不区分大小写 的
    1. var config = new MapperConfiguration(cfg =>
    2. {
    3. cfg.CreateMap<Foo, FooDto>();
    4. cfg.SourceMemberNamingConvention = new PascalCaseNamingConvention();
    5. cfg.DestinationMemberNamingConvention = new LowerUnderscoreNamingConvention();
    6. });