Affects Version/s: 7.1.X, Master
If a site or site template contains a page template with one or more pages based on it, then they cannot all be imported into another site with a single import, despite all being present in the LAR.
This occurs because of a validation step that occurs for all page templates, which was necessary in previous versions when page templates could not be scoped to the site, but is now unnecessary since they can be included in the same import.
Steps to reproduce:
- Create a new site or site template
- Within the new site or site template, create a new page template collection
- Add a new Widget page template within the new collection
- Add a new page based on the Widget page template
- Export the site/site template with all pages and content as a LAR
- Note: if using a site template, this may need to be done from the Site Templates page in the Control Panel (preferably deleting other site templates as well) rather than from the Export page in the site template itself, because exporting directly from the site template will not include pages in the export
- Delete the site/site template
- Attempt to import the LAR again as a new site/site template (if applicable, creating a new, blank one to import into)
Expected result: the import is successful
Actual result: the import fails with a PortletDataException
Reproduced in master: 25540721e7a967c7780a7304eea39b4e82d366ea
Reproduced in 7.1.x: 982701959d248322a8ece2560ea8835f9ec07ac9