Excuse me if I’m asking silly or easy question, but I just can’t figure it out.
So, I have a theme, I want to render only portlets, skipping any journal articles.
Which is the most appropriate way to do it?
Excuse me if I’m asking silly or easy question, but I just can’t figure
Share
In your theme’s resources, there is a
portlet.vmtemplate available in the_diffs/templatedirectory. This template allows you to override the default presentation of portlets in general (e.g. change the configuration icons, remove the title bar, …).However, inside
portlet.vmLiferay injects a predefined variable called$portletDisplay. This is an instance of thecom.liferay.portal.theme.PortletDisplayclass and represents the portlet that is currently printed.You can use the
$portletDisplay.portletNameattribute to check for 56, which is the ID for all Web Content Display portlets. So, in short, encapsulate the parent<div>insideportlet.vmwith the following condition: