OroCRM Forums

Covering OroCRM topics, including community updates and company announcements.

Forums Forums OroCRM OroCRM – Programming Questions Issue with creating manyToMany relation with custom entity

This topic contains 3 replies, has 3 voices, and was last updated by  klipach 9 years, 3 months ago.

Starting from March 1, 2020 the forum has been switched to the read-only mode. Please head to StackOverflow for support.

  • Creator
    Topic
  • #24925

    klipach
    Participant

    I need to create a new entity6 called specialization, with functionality similar to groups. Here is my migration code

    <?php

    namespace Acme\ContactBundle\Migrations\Schema\v1_0;

    use Doctrine\DBAL\Schema\Schema;
    use Oro\Bundle\EntityExtendBundle\Migration\Extension\ExtendExtension;
    use Oro\Bundle\EntityExtendBundle\Migration\Extension\ExtendExtensionAwareInterface;
    use Oro\Bundle\MigrationBundle\Migration\Migration;
    use Oro\Bundle\MigrationBundle\Migration\QueryBag;
    use Oro\Bundle\EntityExtendBundle\EntityConfig\ExtendScope;

    but after migration i get

    the same result i have when i create table via migrations and try match it to an entity via GUI.

    Can someone help me?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Author
    Replies
  • #24926

    Alexandr Smaga
    Participant

    Hello @klipach !

    Thank you for highlighting this! We are able to reproduce it and need to dive deeper and investigate root cause. We’ll keep you posted.

    #24927

    bcappello
    Participant

    @asmaga

    I too am able to reproduce this. Or something very similar. Hopefully some extra info can help debugging:

    This sort of works, if you can get the installer to actually run (run it, let it crash with the ReflectionException, do a app/console oro:mig:load –force, and then run it again. usually works). The front end lets you add tools to the account as you’d expect for a many-to-many, and it persists and re-hydrates correctly. Unfortunately, the account_tools field gets added to the Account form as well as the normal many-to-many tools field.

    Sadly I don’t understand the black magic of Oro extends even remotely enough to be able to debug this any further.

    oro/crm-application: dev-master @ 4a6a1df5e4f
    oro/platform: dev-master @ 2eae11b9d
    oro/crm: dev-master @ e24e5071b

    #24928

    klipach
    Participant

    No news? Is there another way to create a new entity with many to many relation?

Viewing 3 replies - 1 through 3 (of 3 total)

The forum ‘OroCRM – Programming Questions’ is closed to new topics and replies.

Back to top