Closed dalibor-sanzeru closed 4 years ago
Is this repo Alive?
Yes, the repo is active, it's an open source project without paid members so no dedicated resources asdigned on this, all members are working on spare time with this.
I dont think it's possible to do without modification.
Hi @Tasteful. Not possible without modification means update AutoMapper.Collection code itself => new feature.
Correct? Thanks for answer.
From you 'InnerDto' you need to have a property reference to the 'OuterDto' to be able to do the lookup. It does not exists any way in AM to find the parent object during the mapping without the reference what I know about. Without support in AM it's hard to add support in AM.Collection.
From you 'InnerDto' you need to have a property reference to the 'OuterDto' to be able to do the lookup. It does not exists any way in AM to find the parent object during the mapping without the reference what I know about. Without support in AM it's hard to add support in AM.Collection.
Thanks for explanation.
Hi, Is scenario where EqualityComparison is not 1:1 between DTO <-> ENTITY in meaning entity needs to take some equality value from outer dto object? Entity itself identity has one column of parent and one own column. See class example.
Is there any way how to handle these ??? in EqualityComparison with given class structure?
CreateMap<InnerDto, InnerDb>().EqualityComparison((dto, o) => dto.Name== o.Name && dto.??? == o.OuterId);
THANKS FOR HELP.