Liferay 7.2 introduced the possibility of creating custom column layouts within Content Pages and adding widgets to them. Thanks to these functionalities, the large majority of cases where widget pages were being used is now better served by Content Pages. Furthermore Content Pages have powerful new capabilities including the use of fragments and personalization capabilities.
However, for customers upgrading from older versions of Liferay will already have many sites with pages created as Widget Pages. In order to benefit from some of the new features they need to manually convert the pages.
In this Story, we aim to provide a new action within Pages Administration that allows a user to automatically convert a widget page into a content page. In order for this to be possible the page must meet certain criteria that makes the conversion possible. In particular, out of the box, the limitations are as follows:
- The widget page must use one of the default layout templates
- The widget page must not be set as customizable by end users
- The widget page must not use the Nested Applications widget
These limitations must be documented in Liferay's official documentation.
In addition to the conversions supported out of the box, an API will be provided that allow 3rd party developers to support additional conversion cases. The API should have at least two methods (method names are tentative):
- isConvertible(): Determines whether the converter can convert this page. If no registered converter can convert a page, the "Convert" action will not appear in the UI.
- convert(): takes a layout object representation of the page and returns a representation of the converted page.
- Given an existing site with a widget page that does not meet the criteria, when the pages administrator clicks the three dot menu, then an option to convert the page should not appear.
- Given an existing site with a widget page that meets the criteria, when the pages administrator clicks the three dot menu, then an option to convert the page should appear.
- Given an existing site with a widget page that meets the criteria, when the pages administrator clicks the three dot menu and clicks the option to convert the page, then the page must be converted and the user should see the result in the list of pages along with a success message.
- Given an existing site with a widget page that meets the criteria, when the pages administrator clicks the three dot menu and clicks the option to convert the page and there is a failure, then the user should be presented with an explanatory error message and the page should continue as a Widget Page without any modification.
This story does not require design deliverables since it does not require new UIs
- Support for bulk conversion
- Support for widget pages with one or more Nested Applications widgets
- Support for previewing the result of the conversion from a Widget Page to a Content Page before accepting it as final
|Creates new util classes to convert widget pages into content pages||LPS-98351||Closed|
|Creates new interfaces to register layout converters||LPS-98616||Closed|
|Adds new action to convert layouts||LPS-98939||Closed|
|Product QA | Test Scenarios/Cases Creation||LPS-100288||Closed|
|Update layout row||LPS-100564||Closed|