Mapping OneToMany Nhibernate

0

Hello,

In an application has a class that I need to do a OneToMany mapping, this parent class will be responsible for performing the persistence of the child class. My question is, I did the mapping of the Bag in the parent class as below:

        Bag(x => x.ItensMovimentacaoBanco, x =>
        {
            x.Cascade(Cascade.Persist);
            x.Key(y =>
            {
                y.Column("MovimentacaoBancoId");
                y.NotNullable(true);
            });
            x.Lazy(CollectionLazy.Lazy);
        }, x => x.OneToMany());

Now I also need to do the ManyToOne mapping in the child class?

    
asked by anonymous 04.09.2015 / 21:58

1 answer

0

The answer is yes, as per the comment and this link: link

    
28.12.2015 / 12:31