OroPlatform Forums

Covering OroPlatform topics, including community updates and company announcements.

Forums Forums OroPlatform OroPlatform – Programming Questions How to use AttachementBundle and File relation ?

This topic contains 4 replies, has 2 voices, and was last updated by  adriwan_kenoby 5 years, 7 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
  • #34586

    adriwan_kenoby
    Participant

    Hi Oro Team,

    I am trying to add an Image Relation to a custom entity.

    However I always have this exception

    Is their something missing in the documentation ?

    This is the entity

    Installer

    Migrations

    Type

    And View

Viewing 4 replies - 1 through 4 (of 4 total)
  • Author
    Replies
  • #34587

    Andrey Yatsenko
    Moderator

    The problem is that your entity is not configurable so you can’t add extra fields.

    Add @Config() annotation to News entity,
    run below commands:

    Reload the page, everything should work.

    #34588

    adriwan_kenoby
    Participant

    Already done,

    I had noticed that I had forgotten the @Config annotation.

    But still not working.

    #34592

    Andrey Yatsenko
    Moderator

    Try to revert the database state and run again app/console oro:platform:update --force with the new migration.

    For me, everything works with the above code and added @Config annotation.
    The problem probably that you are running platform:update on already installed migration and it’s not executed again.

    #34593

    adriwan_kenoby
    Participant

    Thank you Andrey. In fact it works.

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

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

Back to top