MapperGenerator icon indicating copy to clipboard operation
MapperGenerator copied to clipboard

mapping

Open yuzd opened this issue 4 years ago • 1 comments

 public class PersonEntity
    {
        public int Id { get; set; }
        public string Name { get; set; }
        public string Age { get; set; }
    }

 [Mapping(typeof(PersonEntity),IgnoreNotMatch = true)] // if add true will ignore does not matched? how about it?
    public class PersonViewModel
    {
        public int Id { get; set; }
        public string Name { get; set; }
        public string Age { get; set; }
    }

Can’t the field(Age) be ignored if they don’t match?

image

yuzd avatar Dec 26 '20 11:12 yuzd

I think it would be nice if we plug a ignore attribute upon the property?

robersonliou avatar Dec 26 '20 16:12 robersonliou