Lista aktualności Lista aktualności

Wystąpił błąd podczas przetwarzania szablonu.
Error on line 213, column 33 in 10097#20183917#ARTICLE-EVENT
dlFileEntryLocalService.getFileEntry(groupId, folderId, title) is undefined.
It cannot be assigned to file
1<#setting locale="${locale?string}"> 
2 
3<#assign journalArticleLocalService = serviceLocator.findService("com.liferay.portlet.journal.service.JournalArticleLocalService") /> 
4<#assign dlFileEntryLocalService = serviceLocator.findService("com.liferay.portlet.documentlibrary.service.DLFileEntryLocalService") /> 
5 
6<#assign journalArticleId = .vars["reserved-article-id"].data?replace('.', '-') /> 
7<#assign journalArticle = journalArticleLocalService.getArticle(getterUtil.getLong(groupId), journalArticleId) /> 
8<#assign journalArticleCreateDate = journalArticle.getCreateDate() /> 
9<#assign journalArticleModifiedDate = journalArticle.getModifiedDate() /> 
10<#assign journalArticleAuthor = .vars["reserved-article-author-name"].data /> 
11<#if coauthors?? && coauthors.data?has_content> 
12    <#assign journalArticleAuthor = coauthors.data /> 
13</#if> 
14<#if title?? && title.data?has_content> 
15    <#assign journalArticleTitle = title.data /> 
16<#else> 
17    <#assign journalArticleTitle = .vars["reserved-article-title"].data /> 
18</#if> 
19<#assign journalArticleUrlTitle = journalArticle.getUrlTitle() /> 
20 
21<#assign serviceContext = staticUtil["com.liferay.portal.service.ServiceContextThreadLocal"].getServiceContext() /> 
22<#assign themeDisplay = serviceContext.getThemeDisplay() /> 
23<#assign portletId = themeDisplay.getPortletDisplay().getId() /> 
24 
25<div id="article-${journalArticleId}" class="nfh-cp-article"> 
26 
27    <h1 class="title">${journalArticleTitle}</h1> 
28 
29    <div class="metadata">${journalArticleModifiedDate?string["dd.MM.yyyy"]} | ${journalArticleAuthor}</div> 
30 
31    <#-- MEDIA SPOŁECZNOŚCIOWE --> 
32    <#assign printGroupId = "" /> 
33    <#if journalArticle.groupId != themeDisplay.scopeGroupId> 
34        <#assign printGroupId = themeDisplay.scopeGroupId /> 
35    </#if> 
36    <div class="social-media"> 
37        <div class="addthis_toolbox addthis_default_style"> 
38            <a class="addthis_button_facebook_like" fb:like:layout="button_count"></a> 
39            <a class="addthis_button_google_plusone" g:plusone:size="medium"></a> 
40            <a class="addthis_button_tweet"></a> 
41            <input type="image" alt="${languageUtil.get(locale, "print")}" src="${themeDisplay.pathThemeImages}/nfh-cp/icon-print-20x17.png"                 onclick="Nfhcp.AssetPublisherPortlet.printFullContent('${portletId}', '${journalArticleId}', '${printGroupId}', '${journalArticleUrlTitle}');" class="print"/> 
42            <script type="text/javascript">var addthis_config = {"data_track_addressbar":true};</script> 
43            <script type="text/javascript" src="//s7.addthis.com/js/300/addthis_widget.js#pubid=ra-55c31ccb1e1d814d"></script> 
44        </div> 
45    </div> 
46 
47    <#-- ZDJĘCIE GÓRNE --> 
48    <#assign showImageGallery = false /> 
49    <#if mainphoto?? && mainphoto.data?has_content> 
50        <#assign showImageGallery = true /> 
51    </#if> 
52    <#if showImageGallery> 
53        <div id="gallery-${journalArticleId}" class="event"> 
54            <#assign eventDateFromAsString1 = "" /> 
55            <#assign eventDateFromAsString2 = "" /> 
56            <#assign eventDateToAsString2 = "" /> 
57 
58            <#if event?? && event.datefrom?? && event.datefrom.data?has_content> 
59                <#if event.datefrom.data?matches("^\\d+$")> 
60                    <#assign eventDateFrom = event.datefrom.data?number?number_to_datetime /> 
61                <#else> 
62                    <#assign eventDateFrom = event.datefrom.data?datetime("yyyy-MM-dd HH:mm") /> 
63                </#if> 
64 
65                <#assign eventDateFromAsString1 = eventDateFrom?string("d '<span>'MMMM'</span>'") /> 
66                <#assign eventDateFromAsString2 = eventDateFrom?string("d MMMM 'godz.' HH:mm") /> 
67 
68                <#assign eventDateFromAsString1 = eventDateFromAsString1?replace("styczeń", "stycznia") /> 
69                <#assign eventDateFromAsString1 = eventDateFromAsString1?replace("luty", "lutego") /> 
70                <#assign eventDateFromAsString1 = eventDateFromAsString1?replace("marzec", "marca") /> 
71                <#assign eventDateFromAsString1 = eventDateFromAsString1?replace("kwiecień", "kwietnia") /> 
72                <#assign eventDateFromAsString1 = eventDateFromAsString1?replace("maj$", "maja") /> 
73                <#assign eventDateFromAsString1 = eventDateFromAsString1?replace("czerwiec", "czerwca") /> 
74                <#assign eventDateFromAsString1 = eventDateFromAsString1?replace("lipiec", "lipca") /> 
75                <#assign eventDateFromAsString1 = eventDateFromAsString1?replace("sierpień", "sierpnia") /> 
76                <#assign eventDateFromAsString1 = eventDateFromAsString1?replace("wrzesień", "września") /> 
77                <#assign eventDateFromAsString1 = eventDateFromAsString1?replace("październik$", "października") /> 
78                <#assign eventDateFromAsString1 = eventDateFromAsString1?replace("listopad$", "listopada") /> 
79                <#assign eventDateFromAsString1 = eventDateFromAsString1?replace("grudzień", "grudnia") /> 
80 
81                <#assign eventDateFromAsString2 = eventDateFromAsString2?replace("styczeń", "stycznia") /> 
82                <#assign eventDateFromAsString2 = eventDateFromAsString2?replace("luty", "lutego") /> 
83                <#assign eventDateFromAsString2 = eventDateFromAsString2?replace("marzec", "marca") /> 
84                <#assign eventDateFromAsString2 = eventDateFromAsString2?replace("kwiecień", "kwietnia") /> 
85                <#assign eventDateFromAsString2 = eventDateFromAsString2?replace("maj$", "maja") /> 
86                <#assign eventDateFromAsString2 = eventDateFromAsString2?replace("czerwiec", "czerwca") /> 
87                <#assign eventDateFromAsString2 = eventDateFromAsString2?replace("lipiec", "lipca") /> 
88                <#assign eventDateFromAsString2 = eventDateFromAsString2?replace("sierpień", "sierpnia") /> 
89                <#assign eventDateFromAsString2 = eventDateFromAsString2?replace("wrzesień", "września") /> 
90                <#assign eventDateFromAsString2 = eventDateFromAsString2?replace("październik$", "października") /> 
91                <#assign eventDateFromAsString2 = eventDateFromAsString2?replace("listopad$", "listopada") /> 
92                <#assign eventDateFromAsString2 = eventDateFromAsString2?replace("grudzień", "grudnia") /> 
93            </#if> 
94            <#if event?? && event.dateto?? && event.dateto.data?has_content> 
95                <#if event.dateto.data?matches("^\\d+$")> 
96                    <#assign eventDateTo = event.dateto.data?number?number_to_datetime /> 
97                <#else> 
98                    <#assign eventDateTo = event.dateto.data?datetime("yyyy-MM-dd HH:mm") /> 
99                </#if> 
100 
101                <#assign eventDateToAsString2 = eventDateTo?string("d MMMM 'godz.' HH:mm") /> 
102 
103                <#assign eventDateToAsString2 = eventDateToAsString2?replace("styczeń", "stycznia") /> 
104                <#assign eventDateToAsString2 = eventDateToAsString2?replace("luty", "lutego") /> 
105                <#assign eventDateToAsString2 = eventDateToAsString2?replace("marzec", "marca") /> 
106                <#assign eventDateToAsString2 = eventDateToAsString2?replace("kwiecień", "kwietnia") /> 
107                <#assign eventDateToAsString2 = eventDateToAsString2?replace("maj$", "maja") /> 
108                <#assign eventDateToAsString2 = eventDateToAsString2?replace("czerwiec", "czerwca") /> 
109                <#assign eventDateToAsString2 = eventDateToAsString2?replace("lipiec", "lipca") /> 
110                <#assign eventDateToAsString2 = eventDateToAsString2?replace("sierpień", "sierpnia") /> 
111                <#assign eventDateToAsString2 = eventDateToAsString2?replace("wrzesień", "września") /> 
112                <#assign eventDateToAsString2 = eventDateToAsString2?replace("październik$", "października") /> 
113                <#assign eventDateToAsString2 = eventDateToAsString2?replace("listopad$", "listopada") /> 
114                <#assign eventDateToAsString2 = eventDateToAsString2?replace("grudzień", "grudnia") /> 
115            </#if> 
116 
117            <div class="image-wrapper"> 
118                <div class="event-date">${eventDateFromAsString1}</div> 
119                <img src="${mainphoto.data}&height=305"> 
120            </div> 
121 
122            <div class="event-data"> 
123                <div class="header">${languageUtil.get(locale, "event-information")}</div> 
124 
125                <div class="subheader">${languageUtil.get(locale, "event-date")}</div> 
126                <div class="date table"> 
127                    <div class="row"> 
128                        <div class="from-date cell"><img src="${themeDisplay.pathThemeImages}/nfh-cp/event-from-date-marker-10x9.png"/></div> 
129                        <div class="from-date cell"><span>${eventDateFromAsString2}</span></div> 
130                    </div> 
131                    <div class="row"> 
132                        <div class="to-date cell"><img src="${themeDisplay.pathThemeImages}/nfh-cp/event-to-date-marker-10x9.png"/></div> 
133                        <div class="to-date cell"><span>${eventDateToAsString2}</span></div> 
134                    </div> 
135                </div> 
136                 
137                <div class="subheader">${languageUtil.get(locale, "location")}</div> 
138                <div class="location table"> 
139                    <#if event?? && event.place?? && event.place.data?has_content> 
140                        <div class="row"> 
141                            <div class="cell"><span>${event.place.data}</span></div> 
142                        </div> 
143                    </#if> 
144                    <#if (event?? && event.person?? && event.person.data?has_content) || (event?? && event.email?? && event.email.data?has_content)> 
145                        <div class="row"> 
146                            <div class="cell"><a href="mailto:${event.email.data}">${event.person.data}</a></div> 
147                        </div> 
148                    <#elseif event?? && event.email?? && event.email.data?has_content> 
149                        <div class="row"> 
150                            <div class="cell"><span>${event.email.data}</span></div> 
151                        </div> 
152                    </#if> 
153                    <#if event?? && event.phone?? && event.phone.data?has_content> 
154                        <div class="row"> 
155                            <div class="cell"><span>${languageUtil.get(locale, "phone-abbreviation")}: ${event.phone.data}</span></div> 
156                        </div> 
157                    </#if> 
158                </div> 
159            </div> 
160        </div> 
161    </#if> 
162 
163    <#-- ZAWARTOŚĆ ARTYKUŁU --> 
164    <#if abstract?? && abstract.data?has_content> 
165        <p class="description">${abstract.data}</p> 
166    <#else> 
167        <p class="description">${.vars["reserved-article-description"].data}</p> 
168    </#if> 
169 
170    <div class="content">${content.data}</div> 
171 
172    <#-- ZAŁĄCZNIKI --> 
173    <#assign hasAttachments = false /> 
174    <#if file?? && file.getSiblings()?size gt 0> 
175        <#list file.getSiblings() as fileItem> 
176            <#if fileItem.filedescription?? && fileItem.filedescription.data?has_content> 
177                <#assign fileItemName = fileItem.filedescription.data /> 
178            <#elseif fileItem.filetitle?? && fileItem.filetitle.data?has_content> 
179                <#assign fileItemName = fileItem.filetitle.data /> 
180            <#else> 
181                <#assign fileItemName = fileItem.data /> 
182            </#if> 
183            <#if fileItemName?? && fileItemName?has_content> 
184                <#assign hasAttachments = true /> 
185            </#if> 
186        </#list> 
187    </#if> 
188    <#if hasAttachments> 
189        <div class="attachments"> 
190            <h2>${languageUtil.get(locale, "resources-to-get")}</h2> 
191            <ul class="attachment-list"> 
192                <#list file.getSiblings() as fileItem> 
193                    <#if fileItem.filedescription?? && fileItem.filedescription.data?has_content> 
194                        <#assign fileItemName = fileItem.filedescription.data /> 
195                    <#elseif fileItem.filetitle?? && fileItem.filetitle.data?has_content> 
196                        <#assign fileItemName = fileItem.filetitle.data /> 
197                    <#else> 
198                        <#assign fileItemName = fileItem.data /> 
199                    </#if> 
200 
201                    <#if fileItemName?? && fileItemName?has_content> 
202                        <#assign url = fileItem.data /> 
203                        <#if url?contains("/documents/")> 
204                            <#assign urlParts = stringUtil.split(url, "?") /> 
205                            <#assign urlParts = stringUtil.split(urlParts[0]?string, "/") /> 
206                            <#assign groupId = getterUtil.getLong(urlParts[2]) /> 
207                            <#assign folderId = getterUtil.getLong(urlParts[3]) /> 
208                            <#assign title = httpUtil.decodeURL(urlParts[4]?string, true) /> 
209                            <#if urlParts?size gt 5> 
210                                <#assign uuid = urlParts[5]?string /> 
211                                <#assign file = dlFileEntryLocalService.getFileEntryByUuidAndGroupId(uuid, groupId) /> 
212                            <#else> 
213                                <#assign file = dlFileEntryLocalService.getFileEntry(groupId, folderId, title) /> 
214                            </#if> 
215                            <#assign fileIcon = file.icon + ".png" /> 
216                        </#if> 
217                        <#if !fileIcon?? || !fileIcon?has_content> 
218                            <#assign fileItemExt = fileItem.data /> 
219                            <#assign indexOfDot = fileItemExt?last_index_of(".") + 1 /> 
220                            <#assign indexOfSlash = fileItemExt?last_index_of("/") /> 
221                            <#if indexOfSlash gt indexOfDot> 
222                                <#assign fileItemExt = fileItemExt?substring(0, indexOfSlash) /> 
223                            </#if> 
224                            <#assign fileIcon = fileItemExt?substring(indexOfDot) + ".png" /> 
225                        </#if> 
226                        <#if fileItem.wcagdescription?? && fileItem.wcagdescription.data?has_content> 
227                            <#assign fileItemWCAGDesc = fileItem.wcagdescription.data /> 
228                        <#else> 
229                            <#assign fileItemWCAGDesc = "" /> 
230                        </#if> 
231                        <#if file?? > 
232                            <#assign 
233                            fExtension = file.extension 
234                            textFormatter = staticUtil["com.liferay.portal.kernel.util.TextFormatter"] 
235                            sizeFormatted = textFormatter.formatStorageSize(file.size, locale) 
236                            /> 
237                        </#if> 
238 
239                        <li> 
240                            <a href="${fileItem.data}" target="_blank" <#if fileItemWCAGDesc?? && fileItemWCAGDesc?has_content>title="${htmlUtil.escapeAttribute(fileItemWCAGDesc)}"</#if>><img src="${themeDisplay.pathThemeImages}/file_system/small/${fileIcon}"></a> 
241                            <a href="${fileItem.data}" target="_blank" <#if fileItemWCAGDesc?? && fileItemWCAGDesc?has_content>title="${htmlUtil.escapeAttribute(fileItemWCAGDesc)}"</#if>>${fileItemName} (${stringUtil.upperCase(fExtension)}, ${sizeFormatted})</a> 
242                        </li> 
243                    </#if> 
244                </#list> 
245            </ul> 
246        </div> 
247    </#if> 
248</div> 

Baza noclegowa RDLP w Szczecinku Baza noclegowa RDLP w Szczecinku