For a website powered by Liferay EE 6.0 SP1, there will be cases where some pages will need to “share” the same instance of certain portlets, but other pages will have their own instances.
For example (contrived, but hopefully illustrative), consider a portlet with a preference that changes the portlet’s background color.
Suppose that we have the following pages (the portlet’s background color on that page follows the page name in this list):
Home (green) ├─ About (blue) │ └─ Contact (blue) ├─ Products (orange) │ ├─ AXL-900 (orange) │ └─ VCC-218 (orange) ├─ Support (red) │ └─ VIP (gold) └─ Legal (green)
Note that on several pages, the portlet has the same background color preference. So far, that’s easy enough; you just add a separate instance of the portlet to each page and set the preference appropriately.
However, the content managers don’t want to manage the background color on a per-page basis; they want to, for example, change the background color for the portlet on all the “About” pages to purple, all at the same time (this makes sense; it automates what would otherwise be a manual [and by definition, error-prone] process).
For this to work, either the “About” and “Contact” pages, for example, would both have to use the same instance of the portlet… or they would have to have separate instances, but both instances would share the same preference values. Or perhaps there is a different approach.
Is there a way to make this work?
It looks like the way to go is to create named sets of settings and let each page have its own instance of the portlet.
In the example from the OP, the Products page would have a unique instance of the portlet which would be configured to use e.g., the “orange” setting set. Any changes made to the portlet’s settings would subsequently affect any other portlets using the “orange” setting set.
See http://www.liferay.com/community/forums/-/message_boards/message/10361805#_19_message_10382903 for more information.