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

Loss of WCM Images when publish content after an upgrade to DXP from early versions of 6.2

    Details

      Description

      DXP/7.0.x
      Steps to reproduce it:

      1. Startup a 6.2 EE version using a fix pack below than portal-87 (LPS-45541)
      2. Create an structure which contains a WCM image field.
      3. Create a template for that structure.
      4. Create a web content using that structure filling the WCM image field.
      5. Upgrade the portal to DXP (be sure to copy document library data)
      6. Startup the portal
      7. Edit the content (check that you can see the image preview before publishing)
      8. Publish the web content
      9. Edit the content again

      Results:
      You are unable to see the image preview

      Expect results:
      You are able to see the image preview.

      Master
      Steps to reproduce it:

      1. Startup a 6.2 EE version using a fix pack below than portal-87 (LPS-45541)
      2. Create an structure which contains a WCM image field.
      3. Create a template for that structure.
      4. Create a web content using that structure filling the WCM image field.
      5. Upgrade the portal to DXP (be sure to copy document library data)
      6. Check the field content in the journalArticle table:

      Results:
      You will get something like this:
      <?xml version="1.0"?>

      <root available-locales="en_US" default-locale="en_US">
      <dynamic-element name="images" type="image" index-type="keyword" index="0">
      <dynamic-content language-id="en_US" id="20470">/image/journal/article?img_id=20470&t=1490786012134</dynamic-content>
      </dynamic-element>
      </root>

      Expect results:
      The field instance-id is populated for image field:
      <?xml version="1.0"?>

      <root available-locales="en_US" default-locale="en_US">
      <dynamic-element name="images" type="image" index-type="keyword" instance-id="JIBf9ARC">
      <dynamic-content language-id="en_US"><![CDATA[

      {"groupId":"20182","name":"alberto chaparro.png","alt":"","title":"alberto chaparro.png","type":"journal","uuid":"0971ad07-ead9-ab94-ac38-bfdf1dfe10c0","resourcePrimKey":"20591"}

      ]]></dynamic-content>
      </dynamic-element>
      </root>

      Technical notes
      The problem here is that 6.2 version using a fix pack below than 87 (or any CE version) didn't include instance-id field for any dynamic-element. During the upgrade process JournalArticleImage was populated in com.liferay.journal.internal.upgrade.v1_0_0.UpgradeJournalArticleImage using random strings for instance-id element but the content wasn't updated so the web content edition doesn't work.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                steven.gao Steven Gao (Inactive)
                Reporter:
                alberto.chaparro Alberto Chaparro
                Participants of an Issue:
                Recent user:
                Csaba Turcsan
              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Days since last comment:
                  2 years, 18 weeks, 6 days ago

                  Packages

                  Version Package
                  7.0.0 DXP FP32
                  7.0.5 CE GA6
                  7.0.X
                  7.1.X
                  Master