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

GroupId is not replaced during import using Copy as New strategy

    Details

      Description

      Steps to Reproduce

      1. Go to Control Panel > Sites > Sites.  Create a Site1.
      2. Do the following within Site1:
        1. Go to Content > Documents and Media.  Create/upload a Basic Document.
        2. Go to Content > Web Content.  Select the Structures tab and create a structure with a Documents and Media field.
        3. Select the Templates tab (within Web Content) and a create template.  Under the Details section, select the Structure created in the previous step.
        4. Select the Web Content tab and create a web content using the Structure created in step 2.2.  In the Documents and Media field, select the document added in step 2.1.
        5. Go to Publishing > Export.  Leave the default values, export the site, and download the resulting LAR file.
      3. Go to Control Panel > Sites > Sites.  Delete Site1.
      4. Create a new Site2.
      5. Do the following within Site2:
        1. Go to Publishing > Import.  Select the LAR to import and click Continue.  In the Update Data section, select the "Copy as New" strategy and then click Import.
        2. Go to Content > Web Content.  Select the imported web content.

       Expected Result: The Documents and Media field in the imported Web Content contains the name of the document linked in Step 2.4.

       Actual Result:  The Documents and Media field in the imported Web Content is empty.

      The following output to the console is visible for 7.1.x.

      com.liferay.portal.kernel.repository.InvalidRepositoryIdException: No Repository exists with the primary key 1039091
              at com.liferay.portal.repository.RepositoryProviderImpl.checkRepository(RepositoryProviderImpl.java:355)
              at com.liferay.portal.repository.RepositoryProviderImpl.getRepository(RepositoryProviderImpl.java:277)
              at com.liferay.portlet.documentlibrary.service.impl.DLAppServiceImpl.getRepository(DLAppServiceImpl.java:3078)
              at com.liferay.portlet.documentlibrary.service.impl.DLAppServiceImpl.fetchFileEntryByUuidAndRepositoryId(DLAppServiceImpl.java:3048)
              at com.liferay.portlet.documentlibrary.service.impl.DLAppServiceImpl.getFileEntryByUuidAndGroupId(DLAppServiceImpl.java:1152)
              at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:153)
              at com.liferay.portal.spring.transaction.DefaultTransactionExecutor._execute(DefaultTransactionExecutor.java:203)
              at com.liferay.portal.spring.transaction.DefaultTransactionExecutor.execute(DefaultTransactionExecutor.java:94)
      

       

        Attachments

          Activity

            People

            • Assignee:
              support-lep@liferay.com SE Support
              Reporter:
              diana.lin Diana Lin (Inactive)
              Participants of an Issue:
              Recent user:
              Mária Kispál (Inactive)
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Days since last comment:
                47 weeks, 6 days ago

                Packages

                Version Package