0 votes

ORM Designer 2.1.7.680, MVC: Symfony2, ORM: Doctrine2

The definition that is generated by the many-to-many wizard is incorrect. Patching the .ormdesigner2 XML corrects it.

Output XML (in ManyToManyTest.ormdesigner2):

    <many-to-many mn-entity="SampleEntity2OtherSample" uuid="3a2895ec-5cf5-4c05-bb6c-296be3f4e33c">
  <many-to-many-entity name="OtherSample" owning-side="true" alias="OtherSample" uuid="e96ee5a5-f295-4fc5-82a1-8b9c7110bb79"/>
  <many-to-many-entity name="SampleEntity" owning-side="false" alias="SampleEntity" uuid="a50a3bb8-c1b4-4751-95dc-f667a98a44fd">
    <many-to-many-field from="SampleEntity_id" to="id"/>
    <many-to-many-field from="OtherSample_id" to="id"/>
  </many-to-many-entity>
</many-to-many>

(both fields are set on the Inverse Side)

Visual cue:
Visual

in Solved by (3.6k points)
recategorized by

Are you sure this is many-to-many created in version 680? We already fix this bug (it was in release where we changed a lot of stuff about associations).

Can you please try to create new many to many relation and check output xml? Thanks

I created the association with 680, but the model file might be older. I will check with a brand new file.

Edit: Yup, still there!

Demo file:

<?xml version="1.0"?>
<orm-designer version="2.1.7.680" name="Reproducing307" mvc="Symfony2" orm="Doctrine2" uuid="abada5f6-8d5c-47e9-a04c-fec8912556fd">
  <module name="MainModule" uuid="e48306ab-1d4f-4461-a3a5-bd8f79effd8b">
    <entity name="OtherEntity" uuid="beeb0014-a080-4e8c-b0f2-6e6e9b3b49d3">
      <field name="id" type="bigint" required="true" primary="true" auto-increment="true" uuid="765f7787-1f36-4d37-b7f4-7d24a6ebc1fc"/>
    </entity>
    <entity name="SampleEntity" uuid="6e50eb24-e18f-429e-9032-846807b4c0e1">
      <field name="id" type="integer" required="true" unique="true" primary="true" auto-increment="true" uuid="a7c36b7b-af63-4133-bfe7-0e129e161d88"/>
      <field name="name" type="string" size="255" uuid="5d86b24a-    f6e2-4575-8c9c-2160eb958063"/>
    </entity>
  </module>
  <visual-data>
    <entity uuid="6e50eb24-e18f-429e-9032-846807b4c0e1" position-x="10" position-   y="20"/>
    <project uuid="abada5f6-8d5c-47e9-a04c-fec8912556fd" size-x="0" size-x2="331"    size-y="0" size-y2="285"/>
    <entity uuid="beeb0014-a080-4e8c-b0f2-6e6e9b3b49d3" position-x="98" position-   y="147" size-x="0" size-x2="20" size-y="0" size-y2="20"/>
    <module uuid="e48306ab-1d4f-4461-a3a5-bd8f79effd8b" bk-color="4294375930" position-x="61" position-y="72" size-x="11" size-x2="220" size-y="22" size-y2="163"/>
  </visual-data>
</orm-designer>

Then just add a many-to-many-association between the two.

Found and fixed ;-)

1 Answer

0 votes
Best answer

This issue was fixed in latest version 2.1.7.681. You can download this version here http://support.orm-designer.com/31/download-orm-designer2-here

by Skipper developer (135k points)
selected by