Merging Site Template and Site Changes¶
Once changes are made to a Site created from a Site Template, the Site Template and Site become unlinked. Any changes made to the Site Template from that point on are not propagated to the Site.
Merging App Preferences from Site Templates¶
Site Template Administrators can set preferences for apps on Site Template pages. When a Liferay Administrator creates a Site from a Site Template, the app preferences are copied from the Site Template’s apps, overriding any default app preferences. When merging Site Template and Site changes (e.g., when resetting), app preferences are copied from Site Template apps to Site apps. Only global app preferences or local app preferences which don’t refer to IDs are overwritten.
Merging App Data from a Site Template¶
Site Administrators can also add data to Site Template applications. For example, Site Template Administrators can add the Wiki app to a Site Template page and use the Wiki to create lots of articles. When a Liferay Administrator creates a Site from a Site Template, data is copied from the Site Template’s apps to the Site’s apps. The preferences of the Site’s apps are updated with the IDs of the copied data. For example, if a Site is created from a Site Template that has a Wiki app with multiple wiki articles, the wiki articles are copied from the Site Template’s scope to the Site’s scope and the Site’s Wiki app is updated with the IDs of the copied wiki articles.
App data (such as Message Board categories), Fragment-based pages, related resources, and permissions on resources are only copied from a Site Template to a Site when that site is first created based on the template. No changes made to these entities are propagated to the Site after the Site is created. Neither are such changes propagated to a Site by the Reset or Reset and Propagate features.
Resolving Site Template Merge Conflicts¶
In some cases, merging Site Template and Site changes fails. For example, if pages from a Site Template can’t be propagated because their friendly URLs are in conflict, Liferay DXP stops the merge after several unsuccessful attempts. To resolve this, follow these steps:
Note the indicated merge fail and fix your merge conflicts.
After you’ve resolved the conflicts, open the Product Menu and go to Configuration → Site Settings under the Site Menu.
Click the Reset and Propagate button to reset the merge fail count and attempts to propagate your site’s changes again.
This process can also be done with Page Template merging, which follows similar steps.