0 votes

The ability to specify associations in ORM Designer works fine when the entity that I am associating to is within the same project. Please see attachment.
Image caption

In real life, however, I often need to associate to an entity that lives in a different Symfony2 bundle and so, I must manually edit my entity files after I have created them in ORM Designer so I can update the targetEntity property to the namespace of the entity that I wish to associate to.

Can you add a way to specify the path/namespace to an entity so I may make associations to entities that live outside of the current ORM Designer project? This would be a great boost to my ability to be even more productive through ORM Designer. Thanks.

closed with the note: Martin correctly pointed out that the functionality already exists in ORM Designer.
in Solved by (380 points)
recategorized by

1 Answer

+1 vote
Best answer

The architecture of ORM Designer allows to model several bundles in one project. What might be little confusing is that the bundles are called modules in ORM Designer.
Modules/bundles inside one project can have different export paths and different namespaces etc. If you split the project to modules, you can store each module separately in separate file and share modules/bundles between projects.
How to do this is described in more detail in our documentation:
http://help.orm-designer.com/en/shared-modules

Because this functionality is in place, ORM Designer does not allow to build associations leading out of the current project.

If you for some reason, cannot use this built in modules/bundles functionality, you can simulate the external entities by creating a fictional module, populated with the entities you need to create the relations to. Then you set up your modules to export as usual, but the fictional module will have no export location set up. The fictional module information will not be exported, and the relations will point to proper entities already in place.

by Skipper developer (74.8k points)
selected by

Thanks for the reply, Martin.

I will try your suggestions tomorrow. If everything works as you've described, I'll mark your reply as an accepted/best answer.

Thanks.

Actually, I went and tried it now and yes, this is what I needed. Thanks for pointing it out.

Regards,
MD

I'm glad I could help. We are planning to rename the modules to bundles in the near future, because you and few other customers brought to our attention that the name might be misleading for the Symfony users.