Uploaded image for project: 'Nuxeo Platform'
  1. Nuxeo Platform
  2. NXP-19909

Fix saveDocument ArrayProperty Validation

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: 8.2
    • Fix Version/s: 7.10-HF12, 8.3
    • Component/s: Core

      Description

      When an ArrayProperty element other than the first is dirty during savedocument validation, the SimpleTypeField constraint on the element is not validated.

      The bug causing this issue appears to be found on line 471 in the following method of the Nuxeo 8.2 release of class

      DocumentValidationServiceImpl.java
      
      private List<ConstraintViolation> validateListTypeProperty(Schema schema, List<PathNode> path, Property prop, boolean dirtyOnly)
      
      

      The index++; statement on line 471 needs to be moved down one line so that it is outside the if condition. Then the index will be incremented during each for loop iteration.

        Attachments

          Activity

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - Not Specified
                Not Specified
                Logged:
                Time Spent - 15 minutes
                15m