Uploaded image for project: 'PUBLIC - Liferay Portal Community Edition'
  1. PUBLIC - Liferay Portal Community Edition
  2. LPS-127583

Saving documents having selection fields with no options wipes the entire document

    Details

      Description

      Description

      When creating a document, if you remove all the options of a selection field or use the default values and save, it will wipe the entire document. This only happens with simple fields, does not occur with Fieldsets and Metadata Sets.

       

      OBS: It is only reproducible in Document Types. Do not work in Fieldsets, Metadata Sets and Structures.

      Pre-conditions

      Steps to Reproduce

      1. Go to Product Menu > Content & Data > Documents and Media > Document Types;
      2. Create a new Document;
      3. Add some text fields;
      4. Save the document;
      5. Open the document;
      6. Add any type of selection field (Multiple selection, Single Selection, Select from List Grid);
      7. Delete all the options of the selection field;
      8. Save the document;

      Expected Result

      It should not delete the previous saved work. As in Fieldsets and Metadata Sets, a message explaining the error should appear: "Error: At least one option should be set for field Grid/Multiple Selection/Single Selection/Select from list". 

      Expected result (working with Fieldsets and Metadata Sets): Expected Result
      Actual Result

      Saving documents having empty or default option fields will delete the entire document, even the work that was saved before adding the option field is deleted.

      Video: Saving with selections field with no options wipes the entire document.mp4
      Reproduced In
      master: 12116cd8c2d842201e70ff16e0c41ce05969fc2a

        Attachments

          Activity

            People

            Assignee:
            brittney.nguyen Brittney Nguyen
            Reporter:
            erick.monteiro Erick Monteiro
            Participants of an Issue:
            Recent user:
            Tomáš Polešovský
            Engineering Assignee:
            Alejandro Tardín
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Days since last comment:
              34 weeks, 4 days ago

                Packages

                Version Package
                Master