Fehler bei der Verarbeitung der Vorlage.
Java method "com.sun.proxy.$Proxy711.getLatestArticle(long)" threw an exception when invoked on com.sun.proxy.$Proxy711 object "com.liferay.journal.service.impl.JournalArticleLocalServiceImpl@2cedac1f"; see cause exception in the Java stack trace.

----
FTL stack trace ("~" means nesting-related):
	- Failed at: #assign jArt = JournalArticleLocalSer...  [in template "20116#20152#510999" at line 120, column 13]
----
1<#-- 
2Application display templates can be used to modify the look of a 
3specific application. 
4 
5Please use the left panel to quickly add commonly used variables. 
6Autocomplete is also available and can be invoked by typing "${". 
7--> 
8 
9<#assign DLFileEntryLocalService = serviceLocator.findService( 
10"com.liferay.document.library.kernel.service.DLFileEntryLocalService")> 
11<#assign DLFolderLocalService = serviceLocator.findService( 
12"com.liferay.document.library.kernel.service.DLFolderLocalService")> 
13<#assign JournalArticleLocalService = serviceLocator.findService( 
14"com.liferay.journal.service.JournalArticleLocalService")> 
15<#assign GroupLocalService = serviceLocator.findService( 
16"com.liferay.portal.kernel.service.GroupLocalService")> 
17<#assign LayoutSetService = serviceLocator.findService( 
18"com.liferay.portal.kernel.service.LayoutSetLocalService")> 
19<#assign AssetCategoryLocalService = serviceLocator.findService( 
20"com.liferay.asset.kernel.service.AssetCategoryLocalService")> 
21<#assign AssetVocabularyLocalService = serviceLocator.findService( 
22"com.liferay.asset.kernel.service.AssetVocabularyLocalService")> 
23<#assign AssetCategoryPropertyLocalService = serviceLocator.findService( 
24"com.liferay.asset.category.property.service.AssetCategoryPropertyLocalService")/> 
25<#assign PropertyFactoryUtil = serviceLocator.findService( 
26"com.liferay.portal.kernel.dao.orm.PropertyFactoryUtil") /> 
27 
28<#assign portletId = themeDisplay.getPortletDisplay().getId()> 
29<#assign locale = themeDisplay.getLocale()> 
30<#assign PortletPreferencesLocalService = serviceLocator.findService( 
31"com.liferay.portal.kernel.service.PortletPreferencesLocalService")/> 
32<#assign portletPreferencesXML = saxReaderUtil.read((PortletPreferencesLocalService.getPortletPreferences(themeDisplay.getPlid(), portletId)?first).getPreferences())> 
33<#assign TemplateCustomService = serviceLocator.findService("template.custom.services.TemplateCustomService") /> 
34 
35<#-- Macro used to get specific field text from an Asset Entry --> 
36<#macro entryNode document field> 
37    <#if document.selectSingleNode("/root/dynamic-element[@name='"+field+"']/dynamic-content")??> 
38    "${document.selectSingleNode("/root/dynamic-element[@name='"+field+"']/dynamic-content").getText()?js_string}" 
39    <#else> 
40    "" 
41    </#if> 
42</#macro> 
43 
44<#-- Macro used to get specific portlet preference --> 
45<#macro preference prefKey prefIndex defaultValue> 
46    <#if portletPreferencesXML.selectSingleNode("/portlet-preferences/preference[name='"+prefKey+"-"+prefIndex+"']/value")??> 
47    "${portletPreferencesXML.selectSingleNode("/portlet-preferences/preference[name='"+prefKey+"-"+prefIndex+"']/value").getText()?js_string}"<#return> 
48    <#else> 
49    "${defaultValue?js_string}"<#return> 
50    </#if> 
51</#macro> 
52 
53<div id="articleAdtDiv_${portletId}"></div> 
54<script> 
55    <#if portletPreferencesXML.selectSingleNode("/portlet-preferences/preference[name='useSmallerHeadings']/value")?? && 
56    portletPreferencesXML.selectSingleNode("/portlet-preferences/preference[name='useSmallerHeadings']/value").getText()?js_string == "true"> 
57        <#assign overrideHeadingSize = "heading3 mobile-heading2"> 
58    </#if> 
59 
60	<#assign multiArtBehavior = "Vertical Stack"> 
61	<#if portletPreferencesXML.selectSingleNode("/portlet-preferences/preference[name='multiArticleBehavior']/value")??> 
62        <#assign multiArtBehavior = portletPreferencesXML.selectSingleNode("/portlet-preferences/preference[name='multiArticleBehavior']/value").getText()?js_string> 
63    </#if> 
64 
65    <#assign fullWidthDisplay = "false"> 
66	<#if portletPreferencesXML.selectSingleNode("/portlet-preferences/preference[name='fullWidthDisplay']/value")??> 
67        <#assign fullWidthDisplay = portletPreferencesXML.selectSingleNode("/portlet-preferences/preference[name='fullWidthDisplay']/value").getText()?js_string> 
68    </#if> 
69 
70    <#assign featureDisplayType = "Image Left"> 
71	<#if portletPreferencesXML.selectSingleNode("/portlet-preferences/preference[name='featureDisplayType']/value")??> 
72        <#assign featureDisplayType = portletPreferencesXML.selectSingleNode("/portlet-preferences/preference[name='featureDisplayType']/value").getText()?js_string> 
73    </#if> 
74 
75    <#assign greyBackground = "false"> 
76	<#if portletPreferencesXML.selectSingleNode("/portlet-preferences/preference[name='greyBackground']/value")??> 
77        <#assign greyBackground = portletPreferencesXML.selectSingleNode("/portlet-preferences/preference[name='greyBackground']/value").getText()?js_string> 
78    </#if> 
79 
80    <#assign extraSpacer = "None"> 
81	<#if portletPreferencesXML.selectSingleNode("/portlet-preferences/preference[name='extraSpacer']/value")??> 
82        <#assign extraSpacer = portletPreferencesXML.selectSingleNode("/portlet-preferences/preference[name='extraSpacer']/value").getText()?js_string> 
83    </#if> 
84 
85    <#assign autoplay = "false"> 
86    <#if portletPreferencesXML.selectSingleNode("/portlet-preferences/preference[name='autoPlay']/value")??> 
87        <#assign autoplay = portletPreferencesXML.selectSingleNode("/portlet-preferences/preference[name='autoPlay']/value").getText()?js_string> 
88    </#if> 
89 
90	<#assign seeAllLink = ""> 
91	<#if portletPreferencesXML.selectSingleNode("/portlet-preferences/preference[name='seeAllLink']/value")??> 
92        <#assign seeAllLink = portletPreferencesXML.selectSingleNode("/portlet-preferences/preference[name='seeAllLink']/value").getText()?js_string> 
93    </#if> 
94 
95    <#assign seeAllLinkText = ""> 
96	<#if portletPreferencesXML.selectSingleNode("/portlet-preferences/preference[name='seeAllLinkText']/value")??> 
97        <#assign seeAllLinkText = portletPreferencesXML.selectSingleNode("/portlet-preferences/preference[name='seeAllLinkText']/value").getText()?js_string> 
98    </#if> 
99 
100    <#assign featureDisplayButtonType = "Visible"> 
101    <#if portletPreferencesXML.selectSingleNode("/portlet-preferences/preference[name='featureDisplayButtonType']/value")??> 
102    <#assign featureDisplayButtonType = portletPreferencesXML.selectSingleNode("/portlet-preferences/preference[name='featureDisplayButtonType']/value").getText()?js_string> 
103    </#if> 
104 
105    <#assign featureDisplayButtonText = ""> 
106    <#if portletPreferencesXML.selectSingleNode("/portlet-preferences/preference[name='featureDisplayButtonText']/value")??> 
107        <#assign featureDisplayButtonText = portletPreferencesXML.selectSingleNode("/portlet-preferences/preference[name='featureDisplayButtonText']/value").getText()?js_string> 
108    </#if> 
109 
110	<#assign gridTitle = ""> 
111	<#if portletPreferencesXML.selectSingleNode("/portlet-preferences/preference[name='gridTitle']/value")??> 
112		<#assign gridTitle = portletPreferencesXML.selectSingleNode("/portlet-preferences/preference[name='gridTitle']/value").getText()?js_string> 
113	</#if> 
114 
115	var entries = []; 
116 
117	<#if entries?has_content> 
118        <#list entries as curEntry> 
119 
120            <#assign jArt = JournalArticleLocalService.getLatestArticle(curEntry.getClassPK())> 
121            <#assign document = saxReaderUtil.read(jArt.getContentByLocale(themeDisplay.getLocale()))> 
122 
123            <#assign structureName = jArt.getDDMStructure().getName("en_US")> 
124 
125 
126            var componentType = "FEATURED_ARTICLE"; 
127            var voiceSearch = "featured-article"; 
128 
129            var title = <@entryNode document=document field="ArticleTitle"/>; 
130 
131            var subtitle = <@entryNode document=document field="Subtitle"/>; 
132 
133            var description = <@entryNode document=document field="Description"/>; 
134            if (description == ""){ 
135				description = <@entryNode document=document field="Intro"/>; 
136
137 
138            var slug = <@entryNode document=document field="Slug"/>; 
139 
140            <#assign articleGroup = GroupLocalService.getGroup(jArt.getGroupId())> 
141 
142            <#if LayoutSetService.getLayoutSet(themeDisplay.getScopeGroupId(), false)?? 
143            && LayoutSetService.getLayoutSet(themeDisplay.getScopeGroupId(), false).getThemeSetting("isMicroSite", "regular")?? > 
144                <#assign isMicroSite = (LayoutSetService.getLayoutSet(themeDisplay.getScopeGroupId(), false).getThemeSetting("isMicroSite", "regular") == "true")> 
145            <#else> 
146                <#assign isMicroSite = false> 
147            </#if> 
148 
149            var image = '${TemplateCustomService.getDocumentURL(document,"ThumbnailSquare",themeDisplay)}';  
150            if (null == image || "" == image || ${(fullWidthDisplay == "true")?c}) { 
151				image = '${TemplateCustomService.getDocumentURL(document,"Thumbnail",themeDisplay)}'; 
152
153            if (null == image) { 
154				image = ""; 
155
156 
157            var componentData = { 
158				locale: "${locale}", 
159				structureName: "${structureName}", 
160				displayType: "${featureDisplayType}", 
161				slug: slug, 
162				title: title, 
163				subtitle: subtitle, 
164				description: description, 
165				image: image.trim(), 
166				groupFriendlyUrl: '${articleGroup.getFriendlyURL()}', 
167				isMicrosite: ${isMicroSite?c}, 
168				multiArtBehavior: '${multiArtBehavior}', 
169                featureDisplayButtonText: '${featureDisplayButtonText}', 
170                featureDisplayButtonType: '${featureDisplayButtonType}', 
171				componentType: componentType, 
172				voiceSearch: voiceSearch 
173			}; 
174 
175            <#if structureName == "Video"> 
176 
177                componentData.displayType = "Video"; 
178                componentData.link = <@entryNode document=document field="LinkURL"/>; 
179                componentData.videoUrl = <@entryNode document=document field="VideoURL"/>; 
180 
181            <#elseif structureName == "Article"> 
182 
183                var linkTargetOverride = <@entryNode document=document field="LinkTargetOverride"/>; 
184 
185                if (linkTargetOverride !== ""){ 
186					componentData.link = linkTargetOverride; 
187				} else { 
188                    <#assign assetCategories = AssetCategoryLocalService.getAssetEntryAssetCategories(curEntry.getEntryId())> 
189 
190					var articleCategories = []; 
191 
192                    <#list assetCategories as category> 
193                        <#assign categoryVocabulary = AssetVocabularyLocalService.getAssetVocabulary(category.getVocabularyId())> 
194                        <#assign categoryUrl = "#"> 
195 
196                        <#list AssetCategoryPropertyLocalService.getCategoryProperties(category.categoryId) as categoryProperty> 
197 
198                            <#if categoryProperty.key == "url"> 
199                                <#assign categoryUrl = categoryProperty.value> 
200                            </#if> 
201                        </#list> 
202	 
203                        articleCategories.push({ 
204							id: "${category.categoryId}", 
205							name: "${category.name}", 
206							url: "${categoryUrl}", 
207							vocabularyName: "${categoryVocabulary.getTitle(locale)}", 
208						}); 
209				    
210                    </#list> 
211 
212 
213					componentData.categories = articleCategories; 
214					componentData.urlTitle = "${jArt.getUrlTitle()?js_string}"; 
215
216 
217                var byline = <@entryNode document=document field="Byline"/>; 
218                if (byline != null && byline != ""){ 
219					componentData.byline = []; 
220				}; 
221 
222            <#elseif structureName == "External Article"> 
223 
224 
225 
226            <#-- All External Articles should display at /media-center/article, so populate categories accordingly --> 
227			<#-- var articleCategories = []; 
228                articleCategories.push({ 
229					id: "0", 
230					name: "Media Center", 
231					url: "media-center", 
232					vocabularyName: "Topics", 
233				}); 
234                articleCategories.push({ 
235					id: "1", 
236					name: "Article", 
237					url: "article", 
238					vocabularyName: "Article Type", 
239				}); 
240 
241                componentData.categories = articleCategories; 
242                componentData.urlTitle = "${jArt.getUrlTitle()?js_string}"; --> 
243 
244				componentData.link = <@entryNode document=document field="LinkURL"/>; 
245				componentData.isExternal = true; 
246 
247                var bylineSegments = []; 
248                var pubName = <@entryNode document=document field="PublicationName"/>; 
249 
250                if (pubName != null && pubName != ""){ 
251					bylineSegments.push(pubName); 
252					componentData.italicizeFirstByline = true; 
253				}; 
254 
255            <#--bylineSegments.push(<@entryNode document=document field="PublicationDate"/>); --> 
256                componentData.byline = bylineSegments; 
257 
258            <#elseif structureName == "Link"> 
259 
260                componentData.link = <@entryNode document=document field="LinkURL"/>; 
261                componentData.isExternal = true; 
262 
263                var bylineSegments = []; 
264 
265                <#assign linkja = JournalArticleLocalService.getLatestArticle(curEntry.getClassPK()) > 
266                <#assign linkdocument = saxReaderUtil.read(linkja.getContent())> 
267                <#assign linknodes = document.selectNodes("/root/dynamic-element[@name='BylineSegment']/dynamic-content")> 
268 
269                <#list linknodes as curN> 
270                    bylineSegments.push("${curN.getText()?js_string}"); 
271                </#list> 
272 
273                componentData.byline = bylineSegments; 
274                componentData.italicizeFirstByline = true; 
275 
276            </#if> 
277 
278            entries.push(componentData); 
279        </#list> 
280    </#if> 
281 
282	<#if multiArtBehavior == "Carousel"> 
283        var carouselProps = { 
284			entries: entries, 
285			gridTitle: "${gridTitle}", 
286			fullWidthDisplay: ${(fullWidthDisplay == "true")?c}, 
287			greyBackground: "${greyBackground}", 
288			autoplay: ${(autoplay == "true")?c} 
289		}; 
290 
291        ATK.React.Component.Carousel("articleAdtDiv_${portletId?js_string}", carouselProps); 
292    <#else> 
293    	var componentVoiceSearch = "featured-article"; 
294        var extraProps = { 
295			multiArtBehavior: "${multiArtBehavior}", 
296			gridTitle: "${gridTitle}", 
297			fullWidthDisplay: "${fullWidthDisplay}", 
298			greyBackground: "${greyBackground}", 
299			extraSpacer: "${extraSpacer}", 
300			seeAllLink: "${seeAllLink}", 
301			seeAllLinkText: "${seeAllLinkText}", 
302			componentVoiceSearch: componentVoiceSearch 
303		}; 
304        ATK.React.Component.FeaturedMultiDisplay("articleAdtDiv_${portletId?js_string}", extraProps, entries); 
305    </#if> 
306 
307</script>