เกิดเหตุผิดพลาดในระหว่างเตรียมเท็มเพลต
For "." left-hand operand: Expected a hash, but this has evaluated to a string (wrapper: f.t.SimpleScalar): ==> ortWCSKASDEORT [in template "252001#252047#252845" at line 284, column 40] ---- FTL stack trace ("~" means nesting-related): - Failed at: ortWCSKASDEORTPrimaryKey = ortWCSKASD... [in template "252001#252047#252845" at line 284, column 13] ----
1<#-- used @ Veranstaltung-Detailseite Intro
2 used @ Publikation-Detailseite Intro
3-->
4
5<#--
6Web content templates to display teaser on thema detail page
7
8Generic template for detail pages Intro / Teaser element
9-->
10<#--
11Display the current page title
12-->
13<#include "${fullTemplatesPath}/functions/relatedContentUtil.ftl" />
14<#include "${fullTemplatesPath}/macros/debugging.ftl" />
15
16<#include "${fullTemplatesPath}/macros/page-modules/PMIntro.ftl" />
17<#include "${fullTemplatesPath}/macros/atomic-modules/AMPublicationCarousel.ftl" />
18<#include "${fullTemplatesPath}/macros/atomic-modules/AMMetadata.ftl" />
19<#include "${fullTemplatesPath}/macros/atomic-modules/AMDatetime.ftl" />
20
21
22<#--
23 renders the Intro for nearly all Pages
24 TODO: remove Share? (was in the designs, but not anymore?)
25 TODO: check if languageSelect/filter are working (js)
26
27 - portletId
28 - data = {
29 "media": string (src from image),
30 "category": string,
31 "title": string,
32 "author": string,
33 "subheadline": string,
34 "copy": string,
35 "filter": {
36 "id": string,
37 "name": string,
38 "entries": Array<Object> ({key:value}),
39 },
40 "languageSelect": {
41 "id": string,
42 "name": string,
43 "entries": Array<Object> ({key:value}),
44 },
45 "meta": {
46 "pos"; string (top/bottom)
47 "date": string,
48 "hash": string,
49 "info": string, (url)
50 },
51 "share" : {
52 "login": string,
53 "print": string,
54 "mail": string,
55 "multishare": string?? (tbd)
56 }
57 - AMMetadata: macro
58 - position: String ("top") -> defines wether the meta-data should be rendered above or below the intro-content
59 }
60-->
61
62<#assign
63 JournalArticleLocalService = serviceLocator.findService("com.liferay.journal.service.JournalArticleLocalService")
64
65 ServiceContext = staticUtil["com.liferay.portal.kernel.service.ServiceContextThreadLocal"].getServiceContext()
66 DLAPP = serviceLocator.findService("com.liferay.document.library.kernel.service.DLAppLocalService")
67
68 themeDisplay = ServiceContext.getThemeDisplay()
69 editmode = FrontendService.user.isPrivilegedUser(themeDisplay)
70
71 languageId = themeDisplay.getLocale()
72 groupId = themeDisplay.getScopeGroupId()
73 currentUrl = themeDisplay.getURLCurrent()
74
75 layout = themeDisplay.getLayout()
76 layouttpl = layout.getTypeSettingsProperties().getProperty("layout-template-id")
77/>
78
79<#setting locale="${languageId}">
80
81<#-- get article from url -->
82
83<#assign entry = FrontendService.article.getArticleToUrl(currentUrl, groupId?number)! >
84
85
86<#if entry?has_content>
87
88 <#if entry.resourcePrimKey??>
89 <#assign primaryKey = entry.resourcePrimKey?number >
90 <#elseif entry.classPK??>
91 <#assign primaryKey = entry.classPK?number >
92 </#if>
93
94 <#assign
95 jsonString = FrontendService.article.getWebcontent(primaryKey)
96 json = FrontendService.json.parseAsJson(jsonString)
97 availablelanguages = FrontendService.article.getAssetEntryToUrl(primaryKey).getAvailableLanguageIds()
98
99 title = entry.getTitle(languageId)
100 data = {
101 "title": title
102 }
103 />
104 <@debugJsonString jsonString "ADT_KASDE_DYNAMIC_INTRO" />
105
106 <#if hasContent('untertitel', languageId, json)>
107 <#assign data = data + { "subheadline": getValueForLanguage('untertitel', languageId, json, "first") } >
108 </#if>
109
110 <#if hasContent('beschreibung', languageId, json)>
111 <#assign data = data + { "copy": getValueForLanguage('beschreibung', languageId, json, "first") } >
112 </#if>
113
114 <#-- fill meta data -->
115 <#assign meta = {} />
116
117 <#-- PUBLIKATIONEN DETAIL -->
118 <#if layouttpl?contains("LAYOUT_KASDE_PUBLIKATIONEN_DETAIL")>
119
120 <#if hasContent('coverDMTKASDEMEDIUM', languageId, json)>
121 <#assign
122 coverBildString = getValueForLanguage('coverDMTKASDEMEDIUM', languageId, json, "first")
123 />
124
125 <#if coverBildString?has_content>
126 <#assign
127 coverBild = FrontendService.json.parseAsJson(coverBildString)
128 dMTJsonObject = FrontendService.media.getDMTJsonObject( coverBild.groupId?number, coverBild.uuid, locale )
129 linkToDMT = FrontendService.media.getImageURLForAMConfiguration('hd-resolution',coverBild.groupId?number, coverBild.uuid )
130 data = data + { "media": linkToDMT, "meta" : dMTJsonObject }
131 />
132 <#if dMTJsonObject.altText?? >
133 <#assign data = data + {"alt" : dMTJsonObject.altText} />
134 </#if>
135 <#if dMTJsonObject.quelle??>
136 <#assign meta = meta + { "quelle": dMTJsonObject.quelle } />
137 </#if>
138 </#if>
139 <#-- uncomment to display pdf cover as Intro Image
140 <#elseif hasContent('document_pdfDMTBASICDOCUMENT', languageId, json)>
141 <#assign
142 pdfDocument = getValueForLanguage('document_pdfDMTBASICDOCUMENT', languageId, json, "first")
143 fileEntry = FrontendService.media.getFileEntry(pdfDocument.uuid, groupId?number)!/>
144 <#if fileEntry?has_content>
145 <#assign
146 linkToThumbnail = FrontendService.link.getThumbnailSrc(fileEntry , themeDisplay)
147 data = data + { "media": linkToThumbnail }
148 />
149 </#if>
150 -->
151 </#if>
152
153 <#assign
154 meta = meta + { "orderInfo": "true" }
155 verbundJournalArticle = FrontendService.publication.getVerbundToPublikation( entry )!""
156 />
157
158
159
160 <#if hasContent('erscheinungsdatum', languageId, json)>
161 <#assign
162 erscheinungsdatum = getValueForLanguage('erscheinungsdatum', languageId, json, "first")
163 />
164 <#if erscheinungsdatum?has_content >
165 <#assign
166 erscheinungsdatumFormatted = FrontendService.date.getDateFormatLong( erscheinungsdatum, languageId )
167 meta = meta + { "date": erscheinungsdatumFormatted }
168 />
169 </#if>
170 </#if>
171
172 <#if verbundJournalArticle?has_content>
173 <#assign
174 verbundJsonString = FrontendService.article.getWebcontent(verbundJournalArticle.resourcePrimKey)
175 verbundJson = FrontendService.json.parseAsJson(verbundJsonString)
176 laufendenummer = getValueForLanguage('laufendenummer', languageId, verbundJson, "first")
177 coverImg = getValueForLanguage('mediumDMTKASDEMEDIUM', languageId, verbundJson, "first")
178 />
179 <@debugJsonString verbundJsonString "ADT_KASDE_DYNAMIC_INTRO-verbundJournalArticle" />
180 <#assign meta = meta + { "laufendenummer": laufendenummer } >
181
182 <#if coverImg?has_content && coverImg.url?has_content >
183 <#assign meta = meta + { "coverImg": coverImg.url } >
184 </#if>
185 </#if>
186
187
188 <#if meta?has_content>
189 <#assign data = data + {"meta": meta } >
190 </#if>
191
192 </#if>
193 <#-- PUBLIKATIONEN DETAIL END -->
194
195
196 <#-- VERANSTALTUNGEN DETAIL -->
197 <#if layouttpl?contains("LAYOUT_KASDE_VERANSTALTUNGEN_DETAIL")>
198 <#assign
199 friendlyUrl = FrontendService.article.getFriendlyUrl(primaryKey, languageId, groupId)!""
200 links = []
201 />
202 <#if availablelanguages?has_content && friendlyUrl?has_content>
203 <#if (availablelanguages?size > 1) >
204 <#list availablelanguages as language>
205 <#assign
206 defaultLanguage = "de_DE"
207 defaultLocale = FrontendService.language.getLocaleByKey(defaultLanguage)
208 linkLocale = (FrontendService.language.getLocaleByKey(language))!defaultLocale
209 langFriendlyUrl = FrontendService.article.getFriendlyUrl(primaryKey, linkLocale, groupId)
210
211 link = {
212 "key": language!defaultLanguage,
213 "value": linkLocale.getDisplayLanguage(languageId),
214 "url": "/c/portal/update_language?p_l_id=" +
215 layout.plid + "&redirect=" + langFriendlyUrl +
216 "&languageId=" + language
217 }
218 />
219 <#if language == languageId>
220 <#assign link = link + { "selected": "true" } >
221 </#if>
222 <#assign links = links + [link]>
223 </#list>
224 <#assign
225 data = data + {
226 "languageSelect": {
227 "id": "languageSelectRedirect",
228 "name": "languageselectRedirect",
229 "entries": links,
230 "label": languageUtil.get(languageId, "diese.veranstaltung.ist.in.weiteren.sprachen.verfuegbar")
231 }
232 }
233 />
234 </#if>
235 </#if>
236 </#if>
237
238 <#if hasContent('erscheinungsdatum', languageId, json)>
239 <#assign
240 startdate = getValueForLanguage('erscheinungsdatum', languageId, json, "first")
241 meta = meta + { "start": startdate?date.iso, "end": "" }
242 />
243 </#if>
244
245 <#if hasContent('startdatum', languageId, json)>
246 <#assign
247 startdate = getValueForLanguage('startdatum', languageId, json, "first")
248 meta = meta + { "start": startdate?date.iso, "end": "" }
249 />
250 </#if>
251
252 <#if hasValue('einfuehrungText', locale, json)>
253 <#assign data = data + { "einfuehrungText" : getValueForLanguage('einfuehrungText', locale, json, "first") } >
254 <#elseif hasValue(FrontendService.article.getFieldNameByReferenceName(primaryKey, 'einfuehrungText'), locale, json, "first")>
255 <#assign data = data + { "einfuehrungText" : getValueForLanguage(FrontendService.article.getFieldNameByReferenceName(primaryKey, 'einfuehrungText'), locale, json, "first") } >
256 </#if>
257
258 <#if hasContent('endedatum', languageId, json)>
259 <#assign
260 enddate = getValueForLanguage('endedatum', languageId, json, "first")
261 meta = meta + { "end": enddate?date.iso }
262 />
263 </#if>
264
265 <#if hasContent('startzeit', languageId, json)>
266 <#assign
267 startzeit = getValueForLanguage('startzeit', languageId, json, "first")
268 />
269 <#if startzeit?has_content >
270 <#assign meta = meta + { "startzeit": startzeit } />
271 </#if>
272 </#if>
273
274 <#if hasContent('endezeit', languageId, json)>
275 <#assign
276 endezeit = getValueForLanguage('endezeit', languageId, json, "first")
277 meta = meta + { "endezeit": endezeit }
278 />
279 </#if>
280
281 <#if hasContent('ortWCSKASDEORT', languageId, json)>
282 <#assign
283 ortWCSKASDEORT = FrontendService.json.parseAsJson(getValueForLanguage('ortWCSKASDEORT', languageId, json, "first"))
284 ortWCSKASDEORTPrimaryKey = ortWCSKASDEORT.classPK?number
285 ortWCSKASDEORTWebContent = FrontendService.article.getWebcontentByPk(ortWCSKASDEORTPrimaryKey)!""
286 />
287 <#if ortWCSKASDEORTWebContent?has_content >
288 <#assign
289 ortWCSKASDEORTTitle = ortWCSKASDEORTWebContent.getTitle(languageId)!""
290 />
291 <#if ortWCSKASDEORTTitle?has_content >
292 <#assign
293 meta = meta + { "ortWCSKASDEORT": ortWCSKASDEORTTitle }
294 />
295 </#if>
296 </#if>
297 </#if>
298
299
300 <#if hasContent('veranstaltungsnummer', languageId, json)>
301 <#assign
302 verauuid = getValueForLanguage('veranstaltungsnummer', languageId, json, "first")
303 meta = meta + { "verauuid": verauuid }
304 />
305 </#if>
306
307
308 <#if (data.meta)?has_content >
309 <#assign meta = data.meta />
310 </#if>
311
312 <#if !(data.media)?has_content && hasContent('mediumDMTKASDEMEDIUM', languageId, json)>
313 <#assign
314 medium = getValueForLanguage('mediumDMTKASDEMEDIUM', languageId, json, "first")
315 mediaData = getRelatedMediaObject(medium, themeDisplay, languageId, FrontendService, "hd-resolution")
316 />
317 <#assign data = data + { "media": mediaData.url , "meta" : mediaData.meta} >
318
319
320 <#if mediaData.meta?? && mediaData.meta.quelle??>
321 <#assign meta = meta + data.meta + { "quelle": mediaData.meta.quelle } />
322 </#if>
323 </#if>
324
325
326 <#if meta?has_content>
327 <#assign data = data + {"meta": meta } >
328 </#if>
329
330 <#-- END fill meta data -->
331
332 <#if hasContentForSequence('autorenWCSKASDEPERSON', languageId, json)>
333 <#assign
334 journalArticles = getValueForLanguageAnsprechpartner('autorenWCSKASDEPERSON', languageId, json)
335 authors = []
336 />
337 <#list journalArticles as articleString>
338 <#assign article = FrontendService.json.parseAsJson(articleString) />
339 <#if article?has_content && article?is_hash && article.classPK??>
340 <#assign articleDereferenced = FrontendService.person.resolveContactInstanceToPerson(article, languageId)!"" />
341 <#if articleDereferenced?has_content >
342 <#assign
343 author = ""
344 articlePrimaryKey = articleDereferenced.classPK?number
345 articleJsonString = FrontendService.article.getWebcontent(articlePrimaryKey)
346 articleJson = FrontendService.json.parseAsJson(articleJsonString)
347 />
348 <@debugJsonString articleJsonString "ADT_KASDE_DYNAMIC_INTRO-autorenWCSKASDEPERSON" />
349 <#if hasValue('anredetitel', languageId, articleJson)>
350 <#assign author = author + getValueForLanguage('anredetitel', languageId, articleJson, " ") + " ">
351 </#if>
352 <#if hasValue('vorname', languageId, articleJson)>
353 <#assign author = author + getValueForLanguage('vorname', languageId, articleJson, " ") + " ">
354 </#if>
355 <#if hasValue('nachname', languageId, articleJson)>
356 <#assign author = author + getValueForLanguage('nachname', languageId, articleJson, " ") + " ">
357 </#if>
358
359 <#attempt>
360 <#assign href = FrontendService.article.getFriendlyUrl(articlePrimaryKey, languageId, groupId)!"#" >
361 <#recover>
362 <#assign href = "#" >
363 </#attempt>
364 <#if href?has_content && href != "#" && href != "/_404">
365 <#assign author = '<a href="' + href + '">' + author?trim + '</a>'>
366 </#if>
367
368 <#assign authors = authors + [author?trim]>
369 </#if>
370 </#if>
371 </#list>
372 <#if authors?has_content>
373 <#assign data = data + { "author": authors?join(", ") } >
374 </#if>
375 </#if>
376
377 <#if layouttpl?contains("LAYOUT_KASDE_VERANSTALTUNGEN_DETAIL") >
378 <#assign categories = FrontendService.category.getCategoriesToArticle(primaryKey, "VERANSTALTUNGSTYP")! >
379 <#if categories?has_content && categories[0]?has_content >
380 <#assign data = data + { "category": categories[0].getTitle(languageId,true)! } >
381 </#if>
382
383 <#if hasContent('ausgebucht', languageId, json)>
384 <#assign data = data + { "ausgebucht" : getValueForLanguage('ausgebucht', languageId, json, "first") }>
385 </#if>
386
387 <#if hasContent('storniert', languageId, json)>
388 <#assign data = data + { "storniert" : getValueForLanguage('storniert', languageId, json, "first") }>
389 </#if>
390
391 <#elseif layouttpl?contains("LAYOUT_KASDE_PUBLIKATIONEN_DETAIL") >
392 <#assign categories = FrontendService.category.getCategoriesToArticle(primaryKey, "PUBLIKATIONSREIHE")! >
393 <#if categories?has_content && categories[0]?has_content >
394 <#assign data = data + { "category": categories[0].getTitle(languageId,true)! } >
395 </#if>
396 <#else>
397 <#assign categories = FrontendService.category.getCategoriesToArticle(primaryKey, "THEMA")! >
398 <#if categories?has_content && categories[0]?has_content >
399 <#assign data = data + { "category": categories[0].getTitle(languageId,true)! } >
400 </#if>
401 </#if>
402
403
404 <#assign
405 languages = []
406 />
407
408 <#attempt>
409 <#if json["document_pdfDMTBASICDOCUMENT"]?? >
410 <#if availablelanguages?has_content>
411 <#list availablelanguages as pdf_language>
412 <#assign
413 docRefJson = getValueForLanguage('document_pdfDMTBASICDOCUMENT', pdf_language, json, "first")
414 docRef = FrontendService.json.parseAsJson(docRefJson)
415 />
416 <#if docRef?is_hash && pdf_language != languageId >
417 <#assign
418 lang = FrontendService.language.getLocaleByKey(pdf_language)!""
419 docGroupId = docRef["groupId"]?number
420 docUuid = docRef["uuid"]
421 dMTJsonObject = FrontendService.media.getDMTJsonObject( docGroupId, docUuid, locale )
422 dMTLink = FrontendService.media.getLinkToDMT( dMTJsonObject )
423 />
424 <#if lang?has_content>
425 <#assign
426 languages = languages + [
427 {
428 "key": pdf_language,
429 "value": FrontendService.language.getLocaleByKey(pdf_language).getDisplayLanguage(),
430 "url": dMTLink
431 }]
432 />
433 </#if>
434 </#if>
435 </#list>
436 </#if>
437 </#if>
438 <#recover>
439 </#attempt>
440
441 <#if (languages?size > 0)>
442 <#attempt>
443 <#assign
444 data = data + { "languageSelect": {
445 "id": "languageSelect",
446 "name": "languageselect",
447 "entries": languages,
448 "documents": "",
449 "button": "true"
450 }}
451 />
452 <#recover>
453 </#attempt>
454 </#if>
455
456 <@PMIntro "ADT_KASDE_DYNAMIC_INTRO" data AMMetadata AMDatetime "bottom" />
457 ${FrontendService.article.getEditArticleHtml(primaryKey, themeDisplay)}
458
459 <#if data.meta?has_content>
460 <#if data.meta.laufendenummer?has_content !isACColorScheme() && !isVLCColorScheme() && !isDPMColorScheme()>
461 <div>
462 <div id="publicationVerbundPagination">
463 <@AMPublicationCarousel data.meta.laufendenummer data.meta.date data.meta.coverImg />
464 </div>
465 </div>
466 </#if>
467 </#if>
468
469<#elseif (editmode?? && editmode)>
470 <@errorMessage languageUtil.get(locale, "kein.journalArticle.gefunden") "ADT_KASDE_DYNAMIC_INTRO" layouttpl currentUrl />
471</#if>
เกิดเหตุผิดพลาดในระหว่างเตรียมเท็มเพลต
For "." left-hand operand: Expected a hash, but this has evaluated to a string (wrapper: f.t.SimpleScalar): ==> place [in template "kas-de-theme_SERVLET_CONTEXT_/templates/functions/content-functions/CFPrepareLocationData.ftl" at line 11, column 73] ---- FTL stack trace ("~" means nesting-related): - Failed at: placeString = FrontendService.article... [in template "kas-de-theme_SERVLET_CONTEXT_/templates/functions/content-functions/CFPrepareLocationData.ftl" in function "prepareLocationData" at line 11, column 21] ----
1<#-- used @ Veranstaltungen-Detailseite, Main Content -->
2<#-- used @ Themen-Detailseite, Main Content -->
3<#-- used @ Publikationen-Detailseite, Main Content -->
4<#-- used @ Personen-Detailseite, Main Content -->
5
6<#include "${fullTemplatesPath}/functions/liferayServicesUtil.ftl" />
7<#include "${fullTemplatesPath}/functions/relatedContentUtil.ftl" />
8<#include "${fullTemplatesPath}/macros/debugging.ftl" />
9
10<#include "${fullTemplatesPath}/macros/page-modules/PMPageContent.ftl" />
11
12<#-- additional intro+special content for personen-detailpage -->
13<#include "${fullTemplatesPath}/macros/page-modules/PMShare.ftl" />
14<#include "${fullTemplatesPath}/macros/page-modules/PMIntro.ftl" />
15<#include "${fullTemplatesPath}/macros/page-modules/PMIntroBanner.ftl" />
16<#include "${fullTemplatesPath}/macros/page-modules/PMPersonContent.ftl" />
17<#include "${fullTemplatesPath}/macros/page-modules/PMPersonDocuments.ftl" />
18<#include "${fullTemplatesPath}/macros/atomic-modules/AMMetadata.ftl" />
19<#include "${fullTemplatesPath}/macros/atomic-modules/AMAddress.ftl" />
20<#include "${fullTemplatesPath}/macros/atomic-modules/AMDatetime.ftl" />
21<#include "${fullTemplatesPath}/macros/atomic-modules/AMMetadataContact.ftl" />
22<#include "${fullTemplatesPath}/functions/content-functions/CFRelatedMediaObject.ftl" />
23<#include "${fullTemplatesPath}/functions/content-functions/CFRelatedVeranstaltung.ftl" />
24
25<#assign
26
27 DLFileEntryLocalService = getDLFileEntryLocalService()
28 JournalArticleService = getJournalArticleService()
29 layoutLocalService = serviceLocator.findService("com.liferay.portal.kernel.service.LayoutLocalService")
30
31 themeDisplay = getThemeDisplay()
32
33 locale = themeDisplay.getLocale()
34 default_locale = FrontendService.language.defaultLocale()
35
36 currentUrl = themeDisplay.getURLCurrent()
37 editmode = FrontendService.user.isPrivilegedUser(themeDisplay)
38
39 companyId = themeDisplay.getCompanyId()
40 primaryKey = 0
41
42 layout = themeDisplay.getLayout()
43 layoutUrl = layout.getFriendlyURL(locale)
44 layouttpl = layout.getTypeSettingsProperties().getProperty("layout-template-id")
45/>
46
47<#if layouttpl?contains("LAYOUT_KASDE_VERANSTALTUNGEN_DETAIL")>
48 <#assign
49 classModifier = "c-page-main--veranstaltungedetail"
50 portletId = "ADT_KASDE_VERANSTALTUNGEN_CONTENT"
51 />
52<#elseif layouttpl?contains("LAYOUT_KASDE_PUBLIKATIONEN_DETAIL")>
53 <#assign
54 classModifier = "c-page-main--publikationendetail"
55 portletId = "ADT_KASDE_PUBLIKATIONEN_CONTENT"
56 />
57<#elseif layouttpl?contains("LAYOUT_KASDE_THEMEN_DETAIL")>
58 <#assign
59 classModifier = "c-page-main--themadetail"
60 portletId = "ADT_KASDE_THEMA_CONTENT"
61 />
62<#elseif layouttpl?contains("LAYOUT_KASDE_PERSONEN_DETAIL")>
63 <#assign
64 classModifier = "c-page-main--themadetail"
65 portletId = "ADT_KASDE_PERSONEN_CONTENT"
66 />
67<#else>
68 <#assign
69 classModifier = "c-page-main"
70 portletId = "ADT_KASDE_CONTENT"
71 />
72</#if>
73
74<#assign content = [] >
75
76<#-- check if on detail page -->
77<#-- Publikationen, Veranstaltungen -->
78<#-- check if it is a hidden detail page - get article from url -->
79<#if currentUrl?contains("/-/content") >
80
81 <#attempt>
82 <#assign journalArticle = FrontendService.article.getArticleToUrl(currentUrl, groupId?number)!"" >
83 <#recover>
84 <#if (editmode?? && editmode)>
85 <@errorMessage languageUtil.get(locale, "kein.journalArticle.gefunden") "ADT_KASDE_CONTENT" layouttpl currentUrl />
86 </#if>
87 </#attempt>
88
89 <#if journalArticle?has_content>
90
91 <#if journalArticle.resourcePrimKey??>
92 <#assign primaryKey = journalArticle.resourcePrimKey?number >
93 <#elseif journalArticle.classPK??>
94 <#assign primaryKey = journalArticle.classPK?number >
95 </#if>
96
97 <#assign
98 jsonString = FrontendService.article.getWebcontent(primaryKey)
99 json = FrontendService.json.parseAsJson(jsonString)
100
101 data = {}
102 registerLink = ""
103
104 />
105 <@debugJsonString jsonString "ADT_KASDE_CONTENT" />
106
107 <#-- Personen Detailpage Content renders also the intro -->
108 <#if layouttpl?contains("LAYOUT_KASDE_PERSONEN_DETAIL")>
109 <#-- get general data for PERSON-->
110 <#assign
111 data_person = getRelatedPerson(json, locale, primaryKey, FrontendService, themeDisplay)
112 data_intro = {}
113 data_abteilung = []
114 />
115
116 <#-- get Projekte (Auslandsbüros) for PERSON -->
117 <#assign data_auslandsbuero = getRelatedProjekte(locale, primaryKey, FrontendService, themeDisplay) />
118 <#if data_auslandsbuero?has_content>
119 <#assign data_person = data_person + {"auslandsbuero": data_auslandsbuero} />
120 </#if>
121
122 <#-- get Abteilungen for PERSON -->
123 <#assign abbteilungen = FrontendService.category.getCategoriesToArticle(primaryKey, "ABTEILUNG") />
124 <#if abbteilungen?? >
125 <#list abbteilungen as abteilung >
126 <#assign
127 data_abteilung = data_abteilung + [{
128 "title": abteilung.getTitle(locale),
129 "href": FrontendService.category.getAnzeigeseiteToCategory(abteilung, locale, themeDisplay.getScopeGroupId())!"/_404"
130 }]
131 />
132 </#list>
133 </#if>
134 <#if data_abteilung?has_content>
135 <#assign data_person = data_person + {"abteilung": data_abteilung} />
136 </#if>
137
138 <#-- assign Data for Intro -->
139 <#if data_person.name?? && data_person.lastname?? >
140 <#assign name = data_person.name + " " + data_person.lastname >
141
142 <#if data_person.anredetitel??>
143 <#assign name = data_person.anredetitel + " " + name />
144 </#if>
145 <#assign data_intro = data_intro + { "title" : name } />
146 </#if>
147
148 <#if data_person.subheadline??>
149 <#assign data_intro = data_intro + {"subheadline" : data_person.subheadline} />
150 </#if>
151
152 <#-- render title + function -->
153 <div class="o-page-module o-page-module--full">
154 <@PMIntro "ADT_KASDE_PERSON_INTRO" data_intro AMMetadata AMDatetime/>
155 <#-- render blue box -->
156 <@PMIntroBanner "ADT_KASDE_PERSON_INTRO_BANNER" data_person "" />
157 <#-- render contact data, auslandsbüros, abteilungen -->
158 <@PMPersonContent "ADT_KASDE_PERSON_INFO" data_person "" AMMetadataContact AMAddress />
159 <#-- render persons document -->
160 <#if data_person.documents??>
161 <@PMPersonDocuments "ADT_KASDE_PERSON_DOCUMENT" data_person.documents "" />
162 </#if>
163 </div>
164
165 </#if>
166
167 <#-- Publikations-Detail only -->
168
169 <#if layouttpl?contains("LAYOUT_KASDE_PUBLIKATIONEN_DETAIL")>
170 <#assign data = data + getRelatedPublication(json, locale, primaryKey, themeDisplay, FrontendService, ['primaryKey', 'title', 'href', 'subtitle', 'description', 'author', 'erscheinungsdatum', 'category', 'image', 'imagetype', 'meta', 'publicationSeriesCategory'])>
171 </#if>
172
173 <#-- Veranstaltungs-Detail only -->
174 <#if layouttpl?contains("LAYOUT_KASDE_VERANSTALTUNGEN_DETAIL")>
175
176 <#assign data = data + getRelatedVeranstaltung(json, locale, primaryKey, FrontendService)>
177
178 <#if isVLCColorScheme()>
179 <#-- Headline "Im Detail" for Veranstaltungs-Detail für VLC -->
180 <#assign data = data + { "headline" : languageUtil.get(locale, "details_vlc") }>
181 <#else>
182 <#-- Headline "Im Detail" for Veranstaltungs-Detail -->
183 <#assign data = data + { "headline" : languageUtil.get(locale, "details") }>
184 </#if>
185
186 <#-- ausgebucht -->
187 <#if hasContent('ausgebucht', locale, json)>
188 <#assign data = data + { "ausgebucht" : getValueForLanguage('ausgebucht', locale, json, "first") }>
189 </#if>
190
191 <#-- storniert -->
192 <#if hasContent('storniert', locale, json)>
193 <#assign data = data + { "storniert" : getValueForLanguage('storniert', locale, json, "first") }>
194 </#if>
195 <#-- Programm Data -->
196 <#assign program = getProgramm(json) >
197 <#if program?has_content>
198 <#assign data = data + { "program" : program } >
199 </#if>
200
201 <#assign registerLink = FrontendService.event.getEventSignupLink(themeDisplay)!"" />
202 </#if>
203
204 <#-- Beschreibung -->
205 <#if hasContent('beschreibung', locale, json)>
206 <#assign data = data + { "description" : getValueForLanguage('beschreibung', locale, json, "first") }>
207 </#if>
208
209 <#-- Contenttext -->
210 <#if (json["contenttext"][locale])?? >
211 <#assign data = data + { "text": json["contenttext"][locale] } >
212 <#elseif (json["contenttext"][default_locale])??>
213 <#assign data = data + { "text": json["contenttext"][default_locale] } >
214 </#if>
215
216 <#if (json["contentbildunterschrift"][locale])?? >
217 <#assign data = data + { "caption": json["contentbildunterschrift"][locale] } >
218 <#elseif (json["contentbildunterschrift"][default_locale])??>
219 <#assign data = data + { "caption": json["contentbildunterschrift"][default_locale] } >
220 </#if>
221
222 <#-- Bilderstrecke -->
223 <#assign series = getContentBilderstrecke(json) >
224 <#if series?has_content>
225 <#assign data = data + { "series" : series } />
226 </#if>
227
228 <#-- Media -->
229 <#if (json["contentmediumDMTKASDEMEDIUM"][locale])?? >
230 <#assign data = data + { "media": json["contentmediumDMTKASDEMEDIUM"][locale] } >
231 <#elseif (json["contentmediumDMTKASDEMEDIUM"][default_locale])??>
232 <#assign data = data + { "media": json["contentmediumDMTKASDEMEDIUM"][default_locale] } >
233 </#if>
234
235 <#-- Programm Download -->
236 <#if hasContent('documentDMTBASICDOCUMENT', locale, json)>
237 <#assign
238 documentDMTBASICDOCUMENTString = getValueForLanguage('documentDMTBASICDOCUMENT', locale, json, "first")
239 documentDMTBASICDOCUMENT = FrontendService.json.parseAsJson(documentDMTBASICDOCUMENTString)
240 dmtJson_doc = FrontendService.media.getDMTJsonObject( documentDMTBASICDOCUMENT.groupId?number, documentDMTBASICDOCUMENT.uuid, locale )!""
241 />
242
243 <#if dmtJson_doc?has_content>
244 <#assign url = FrontendService.media.getLinkToDMT(dmtJson_doc)/>
245 <#if url?has_content>
246 <#assign
247 data = data + {
248 "documentDMTBASICDOCUMENT": {
249 "title": documentDMTBASICDOCUMENT.title,
250 "url": url
251 }
252 }
253 />
254 </#if>
255 </#if>
256 </#if>
257
258 <#-- Biogramm Special Data lebenslauf, veroeffentlichungen, literatur -->
259 <#if hasContent('lebenslauf', locale, json)>
260 <#assign data = data + { "lebenslauf" : getValueForLanguage('lebenslauf', locale, json, "first") }>
261 </#if>
262
263 <#if hasContent('veroeffentlichungen', locale, json)>
264 <#assign data = data + { "veroeffentlichungen" : getValueForLanguage('veroeffentlichungen', locale, json, "first") }>
265 </#if>
266
267 <#if hasContent('literatur', locale, json)>
268 <#assign data = data + { "literatur" : getValueForLanguage('literatur', locale, json, "first") }>
269 </#if>
270
271 <#-- iFrame Content -->
272 <#if (json["contentiframeueberschrift"][locale])?? >
273 <#assign data = data + { "iframeueberschrift": json["contentiframeueberschrift"][locale] } >
274 <#elseif (json["contentiframeueberschrift"][default_locale])??>
275 <#assign data = data + { "iframeueberschrift": json["contentiframeueberschrift"][default_locale] } >
276 </#if>
277
278 <#if (json["einfuehrungText"][locale])?? >
279 <#assign data = data + { "introductoryText": json["einfuehrungText"][locale] } >
280 <#elseif (json["einfuehrungText"][default_locale])?? >
281 <#assign data = data + { "introductoryText": json["einfuehrungText"][default_locale] } >
282 <#elseif (json[FrontendService.article.getFieldNameByReferenceName(primaryKey, 'einfuehrungText')][locale])?? >
283 <#assign data = data + { "introductoryText": json[FrontendService.article.getFieldNameByReferenceName(primaryKey, 'einfuehrungText')][locale] } >
284 <#elseif (json[FrontendService.article.getFieldNameByReferenceName(primaryKey, 'einfuehrungText')][default_locale])?? >
285 <#assign data = data + { "introductoryText": json[FrontendService.article.getFieldNameByReferenceName(primaryKey, 'einfuehrungText')][default_locale] } >
286 </#if>
287
288 <#assign themenId = FrontendService.verbund.getThemenverbundByThema(themeDisplay, primaryKey) >
289
290 <#--prevArticle and nextArticle thema links-->
291 <#if isACColorScheme()>
292 <#if themenId?? && themenId?has_content >
293 <#assign data = data + { "nextArticle" : FrontendService.verbund.getThemenverbundNextLink(primaryKey, themenId, layoutUrl, locale, 'modulesKasThema', 'labelmodul', 'modulThemaKasTHEMENKASDESTRUCTURE') } >
294 <#assign data = data + { "prevArticle" : FrontendService.verbund.getThemenverbundPreviousLink(primaryKey, themenId, layoutUrl, locale, 'modulesKasThema', 'labelmodul', 'modulThemaKasTHEMENKASDESTRUCTURE') } >
295 </#if>
296 </#if>
297
298 <#if (json["contentiframeeinbindung"][locale])?? >
299 <#assign data = data + { "iframeeinbindung": json["contentiframeeinbindung"][locale] } >
300 <#elseif (json["contentiframeeinbindung"][default_locale])??>
301 <#assign data = data + { "iframeeinbindung": json["contentiframeeinbindung"][default_locale] } >
302 </#if>
303
304 <#if (json["contentiframeuntertitel"][locale])?? >
305 <#assign data = data + { "iframeuntertitel": json["contentiframeuntertitel"][locale] } >
306 <#elseif (json["contentiframeuntertitel"][default_locale])??>
307 <#assign data = data + { "iframeuntertitel": json["contentiframeuntertitel"][default_locale] } >
308 </#if>
309
310 <#if (json["contentiframequelle"][locale])?? >
311 <#assign data = data + { "iframequelle": json["contentiframequelle"][locale] } >
312 <#elseif (json["contentiframequelle"][default_locale])??>
313 <#assign data = data + { "iframequelle": json["contentiframequelle"][default_locale] } >
314 </#if>
315
316 <#if layouttpl?contains("LAYOUT_KASDE_THEMEN_DETAIL") || layouttpl?contains("LAYOUT_KASDE_STATIC") || layouttpl?contains("LAYOUT_KASDE_STATIC_HIDDEN") >
317 <#-- DropDownMenue Data -->
318 <#assign dropdownmenue = getDropDownMenue(json) >
319 <#if dropdownmenue?has_content>
320 <#assign data = data + { "dropdownmenue" : dropdownmenue } >
321 <#if (json["dropdownheader"][locale])?? >
322 <#assign data = data + { "dropdownheader" : getValueForLanguage('dropdownheader', locale, json, "first") } >
323 <#elseif (json["dropdownheader"][default_locale])??>
324 <#assign data = data + { "dropdownheader": getValueForLanguage('dropdownheader', default_locale, json, "first") } >
325 </#if>
326 </#if>
327 </#if>
328
329 <#if data?has_content>
330 <#assign content = content + [data]>
331 </#if>
332
333 </#if>
334
335<#else>
336 <#list entries as entry>
337
338 <#assign className = entry.getClassName()/>
339 <#if className = 'com.liferay.journal.model.JournalArticle'>
340
341 <#assign
342 primaryKey = entry.classPK?number
343 jsonString = FrontendService.article.getWebcontent(primaryKey)
344 json = FrontendService.json.parseAsJson(jsonString)
345 />
346 <@debugJsonString jsonString "ADT_KASDE_CONTENT" />
347
348 <#assign data = {} >
349
350 <#if (json["contenttext"][locale])?? >
351 <#assign data = data + { "text": json["contenttext"][locale] } >
352 <#elseif (json["contenttext"][default_locale])??>
353 <#assign data = data + { "text": json["contenttext"][default_locale] } >
354 </#if>
355
356 <#-- Bilderstrecke -->
357 <#assign series = getContentBilderstrecke(json) >
358 <#if series?has_content>
359 <#assign data = data + { "series" : series } />
360 </#if>
361
362 <#-- Media -->
363 <#if (json["contentmediumDMTKASDEMEDIUM"][locale])?? >
364 <#assign data = data + { "media": json["contentmediumDMTKASDEMEDIUM"][locale] } >
365 <#elseif (json["contentmediumDMTKASDEMEDIUM"][default_locale])??>
366 <#assign data = data + { "media": json["contentmediumDMTKASDEMEDIUM"][default_locale] } >
367 </#if>
368
369 <#if (json["contentbildunterschrift"][locale])?? >
370 <#assign data = data + { "caption": json["contentbildunterschrift"][locale] } >
371 <#elseif (json["contentbildunterschrift"][default_locale])??>
372 <#assign data = data + { "caption": json["contentbildunterschrift"][default_locale] } >
373 </#if>
374
375 <#-- iFrame Content -->
376 <#if (json["contentiframeueberschrift"][locale])?? >
377 <#assign data = data + { "iframeueberschrift": json["contentiframeueberschrift"][locale] } >
378 <#elseif (json["contentiframeueberschrift"][default_locale])??>
379 <#assign data = data + { "iframeueberschrift": json["contentiframeueberschrift"][default_locale] } >
380 </#if>
381
382 <#if (json["einfuehrungText"][locale])?? >
383 <#assign data = data + { "introductoryText": json["einfuehrungText"][locale] } >
384 <#elseif (json["einfuehrungText"][default_locale])?? >
385 <#assign data = data + { "introductoryText": json["einfuehrungText"][default_locale] } >
386 <#elseif (json[FrontendService.article.getFieldNameByReferenceName(primaryKey, 'einfuehrungText')][locale])?? >
387 <#assign data = data + { "introductoryText": json[FrontendService.article.getFieldNameByReferenceName(primaryKey, 'einfuehrungText')][locale] } >
388 <#elseif (json[FrontendService.article.getFieldNameByReferenceName(primaryKey, 'einfuehrungText')][default_locale])?? >
389 <#assign data = data + { "introductoryText": json[FrontendService.article.getFieldNameByReferenceName(primaryKey, 'einfuehrungText')][default_locale] } >
390 </#if>
391
392 <#assign themenId = FrontendService.verbund.getThemenverbundByThema(themeDisplay,primaryKey) >
393
394 <#--prevArticle and nextArticle thema links-->
395 <#if isACColorScheme()>
396 <#if themenId?? && themenId?has_content >
397 <#assign data = data + { "nextArticle" : FrontendService.verbund.getThemenverbundNextLink(primaryKey, themenId, layoutUrl, locale, 'modulesKasThema', 'labelmodul', 'modulThemaKasTHEMENKASDESTRUCTURE') } >
398 <#assign data = data + { "prevArticle" : FrontendService.verbund.getThemenverbundPreviousLink(primaryKey, themenId, layoutUrl, locale, 'modulesKasThema', 'labelmodul', 'modulThemaKasTHEMENKASDESTRUCTURE') } >
399 </#if>
400 </#if>
401
402 <#if (json["contentiframeeinbindung"][locale])?? >
403 <#assign data = data + { "iframeeinbindung": json["contentiframeeinbindung"][locale] } >
404 <#elseif (json["contentiframeeinbindung"][default_locale])??>
405 <#assign data = data + { "iframeeinbindung": json["contentiframeeinbindung"][default_locale] } >
406 </#if>
407
408 <#if (json["contentiframeuntertitel"][locale])?? >
409 <#assign data = data + { "iframeuntertitel": json["contentiframeuntertitel"][locale] } >
410 <#elseif (json["contentiframeuntertitel"][default_locale])??>
411 <#assign data = data + { "iframeuntertitel": json["contentiframeuntertitel"][default_locale] } >
412 </#if>
413
414 <#if (json["contentiframequelle"][locale])?? >
415 <#assign data = data + { "iframequelle": json["contentiframequelle"][locale] } >
416 <#elseif (json["contentiframequelle"][default_locale])??>
417 <#assign data = data + { "iframequelle": json["contentiframequelle"][default_locale] } >
418 </#if>
419
420 <#if layouttpl?contains("LAYOUT_KASDE_THEMEN_DETAIL") || layouttpl?contains("LAYOUT_KASDE_STATIC") || layouttpl?contains("LAYOUT_KASDE_STATIC_HIDDEN") || layouttpl?contains("LAYOUT_KASDE_MICROSITE_HOME") >
421 <#-- DropDownMenue Data -->
422 <#assign dropdownmenue = getDropDownMenue(json) >
423 <#if dropdownmenue?has_content>
424 <#assign data = data + { "dropdownmenue" : dropdownmenue } >
425 <#if (json["dropdownheader"][locale])?? >
426 <#assign data = data + { "dropdownheader" : getValueForLanguage('dropdownheader', locale, json, "first") } >
427 <#elseif (json["dropdownheader"][default_locale])??>
428 <#assign data = data + { "dropdownheader": getValueForLanguage('dropdownheader', default_locale, json, "first") } >
429 </#if>
430 </#if>
431 </#if>
432
433 <#if data?has_content>
434 <#assign content = content + [data]>
435 </#if>
436
437 </#if>
438
439 </#list>
440
441</#if>
442
443<#if content?has_content >
444 <#if !layouttpl?contains("LAYOUT_KASDE_PERSONEN_DETAIL")>
445 <@PMShare content registerLink />
446 <@PMPageContent portletId content classModifier />
447
448 <#if layouttpl?contains("LAYOUT_KASDE_VERANSTALTUNGEN_DETAIL")>
449 <#assign
450 translations = {
451 "speakers": languageUtil.get(locale, 'referenten'),
452 "showAll": languageUtil.get(locale, 'accordion.alle.anzeigen'),
453 "showLess": languageUtil.get(locale, 'accordion.weniger.anzeigen'),
454 "profile": languageUtil.get(locale, 'zum.profil')
455 }
456
457 translationsString = FrontendService.json.transformToJson(translations)
458 />
459
460 <#-- check if the referenten-field contains IDs - workaround for speaker-component -->
461 <#if hasContent('referenten', locale, json)>
462 <#assign referentenHtmlString = getValueForLanguage('referenten', locale, json, "first") >
463
464 <#assign regex = '<span class="inner-referenten-list-header">\\s*(\\d{4,})\\s*</span>' />
465
466 <#assign has4DigitNumbers = (referentenHtmlString?matches(regex)?size > 0) />
467
468 <#if has4DigitNumbers>
469 <speaker-view resource-prim-key-veranstaltung="${primaryKey}" translations-string='${translationsString}'></speaker-view>
470 </#if>
471 </#if>
472 </#if>
473 </#if>
474<#elseif (editmode?? && editmode)>
475 <@errorMessage languageUtil.get(locale, "keine.inhalte.vorhanden") "ADT_KASDE_CONTENT" layouttpl currentUrl />
476</#if>
เกิดเหตุผิดพลาดในระหว่างเตรียมเท็มเพลต
'article' parameter of getJsonFromArticle() was not a hash / object with member 'classPK' and also not an empty string (maybe you forgot a 'FrontendService.json.parseAsJson()' to deserialize json earlier?): "null" ---- FTL stack trace ("~" means nesting-related): - Failed at: #stop ("'article' parameter of getJso... [in template "kas-de-theme_SERVLET_CONTEXT_/templates/functions/relatedContentUtil.ftl" in function "getJsonFromArticle" at line 283, column 5] ----
1<#include "${fullTemplatesPath}/functions/relatedContentUtil.ftl" />
2<#include "${fullTemplatesPath}/functions/freemarkerUtil.ftl" />
3<#include "${fullTemplatesPath}/macros/debugging.ftl" />
4<#include "${fullTemplatesPath}/functions/liferayServicesUtil.ftl" />
5
6<#include "${fullTemplatesPath}/macros/page-modules/PMNavigation.ftl" />
7<#include "${fullTemplatesPath}/macros/page-modules/PMMarginalspalte.ftl" />
8<#include "${fullTemplatesPath}/macros/atomic-modules/AMVenue.ftl" />
9<#include "${fullTemplatesPath}/macros/atomic-modules/AMMarginalContent.ftl" />
10<#include "${fullTemplatesPath}/macros/atomic-modules/AMPricing.ftl" />
11<#include "${fullTemplatesPath}/macros/atomic-modules/AMPerson.ftl" />
12<#include "${fullTemplatesPath}/macros/atomic-modules/AMMediaElement.ftl" />
13<#include "${fullTemplatesPath}/macros/atomic-modules/AMDatetime.ftl" />
14<#include "${fullTemplatesPath}/macros/atomic-modules/AMMap.ftl" />
15<#include "${fullTemplatesPath}/macros/atomic-modules/AMMarginalLinks.ftl" />
16<#include "${fullTemplatesPath}/macros/atomic-modules/AMCollapsibleListItem.ftl" />
17
18<#assign
19 JournalArticleLocalService = getJournalArticleLocalService()
20
21
22
23 themeDisplay = getThemeDisplay()
24 languageId = themeDisplay.getLocale()
25 editmode = FrontendService.user.isPrivilegedUser(themeDisplay)
26
27 groupId = themeDisplay.getScopeGroupId()
28 currentUrl = themeDisplay.getURLCurrent()
29
30 layout = themeDisplay.getLayout()
31 layouttpl = layout.getTypeSettingsProperties().getProperty("layout-template-id")
32
33 isMicrosite = FrontendService.site.isMicrosite(groupId)!false
34/>
35
36<#-- Veranstaltungen-Detail, Publikationen-Detail -->
37<#if currentUrl?contains("/-/content") >
38
39 <#assign journalArticle = FrontendService.article.getArticleToUrl(currentUrl, groupId?number)! >
40
41 <#if journalArticle?has_content>
42 <#if journalArticle.resourcePrimKey??>
43 <#assign primaryKey = journalArticle.resourcePrimKey?number >
44 <#elseif journalArticle.classPK??>
45 <#assign primaryKey = journalArticle.classPK?number >
46 </#if>
47
48 <#assign
49 jsonString = FrontendService.article.getWebcontent(primaryKey)
50 json = FrontendService.json.parseAsJson(jsonString)
51 />
52
53
54 <@debugJsonString jsonString "ADT_KASDE_MARGINALSPALTE" />
55
56 <#if hasContent('title', locale, json)>
57 <#assign
58 pageName = ""
59 title = " - " + getValueForLanguage("title", languageId, json, "first")
60 />
61 <#if isMicrosite >
62 <#assign
63 pageGroup = layout.getGroup()
64 pageName = " - " + htmlUtil.escape(pageGroup.getDescriptiveName())
65 />
66 </#if>
67
68 </#if>
69
70 <#assign content = getMarginalContent(json, locale, primaryKey, FrontendService, JournalArticleLocalService, themeDisplay) >
71
72
73 <#if hasContent('ausgebucht', locale, json)>
74 <#assign content = content + { "ausgebucht" : getValueForLanguage('ausgebucht', locale, json, "first") }>
75 </#if>
76
77 <#if hasContent('storniert', locale, json)>
78 <#assign content = content + { "storniert" : getValueForLanguage('storniert', locale, json, "first") }>
79 </#if>
80
81 <#if hasContent('document_pdfDMTBASICDOCUMENT', locale, json)>
82 <#assign
83 pdfDocumentString = getValueForLanguage('document_pdfDMTBASICDOCUMENT', locale, json, "first")
84 pdfDocument = FrontendService.json.parseAsJson(pdfDocumentString)
85 fileEntry = FrontendService.media.getFileEntry(pdfDocument.uuid, pdfDocument.groupId?number)!/>
86 <#if fileEntry?has_content>
87 <#assign
88 linkToThumbnail = FrontendService.link.getThumbnailSrc(fileEntry , themeDisplay)
89 covermedia = getDefaultMediaObject(linkToThumbnail, "pdf cover")
90 covermedia = covermedia + {"hrefSource" : content.pdfBasicDocumentUrl.url }
91 content = content + { "covermedia": covermedia }
92 />
93 </#if>
94 </#if>
95
96 <#if layouttpl?contains("LAYOUT_KASDE_VERANSTALTUNGEN_DETAIL")>
97 <#assign calendar = FrontendService.event.createCalendarFile(primaryKey, locale) />
98 <#assign content = content + {"calendar": calendar } />
99 </#if>
100 <#elseif (editmode?? && editmode)>
101 <@errorMessage languageUtil.get(locale, "kein.journalArticle.gefunden") "ADT_KASDE_MARGINALSPALTE" layouttpl />
102 </#if>
103
104<#-- Themen-Detail and others -->
105<#else>
106 <#-- content in marginalspalte -->
107 <#if entries?has_content>
108 <#assign
109 entry = entries?first
110 primaryKey = entry.classPK?number
111
112 jsonString = FrontendService.article.getWebcontent(primaryKey)
113 json = FrontendService.json.parseAsJson(jsonString)
114 />
115 <@debugJsonString jsonString "ADT_KASDE_MARGINALSPALTE" />
116 <@debugJson json "MARGINALSPALTE_CONTENT_JSON" />
117
118 <#assign content = getMarginalContent(json, locale, primaryKey, FrontendService, JournalArticleLocalService, themeDisplay) >
119 <#elseif (editmode?? && editmode)>
120 <@errorMessage languageUtil.get(locale, "es.existieren.keine.entries") "ADT_KASDE_MARGINALSPALTE" layouttpl />
121 </#if>
122</#if>
123
124
125<#if content??>
126 <#if layouttpl?contains("LAYOUT_KASDE_VERANSTALTUNGEN_DETAIL")>
127 <#assign type = "veranstaltung" />
128
129 <#elseif layouttpl?contains("LAYOUT_KASDE_PUBLIKATIONEN_DETAIL")>
130 <#assign type = "publikation" />
131 <#elseif layouttpl?contains("LAYOUT_KASDE_THEMEN_DETAIL")>
132 <#assign type = "thema" />
133 <#else>
134 <#assign type = "default" />
135 </#if>
136
137 <#assign content = content + {"type": type } />
138 <@debugJsonString content "ADT_KASDE_MARGINALSPALTE_CONTENT" />
139 <@PMMarginalspalte "ADT_KASDE_MARGINALSPALTE" content AMArticle AMPerson AMVenue AMPricing AMMediaElement AMDatetime AMMap AMMarginalContent AMMarginalLinks/>
140<#elseif (editmode?? && editmode)>
141 <@errorMessage languageUtil.get(locale, "entries.enthalten.keinen.content") "ADT_KASDE_MARGINALSPALTE" layouttpl />
142</#if>
หัวข้อ
เกิดเหตุผิดพลาดในระหว่างเตรียมเท็มเพลต
For "." left-hand operand: Expected a hash, but this has evaluated to a string (wrapper: f.t.SimpleScalar): ==> place [in template "kas-de-theme_SERVLET_CONTEXT_/templates/functions/content-functions/CFPrepareLocationData.ftl" at line 11, column 73] ---- FTL stack trace ("~" means nesting-related): - Failed at: placeString = FrontendService.article... [in template "kas-de-theme_SERVLET_CONTEXT_/templates/functions/content-functions/CFPrepareLocationData.ftl" in function "prepareLocationData" at line 11, column 21] ----
1<#--
2 used @ Detailseite, PARTNER
3 used @ Veranstaltungs-Detailseite, PARTNER + Bereitgestellt von
4-->
5
6<#include "${fullTemplatesPath}/functions/relatedContentUtil.ftl" />
7<#include "${fullTemplatesPath}/functions/contentUtil.ftl" />
8<#include "${fullTemplatesPath}/macros/debugging.ftl" />
9
10<#include "${fullTemplatesPath}/macros/page-modules/PMContextPartner.ftl" />
11<#include "${fullTemplatesPath}/macros/page-modules/PMPartner.ftl" />
12<#include "${fullTemplatesPath}/macros/page-modules/PMContext.ftl" />
13<#include "${fullTemplatesPath}/macros/page-modules/PMPromo.ftl" />
14
15<#include "${fullTemplatesPath}/macros/atomic-modules/AMPartner.ftl" />
16<#include "${fullTemplatesPath}/macros/atomic-modules/AMMediaElement.ftl" />
17
18<#assign
19
20
21 JournalArticleLocalService = getJournalArticleLocalService()
22
23 themeDisplay = getThemeDisplay()
24 currentUrl = themeDisplay.getURLCurrent()
25 locale = themeDisplay.getLocale()
26 layout = themeDisplay.getLayout()
27
28 layouttpl = layout.getTypeSettingsProperties().getProperty("layout-template-id")
29 editmode = FrontendService.user.isPrivilegedUser(themeDisplay)
30/>
31
32<#-- PARTNER + "Bereitgestellt von" (Veranstaltungs-Detail) -->
33<#-- check if it is a hidden detail page - get article from url -->
34<#if currentUrl?contains("/-/content") >
35 <#assign journalArticle = FrontendService.article.getArticleToUrl(currentUrl, groupId?number)!"" >
36
37 <#if journalArticle?has_content >
38 <#assign
39 primaryKey = journalArticle.resourcePrimKey?number
40 jsonString = FrontendService.article.getWebcontent(primaryKey)
41 json = FrontendService.json.parseAsJson(jsonString)
42
43 title = journalArticle.getTitle(locale)
44 data = {
45 "title": title
46 }
47 />
48 <@debugJsonString jsonString "ADT_KASDE_CONTEXT" />
49
50 <#assign content = getRelatedPublication(json, locale, primaryKey, themeDisplay, FrontendService ) >
51
52 <#if hasContentForSequence('partnerWCSKASDEPARTNER', locale, json)>
53 <#assign
54 partner = []
55 partners = getValueForLanguageAnsprechpartner('partnerWCSKASDEPARTNER', locale, json)
56 />
57
58 <#list partners as partnerEntry>
59 <#if partnerEntry?has_content >
60 <#assign
61 partnerJson = getJsonFromArticle(FrontendService.json.parseAsJson(partnerEntry), JournalArticleLocalService, FrontendService)
62 partnerData = getRelatedPartner(partnerJson, themeDisplay, locale, FrontendService)!""
63 />
64 <@debugJson partnerJson "ADT_KASDE_CONTEXT-partnerWCSKASDEPARTNER" />
65
66 <#if partnerData?has_content >
67 <#assign
68 partner = partner + [partnerData]
69 />
70 </#if>
71 </#if>
72 </#list>
73 <#assign content = content + {"partner": partner} >
74 </#if>
75
76 <#if content?has_content>
77
78 <#-- PARTNER -->
79 <#if content.partner?? >
80 <div class="o-page-module o-page-module--border">
81 <@PMContextPartner "ADT_KASDE_PARTNER_CONTEXT" content.partner PMPartner AMPartner AMMediaElement languageUtil.get(locale, "partner") "c-page-context--veranstaltungdetail" />
82 </div>
83 <#elseif (editmode?? && editmode)>
84 <@errorMessage languageUtil.get(locale, "keine.partner.zum.thema") "ADT_KASDE_CONTEXT" layouttpl currentUrl />
85 </#if>
86
87 <#if hasValue('bereitgestelltvon', locale, json)>
88 <#assign
89 bereitgestelltvon = getValueForLanguage('bereitgestelltvon', locale, json, "first")
90 />
91
92 <#-- "Bereitsgestellt von" -->
93 <#if bereitgestelltvon?has_content >
94 <#assign
95 data = {
96 "title": languageUtil.get(locale, "bereitgestellt.von"),
97 "copy": bereitgestelltvon
98 }
99 />
100
101 <#if hasValue('bereitgestelltvonlink', locale, json)>
102 <#assign data = data + { "href" : getValueForLanguage('bereitgestelltvonlink', locale, json, "first") } />
103 </#if>
104
105 <#assign data = data + { "uniquename" : "presented-by" } />
106
107 <div class="o-page-module o-page-module--border">
108 <@PMContext "ADT_KASDE_ABOUT_CONTEXT" data "c-page-context--veranstaltungdetail c-page-context--presented-by" />
109 </div>
110 <#elseif (editmode?? && editmode)>
111 <@errorMessage languageUtil.get(locale, "es.existieren.keine.entries") "ADT_KASDE_CONTEXT" layouttpl currentUrl />
112 </#if>
113 <#elseif (editmode?? && editmode)>
114 <@errorMessage languageUtil.get(locale, "es.existieren.keine.entries") "ADT_KASDE_CONTEXT" layouttpl currentUrl />
115 </#if>
116 <#elseif (editmode?? && editmode)>
117 <@errorMessage languageUtil.get(locale, "es.existieren.keine.entries") "ADT_KASDE_CONTEXT" layouttpl currentUrl />
118 </#if>
119 </#if>
120
121<#-- PARTNER -->
122<#elseif entries?has_content>
123 <#assign content = [] >
124
125 <#list entries as entry>
126 <#assign
127 primaryKey = entry.classPK?number
128 jsonString = FrontendService.article.getWebcontent(primaryKey)
129 json = FrontendService.json.parseAsJson(jsonString)
130
131 headline = languageUtil.get(locale, "partner")
132 />
133 <@debugJsonString jsonString "ADT_KASDE_CONTEXT" />
134
135 <#-- "PARTNER List" -->
136 <#if hasContentForSequence('partnerWCSKASDEPARTNER', locale, json)>
137 <#assign
138 partner = []
139 partners = getValueForLanguageAnsprechpartner('partnerWCSKASDEPARTNER', locale, json)
140 />
141
142 <#list partners as partnerEntry>
143 <#if partnerEntry?has_content >
144 <#assign
145 partnerJson = getJsonFromArticle(partnerEntry, JournalArticleLocalService, FrontendService)
146 partnerData = getRelatedPartner(partnerJson, themeDisplay, locale, FrontendService)!""
147 />
148 <#if partnerData?has_content >
149 <#assign
150 partner = partner + [partnerData]
151 />
152 </#if>
153 </#if>
154 </#list>
155
156 <#if partner?has_content>
157 <div class="o-page-module o-page-module--border">
158 <@PMContextPartner "ADT_KASDE_PARTNER_CONTEXT" partner PMPartner AMPartner AMMediaElement headline "c-page-context--themadetail" />
159 </div>
160 <#elseif (editmode?? && editmode && entry?is_first)>
161 <@errorMessage languageUtil.get(locale, "keine.partner.zum.thema") "ADT_KASDE_CONTEXT" layouttpl currentUrl />
162 </#if>
163 <#elseif (editmode?? && editmode && entry?is_first)>
164 <@errorMessage languageUtil.get(locale, "keine.partner.zum.thema") "ADT_KASDE_CONTEXT" layouttpl currentUrl />
165 </#if>
166
167 </#list>
168<#elseif (editmode?? && editmode)>
169 <@errorMessage languageUtil.get(locale, "es.existieren.keine.entries") "ADT_KASDE_CONTEXT" layouttpl currentUrl />
170</#if>