Generate both collection and property

Discussion of open issues, suggestions and bugs regarding Entity Developer - ORM modeling and code generation tool
Post Reply
Posts: 1
Joined: Wed 24 Sep 2014 07:29

Generate both collection and property

Post by aroncox » Wed 24 Sep 2014 07:35

Using NHibernate template, Entity Developer 5.7.441

Is it possible to generate both the collection and the property for a foreign key relationship. For example our Manager table has a foreign key to the Office table, when I generate I get a 'public virtual Office Office' but do not get the OfficeCode property.

I realize this may be non-standard but I'd like both if possible (and even better if I could specify that the property was able to be generated as readonly).

Thank you for your help :)

Devart Team
Posts: 7968
Joined: Thu 14 Aug 2008 12:44

Re: Generate both collection and property

Post by Shalex » Fri 26 Sep 2014 15:24

Please open Model Settings (double click on the diagram surface) and turn on the "Include foreign key columns in the model" checkbox. After this, remove and readd Manager and Office tables in the model.

Post Reply