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

Able to create Web Content with same ID if the article is in a different folder with different version

    Details

      Description

      Steps to reproduce

      Case1:
      1. Set the following in portal-ext.properties (or in case of master, set it in System Settings / Web Content administration):

      journal.article.force.autogenerate.id=false
      

      2. Create a web content article with manual ID 'ONE' and title 'Article1' and publish it
      3. Open this article and edit it, publish the changes
      4. Open this article again, click on 'Version History' and delete version 1.0
      5. Create a Web Content Folder and open it
      6. Create a Web Content Article with article ID 'ONE' and title 'Article2' and publish it
       Expected Result: The portal should display an error message stating that an article already exist with this ID.
       Actual Result: Article is created and now you have two articles with the same ID, one in the root folder, one in the just created folder. If you open the version history of either web content, you will see that the article with title 'Article2' is now version 1.0, and 'Article1' is 1.1. If you move either one to the recycle bin, both will be removed.

       If you don't remove version 1.0 in step 4, it works as expected.

      Note: In point 5. If one adds an article with the same ID in root folder. Then the article is created with version 1.0 (maintaining version 1.1) in history

      Case2: (I'm 99% sure that it is the same issue, so I didn't create a separate LPP yet)
      1. Set the following in portal-ext.properties (or in case of master, set it in System Settings / Web Content administration):

      journal.article.force.autogenerate.id=false
      

      2. Create a web content article with manual ID 'ONE' and title 'Article1' and publish it
      3. Open this article and edit it, publish the changes
      4. Export Web Contents into a LAR file without version history
      5. Create a Web Content Folder and move the article into it
      6. Edit this article again and publish it (version 1.2)
      7. Export again the Web Contents into a LAR file without version history (you have two LARs now)
      8. On a different server, import the first LAR file, then the second.
       Expected Result: The article should not exist in the root folder as it has been moved to the folder
       Actual Result: You will now have two articles with the same ID, one in the root folder and one in the folder you created in step 5.

       reproduced with portal-154-6210
       reproduced on ee-6.2.x @ cdc1691c40ae12c1d3bab0b3d74458482057de2d
       reproduced on master @ 5bcb48f044688693aa3f71d11fdab69eb10be97b

        Attachments

          Activity

            People

            Assignee:
            hong.zhao Hong Zhao (Inactive)
            Reporter:
            rimi.saadou Rimi Saadou (Inactive)
            Participants of an Issue:
            Recent user:
            Joel Garman
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Days since last comment:
              3 years, 24 weeks, 3 days ago

                Packages

                Version Package
                7.0.0 DXP FP88
                7.0.10.13 DXP SP13
                7.0.X
                7.1.0 M1
                7.1.X
                Master