ssossossosso

Forums

Covering OroCRM topics, including community updates and company announcements.  Subscribe

Open-Source CRM software Forums OroCRM OroCRM – How do I? Questions Add ManyToOne Field to Address Entity via Migration Script

This topic contains 2 replies, has 2 voices, and was last updated by Hiro Hiro 2 years, 5 months ago.

  • Creator
    Topic
  • #6188
    Hiro
    Hiro
    Participant

    There is this table I created. The table contains the type of street (e.g. Road, Street, Tce etc) and its Id.

    I want to add extra field to Address Entity that has ManyToOne relationship as Street Type field.

    I have created a migration script using addManyToOneRelation(), but when I run the command like “php app/console oro:migration:load –dry-run –show-queries –bundles AcmeMyBundle” it says like I cannot add the field to non extended table “Oro\Bundle\AddressBundle\Entity\Address”.

    Is there a way to make Address Entity Table as Extended Table by extra code in my migration script?

Viewing 2 replies - 1 through 2 (of 2 total)
  • Author
    Replies
  • #6198

    Alexandr Smaga
    Participant

    Hello @hiro-ifactory!

    Unfortunately there is not possibility to make table extendable from third party code. We are planning to collect most needed for expanding entities and make them all extended.

    #6221
    Hiro
    Hiro
    Participant

    Thank you for the reply.
    I guess I have to add custom Address fields to my Entity for now.

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

You must be logged in to reply to this topic.