Fluent NHibernate Many-to-Many with Conventions
I have a many to many between two classes:
User
RetailOutlet
It seems that the conventions have specified the RetailOutlet as the owner for the relationship. So when I add a RetailOutlet to the collection on the User - nothing happens. I have to set both ends of the relationship.
So I try and override the mappings and:
if I specify the ManyToMany from both sides it tells me I've duplicated mappings
if I only specify it on one side it 开发者_运维知识库say something similar
I think I need to override the conventions and just tell Fluent to forget any conventions for both these classes.
I could be wrong, setting the ManyToMany in both mapping files is exactly what all the examples on the net do.
cheers
Fixed it. IAutoMappingOverride.
精彩评论