Uploaded image for project: 'CMS'
  1. CMS
  2. CMS-9993

[Content] Impossible to override global validators

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • 4.3.0
    • 4.2.3, 4.3.0
    • None
    • None
    • 4.3 RC1

      Steps to reproduce :

      1. Create the file to override a content type : WEB-INF/param/content-types/org.ametys.web.default.Content.article.xml
      2. Add your own global validator in it :
        <?xml version="1.0" encoding="UTF-8"?>
        <cms:content-type xmlns:cms="http://www.ametys.org/schema/cms">
            <cms:global-validators>
                <cms:global-validator class="my.own.GlobalValidator"/>
            </cms:global-validators>
        </cms:content-type>
      3. Add a breakpoint into your validator in the method #validate(Content, Form, MetadataSet, Errors)
      4. Restart your CMS
      5. Edit a content (of the modified content type)
      6. Nothing happens while saving

          [CMS-9993] [Content] Impossible to override global validators

          Bérénice Maurel made changes -
          Status Original: Resolved [ 5 ] New: Closed [ 6 ]
          Laurence Aumeunier made changes -
          Resolution New: Fixed [ 1 ]
          Status Original: Ready to merge [ 10208 ] New: Resolved [ 5 ]
          Bérénice Maurel made changes -
          Status Original: Functional review OK [ 10207 ] New: Ready to merge [ 10208 ]
          Laurence Aumeunier made changes -
          Assignee Original: Laurence Aumeunier [ laurence ]
          Laurence Aumeunier made changes -
          Status Original: Available for review [ 10005 ] New: Functional review OK [ 10207 ]
          Laurence Aumeunier made changes -
          Status Original: In Progress [ 3 ] New: Available for review [ 10005 ]
          Laurence Aumeunier made changes -
          Fix Version/s Original: 4.2.12 [ 15582 ]
          Laurence Aumeunier made changes -
          Sprint New: 4.3 RC1 [ 40 ]
          Laurence Aumeunier made changes -
          Assignee New: Laurence Aumeunier [ laurence ]
          Laurence Aumeunier made changes -
          Status Original: Open [ 1 ] New: In Progress [ 3 ]

            Unassigned Unassigned
            bmaurel Bérénice Maurel
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: