Käytämme evästeitä tarjotaksemme mahdollisimman hyvän käyttäjäkokemuksen. Käyttämällä sivustoa hyväksyt evästeiden käytön.
Lisätietoja
Ajankohtaista
Sisältöjulkaisija
Virhe tapahtui prosessoidessa esitysmallia.
Java method "static com.liferay.journal.service.JournalArticleLocalServiceUtil.getArticle(long, String)" threw an exception; see cause exception in the Java stack trace. ---- FTL stack trace ("~" means nesting-related): - Failed at: #assign reservedArticle = journalArti... [in template "391972#392006#UUTINEN_TMPL-1.0.0" at line 10, column 1] ----
1<#assign displaydate = .vars['reserved-article-display-date'].data>
2<#assign originalLocale = .locale>
3<#setting locale = localeUtil.getDefault()>
4<#assign displaydate = displaydate?datetime("EEE, d MMM yyyy HH:mm:ss Z")>
5<#assign locale = originalLocale>
6
7<#assign journalArticleId = .vars['reserved-article-id'].data />
8<#assign journalArticleLocalServiceUtil = staticUtil["com.liferay.journal.service.JournalArticleLocalServiceUtil"] />
9<#assign layoutLocalServiceUtil = staticUtil["com.liferay.portal.kernel.service.LayoutLocalServiceUtil"] />
10<#assign reservedArticle = journalArticleLocalServiceUtil.getArticle(groupId, journalArticleId) />
11<#if reservedArticle?? && reservedArticle.getLayout()??>
12 <#assign contentUrl = reservedArticle.getLayout().getFriendlyURL(localeUtil.getDefault()) />
13<#else>
14 <!-- Error while fetching article display page url -->
15 <#assign contentUrl = "#" />
16</#if>
17<div class="article-container clear">
18
19 <!-- article header -->
20
21 <div class="article-header-container">
22 <div class="article-header">
23 <div class="article-date">
24 ${displaydate?string["dd.MM.yyyy"]}
25 </div>
26 <h1>${articleTitle.getData()}</h1>
27 <div class="article-ingress">
28 ${articleTitle.articleIngress.getData()}
29 </div>
30 </div>
31 </div>
32
33 <!-- article content -->
34
35 <div class="article-content">
36 ${articleContent.getData()}
37 </div>
38 <div style="display: none;">
39 <#if articleThumbnail.getData()?? && articleThumbnail.getData() != "">
40 <img style="display:none;" data-fileentryid="${articleThumbnail.getAttribute("fileEntryId")}" alt="${articleThumbnail.getAttribute("alt")}" src="${articleThumbnail.getData()}" />
41 </#if>
42 </div>
43 <!-- repeatable link list -->
44
45<#if articleLinkList.getSiblings()?has_content>
46 <#list articleLinkList.getSiblings() as cur_linklist>
47 <#if cur_linklist.articleLinkText.getSiblings()[0].getData()?has_content>
48 <div class="article-linklist">
49 <#if cur_linklist.getData()?has_content>
50 <div class ="article-linklist-title">
51 <h3>${cur_linklist.getData()}</h3>
52 </div>
53 </#if>
54 <ul class="link-list container">
55 <#if cur_linklist.articleLinkText.getSiblings()?has_content>
56 <#list cur_linklist.articleLinkText.getSiblings() as cur_link>
57 <li class="article-link col-md-6 col-xs-12">
58 <i class="icon-chevron-right"></i><a href="${cur_link.articleLinkAdress.getData()}">${cur_link.getData()}</a>
59 </li>
60 </#list>
61 </#if>
62 </ul>
63 </div>
64 </#if>
65 </#list>
66</#if>
67
68<#if articleContactList.getSiblings()?has_content>
69 <#list articleContactList.getSiblings() as cur_contactlist>
70 <#if cur_contactlist.articleContactText.getSiblings()[0].getData()?has_content>
71 <div class="article-linklist contact-linklist">
72 <#if cur_contactlist.getData()?has_content>
73 <div class ="article-linklist-title contact-title">
74 <h3>${cur_contactlist.getData()}</h3>
75 </div>
76 </#if>
77 <ul class="link-list contact-link container">
78 <#if cur_contactlist.articleContactText.getSiblings()?has_content>
79 <#list cur_contactlist.articleContactText.getSiblings() as cur_contact>
80 <li class="article-contact col-md-6 col-xs-12">
81 <div class="contact-name-container">
82 <i class="icon-chevron-right"></i>${cur_contact.getData()}
83 </div>
84 <div class="article-contact-info">
85 <p>${cur_contact.articleContactTitle.getData()}</p>
86 <p>${cur_contact.articleContactAdress.getData()}</p>
87 <p>${cur_contact.articleContactNumber.getData()}</p>
88 <p>${cur_contact.articleContactEmail.getData()}</p>
89 </div>
90 </li>
91 </#list>
92 </#if>
93 </ul>
94 </div>
95 </#if>
96 </#list>
97</#if>
98 <div class="return-links">
99 <div class="return-to-previous">
100 <a class="return-link" href="javascript:history.back()">
101 <i class="icon-chevron-left"></i>
102 <@liferay.language key="back-to-previous" />
103 </a>
104 </div>
105 <div style="display: none;" id="return-to-news-listing" class="return-to-news-listing">
106 <a id="return-to-news-list-link" class="return-link" href="${contentUrl}">
107 <i class="icon-chevron-left"></i>
108 <@liferay.language key="back-to-news-list" />
109 </a>
110 </div>
111 </div>
112</div>
113
114
115
116<style>
117 div.h2 {
118 display:none !important;
119 }
120</style>
121<script type="text/javascript">
122window.onload = function () {
123 var currentLocation = window.location.toString();
124 if(currentLocation.includes("/-/")) {
125 var returnLinkContainer = document.getElementById("return-to-news-listing");
126 var returnLinkElement = document.getElementById("return-to-news-list-link");
127 // if reserved journalarticle layout isn't set, this will do the trick at least when user is opening this article from /uutiset page
128 if (returnLinkElement.href.includes("/-/")) {
129 var newsLocation = currentLocation.split("/-/")[0];
130 //console.log("changing url to newlocation: "+newsLocation);
131 returnLinkElement.href=newsLocation;
132 returnLinkContainer.style.display = "block";
133 }
134 returnLinkContainer.style.display = "block";
135 }
136}
137</script>