Can configuration templates be propagated?Can configuration templates be propagated?https://liferay.dev/en/c/message_boards/find_thread?p_l_id=119785333&threadId=1090956662024-03-29T13:28:43Z2024-03-29T13:28:43ZRE: Can configuration templates be propagated?Barry Martinhttps://liferay.dev/en/c/message_boards/find_message?p_l_id=119785333&messageId=1092143412018-05-31T13:59:27Z2018-05-31T13:59:27ZKind of what I was thinking.<br /><br />Thx for the help ... I let you know how it works out.Barry Martin2018-05-31T13:59:27ZRE: Can configuration templates be propagated?Andrew Jardinehttps://liferay.dev/en/c/message_boards/find_message?p_l_id=119785333&messageId=1092127872018-05-31T13:51:12Z2018-05-31T13:51:12ZGood morning Barry,<br /><br />I didn't realize that you were an enterprise customer -- which is great news because I think you have tried enough things at this point that it's safe to say that you might have unearthed a bug. Fortunately you have LESA at your disposal to report it. <br /><br />FP 39 is pretty good, but I think I received and email earlier this week reporting that FP47 has been released. Here is what I would do if I were you.<br /><br />1. Clone you FP39 install<br />2. Apply FP 47 to it<br />3. Re-run your tests to see if the issue and results are the same<br /><br />.. and if they are, then open a LESA ticket to report it to Liferay. The chances of this being a bug that has slipped through and not yet having been reported I think are pretty high because, from my experience at least, User specific portlet preferences are not something often used. If it is a bug and you get something back from Liferay, please let us know because I am curious and also about to start using this feature myself on one of my current projects.Andrew Jardine2018-05-31T13:51:12ZRE: Can configuration templates be propagated?Barry Martinhttps://liferay.dev/en/c/message_boards/find_message?p_l_id=119785333&messageId=1092109672018-05-31T13:41:37Z2018-05-31T13:41:37ZFor simplicity I just gave both my users administrator role. Rule out permissions issues. No effect on original tests.<br /><br />Adding the portlet to a page outside a template works just fine. Configuration templates are saved and show in both 3 dot and app menus.<br /><br />Same is true when working in the template itself. Just no propagation to personal sites.<br /><br />PortletPreferences.ownerType is 4 for the portlet instances in the private sites.<br /><br />This would be neat if it worked!<br /><br />Testing with fix pack 39 ... just came thru a lengthy 6.2 upgrade. Resting for a while on fix packs. An issue with this?<br /><br />Thx!Barry Martin2018-05-31T13:41:37ZRE: Can configuration templates be propagated?Andrew Jardinehttps://liferay.dev/en/c/message_boards/find_message?p_l_id=119785333&messageId=1091661592018-05-30T19:39:18Z2018-05-30T19:39:18Z<html><head></head><body>Weird. With those settings in place now, if you add the portlet to a regular site page and set the preferences differently for two different users, does that work? (meaning if you remove the template from the equation). <br><br>Also, can you check the portletPreferences table and validate that the ownerType is 4? <br><br><pre><code>public static final int PREFS_OWNER_TYPE_USER = 4;</code></pre></body></html>Andrew Jardine2018-05-30T19:39:18ZRE: Can configuration templates be propagated?Barry Martinhttps://liferay.dev/en/c/message_boards/find_message?p_l_id=119785333&messageId=1091633332018-05-30T18:27:08Z2018-05-30T18:27:08ZNo change ... started over with a new user (assign power user role ... create site from template). Added -metatype:* to the bnd.bnd.<br /><br />Configuration is also not scoped in system settings ... and is in the other category.<br /><br />Here's my annotations ... configuration interface ...<br /><br />@ExtendedObjectClassDefinition(<br /> category = "category.agristats",<br /> scope = ExtendedObjectClassDefinition.Scope.PORTLET_INSTANCE<br />)<br />@Meta.OCD(<br /> id = "com.agristats.my.dashboard.web.portlet.action.AgristatsMyDashboardConfiguration",<br /> localization = "content/Language",<br /> name = "agristats-my-dashboard-configuration"<br />)<br /><br />portlet ...<br /><br />@Component(<br /> configurationPid = "com.agristats.my.dashboard.web.portlet.action.AgristatsMyDashboardConfiguration",<br /> immediate = true,<br /> property = {<br /> "com.liferay.portlet.display-category=category.agristats",<br /> "com.liferay.portlet.footer-portlet-javascript=/js/jquery.lwMultiSelect.js",<br /> "com.liferay.portlet.header-portlet-css=/css/jquery.lwMultiSelect.css",<br /> "com.liferay.portlet.header-portlet-css=/css/main.css",<br /> "com.liferay.portlet.instanceable=true",<br /> "com.liferay.portlet.preferences-company-wide=false",<br /> "com.liferay.portlet.preferences-unique-per-layout=true",<br /> "com.liferay.portlet.preferences-owned-by-group=false",<br /> "javax.portlet.display-name=My Dashboard",<br /> "javax.portlet.init-param.always-display-default-configuration-icons=true",<br /> "javax.portlet.init-param.config-template=/configuration.jsp",<br /> "javax.portlet.init-param.template-path=/",<br /> "javax.portlet.init-param.view-template=/view.jsp",<br /> "javax.portlet.name=" + AgriStatsMyDashboardPortletKeys.AgristatsMyDashboardPortlet,<br /> "javax.portlet.resource-bundle=content.Language",<br /> "javax.portlet.security-role-ref=power-user,user"<br /> },<br /> service = Portlet.class<br />)<br /><br />Bnd ...<br /><br />Bundle-Name: agristats-my-dashboard-web<br />Bundle-SymbolicName: com.agristats.my.dashboard.web<br />Bundle-Version: 1.0.0<br />Export-Package: com.agristats.my.dashboard.web.constants<br />Import-Package: \<br /> com.agristats.my.dashboard.model,\<br /> com.agristats.my.dashboard.service,\<br /> *<br />-metatype: *<br /><br />Thx!Barry Martin2018-05-30T18:27:08ZRE: Can configuration templates be propagated?Andrew Jardinehttps://liferay.dev/en/c/message_boards/find_message?p_l_id=119785333&messageId=1091542842018-05-30T15:53:03Z2018-05-30T15:53:03Z<html><head></head><body>Hey Barry,<br><br>Portlet instance is one part yes, but even within this there different scopes. You have<br><br>1. Portal wide preferences -- same for all instances of this portlet everywhere (across sites)<br>2. Site wide -- same for all instances of this portlet on this site <br>3. Per portlet instance, shared by all users<br>4. Per user, per portlet settings (This is the one you are after I believe)<br>5. Per user, across all portlets <br><br>In the old liferay-portlet.xml work you would manage #4 by using the following configuration --<br><br><pre><code><preferences-company-wide>false</preferences-company-wide>
<preferences-unique-per-layout>true</preferences-unique-per-layout>
<preferences-owned-by-group>false</preferences-owned-by-group></code></pre><br><br>in our brave new world you are going to have to do this in your component annotation for your portlet class I believe.<br><br><pre><code>com.liferay.portlet.preferences-company-wide=false
com.liferay.portlet.preferences-unique-per-layout=true
com.liferay.portlet.preferences-owned-by-group=false
</code></pre><br><br>.. I THINK <img alt="emoticon" src="@theme_images_path@/emoticons/happy.gif">. Can you give that a shot and let me know if you notice any changes? I'm not sure how it would affect existing stored values though (or if it would at all) so you may nee to clean up some records from the PortletPrefrences table and start a la scratch. <br><br>Let me know how it goes.</body></html>Andrew Jardine2018-05-30T15:53:03ZRE: Can configuration templates be propagated?Barry Martinhttps://liferay.dev/en/c/message_boards/find_message?p_l_id=119785333&messageId=1091512332018-05-30T15:46:45Z2018-05-30T15:46:45ZOOTB Web Content exhibits the same behavior.Barry Martin2018-05-30T15:46:45ZRE: Can configuration templates be propagated?Barry Martinhttps://liferay.dev/en/c/message_boards/find_message?p_l_id=119785333&messageId=1091509962018-05-30T15:33:57Z2018-05-30T15:33:57ZCustom.<br /><br />Just added the following to the configuration interface ...<br /><br />@ExtendedObjectClassDefinition(<br /> category = "category.agristats",<br /> scope = ExtendedObjectClassDefinition.Scope.PORTLET_INSTANCE<br />)<br /><br />And gave another user the power user role and created their site from the template with user maintenance.<br /><br />No effect.Barry Martin2018-05-30T15:33:57ZRE: Can configuration templates be propagated?Andrew Jardinehttps://liferay.dev/en/c/message_boards/find_message?p_l_id=119785333&messageId=1091493812018-05-30T15:03:32Z2018-05-30T15:03:32ZHmm -- that to me says that the configurations for that portlet are available at the Group Level, but not the User level. Is it a custom portlet that you are using? or is it one of the out of the box ones?Andrew Jardine2018-05-30T15:03:32ZRE: Can configuration templates be propagated?Barry Martinhttps://liferay.dev/en/c/message_boards/find_message?p_l_id=119785333&messageId=1091478012018-05-30T14:55:12Z2018-05-30T14:55:12ZOn the 3 dot menu in the portlet topper ... we see configuration, maximize, minimize, restore ... no configuration templates.<br /><br />On the app window far right we see only the app ... not the configuration templates underneath it.<br /><br />Both of these show configuration templates in the site template ... but not on the personal sites.Barry Martin2018-05-30T14:55:12ZRE: Can configuration templates be propagated?Andrew Jardinehttps://liferay.dev/en/c/message_boards/find_message?p_l_id=119785333&messageId=1091431372018-05-30T14:48:55Z2018-05-30T14:48:55ZHi Barry,<br /><br />Ok --- hmm. I know recently I discovered that there are a number of things from the template that don't actually propagate (which is kind of annoying, but makes sense in some cases). <br /><br />So you don't see the menu at all? or you are not seeing all the option that you expect to see for the Configuration Templates?Andrew Jardine2018-05-30T14:48:55ZRE: Can configuration templates be propagated?Barry Martinhttps://liferay.dev/en/c/message_boards/find_message?p_l_id=119785333&messageId=1091475212018-05-30T14:45:19Z2018-05-30T14:45:19ZIt is set to yes.<br /><br />So site admins can modify the pages ... even when propagation occurs.<br /><br />The end users will want to be able to tweak their personal sites ... even though they are initially created from the site template.Barry Martin2018-05-30T14:45:19ZRE: Can configuration templates be propagated?Andrew Jardinehttps://liferay.dev/en/c/message_boards/find_message?p_l_id=119785333&messageId=1091429262018-05-30T14:38:05Z2018-05-30T14:38:05ZHi Barry,<br /><br />You said "Site Template" in combination with "Not Available" on the site instance which immediately makes me think that the Site Template has been configured so that the lower level sites that are generated from the template are set to not allow for changes that don't come from the Template.<br /><br />If you go to the Control Panel and then choose to edit your Site Template, then under the Configuration (for the site template), Site Template Settings ... is the last toggle <br /><br /><blockquote>Allow site administrators to modify pages associated with this site template, even when propagation of changes is enabled./quote]<br /><br />enabled? or disabled?</blockquote>Andrew Jardine2018-05-30T14:38:05ZRE: Can configuration templates be propagated?Barry Martinhttps://liferay.dev/en/c/message_boards/find_message?p_l_id=119785333&messageId=1091395982018-05-30T13:43:00Z2018-05-30T13:43:00ZThis is for one of our configurable apps in the site template. Once a configuration is created we can save it by selecting "Configuration Templates" from the 3 dot menu in the portlet topper. It then appears in the application menu far right.<br /><br />So the thought is ... we can create a bunch of configurations which the user can select from.<br /><br />Unfortunately the templates do not propagate down to the personal sites.<br /><br />I neither see them in the app menu far right .. or have access to them with the 3 dot portlet topper menu ... as "Configuration Templates" is not an action available for the users.<br /><br />This could be very useful if it worked.<br /><br />Perhaps I'm missing a permission somewhere.<br /><br />BTW ... the app is instanceable.<br /><br />Thx.Barry Martin2018-05-30T13:43:00ZRE: Can configuration templates be propagated?Sushil Patidarhttps://liferay.dev/en/c/message_boards/find_message?p_l_id=119785333&messageId=1091176742018-05-30T08:11:29Z2018-05-30T08:11:29Z<blockquote>We are using a site template to create personal sites for our end users. We would like to have a variety of configuration templates for one of our apps that are propagated to the personal sites. Is this possible? Thx.</blockquote><br /><br