OroPlatform Forums

Covering OroPlatform topics, including community updates and company announcements.

Forums Forums OroPlatform Want to override ProductBundle's validation.yml

This topic contains 2 replies, has 2 voices, and was last updated by  Andrey Yatsenko 4 years, 6 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
  • #40682

    Shahriar
    Participant

    I want to override ProductBundle’s validation.yml to allow validation for a 3rd product type, “giftcard”.

    I have tried these but it still have a violation of product type not being valid:

    Trial 1:

    Trial 2:

    Please advise what am I doing wrong or if there is a way to replace that callback function with my custom array?

    We want to avoid overriding the Product Entity with another custom type. Thanks.

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

    Shahriar
    Participant

    Just to clarify, the First screenshot is how validation.yml is set in Oro’s ProductBundle.

    The Trial screenshots are how I tried to overwrite from my own custom bundle’s validation.yml.

    • This reply was modified 4 years, 6 months ago by  Shahriar.
    #40692

    Andrey Yatsenko
    Moderator

    You can override it with the validation groups. But you should note that there is a lot of code that relies on the fact that there are only two types of products at the system, so it can be hard to override other parts, as this functionality is not intended to be extensible.

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

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

Back to top