Created
July 22, 2019 11:42
-
-
Save jverweijL/5748a1af0c7429a81e497e518972fdcc to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <#-- | |
| Web content templates are used to lay out the fields defined in a web | |
| content structure. | |
| Please use the left panel to quickly add commonly used variables. | |
| Autocomplete is also available and can be invoked by typing "${". | |
| --> | |
| <#assign AssetCategoryLocalService = serviceLocator.findService("com.liferay.asset.kernel.service.AssetCategoryLocalService") /> | |
| <#assign JournalArticleLocalService = serviceLocator.findService("com.liferay.journal.service.JournalArticleLocalService") /> | |
| <#assign journalArticle = JournalArticleLocalService.getArticle(getterUtil.getLong(groupId),.vars['reserved-article-id'].data) /> | |
| <#assign categories = AssetCategoryLocalService.getCategories("com.liferay.journal.model.JournalArticle", journalArticle.getResourcePrimKey()) /> | |
| <h2>${Position.getData()}</h2> | |
| <p> | |
| <#if categories?has_content> | |
| <#list categories as category> | |
| ${category.getName()}${category?has_next?then(' | ', '')} | |
| </#list> | |
| </#if> | |
| </p> | |
| <p> | |
| ${Intro.getData()?substring(0, 100)}... | |
| </p> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment