Provincia de Galicia detalle
296 Emaitza
Errorea gertatu da txantiloia prozesatzerakoan.
Java method "com.sun.proxy.$Proxy930.getFriendlyURLEntryLocalization(long, String)" threw an exception when invoked on com.sun.proxy.$Proxy930 object "com.liferay.friendly.url.service.impl.FriendlyURLEntryLocalServiceImpl@58636e07"; see cause exception in the Java stack trace.
----
FTL stack trace ("~" means nesting-related):
- Failed at: #assign friendlyURLEntryLocalization ... [in template "13333257#13333299#13752006" at line 31, column 41]
----
1<#assign classNameLocalService = serviceLocator.findService("com.liferay.portal.kernel.service.ClassNameLocalService")/>
2<#assign dlFileEntryLocalService = serviceLocator.findService("com.liferay.document.library.kernel.service.DLFileEntryLocalService")/>
3<#assign dlFileEntryTypeLocalService = serviceLocator.findService("com.liferay.document.library.kernel.service.DLFileEntryTypeLocalService")/>
4<#assign dlFileEntryMetadataLocalService = serviceLocator.findService("com.liferay.document.library.kernel.service.DLFileEntryMetadataLocalService")/>
5<#assign friendlyURLLocalService = serviceLocator.findService("com.liferay.friendly.url.service.FriendlyURLEntryLocalService")/>
6<#assign storageEngineManagerUtil = objectUtil("com.liferay.dynamic.data.mapping.kernel.StorageEngineManagerUtil")/>
7
8<#assign groupLocalService = serviceLocator.findService("com.liferay.portal.kernel.service.GroupLocalService")/>
9<#assign layout = themeDisplay.getLayout()>
10 <#if layout??>
11 <#if layout.isPrivateLayout()>
12 <#assign fiscalRepositoryGroup = groupLocalService.getGroup(companyId, "FISCAL_Zona_Privada")/>
13 <#else>
14 <#assign fiscalRepositoryGroup = groupLocalService.getGroup(companyId, "Guest")/>
15 </#if>
16 <#assign repositoryFriendlyUrl = fiscalRepositoryGroup.getFriendlyURL()/>
17 <#assign imgUrlBase = "/documents/d"+repositoryFriendlyUrl+"/"/>
18 </#if>
19
20<#assign documentUrlPrincipal = ""/>
21
22<#if entries?has_content>
23 <ul class="mj-results-list">
24 <#list entries as curEntry>
25 <li class="mj-box__information w-100">
26 <#assign dlFileEntry = dlFileEntryLocalService.getDLFileEntry(curEntry.classPK) />
27 <#assign classNameId = classNameLocalService.getClassNameId("com.liferay.portal.kernel.repository.model.FileEntry") />
28 <#-- <#assign friendlyURLEntry = friendlyURLLocalService.getMainFriendlyURLEntry(classNameId, curEntry.classPK) /> -->
29 <#assign friendlyURLEntry = friendlyURLLocalService.fetchMainFriendlyURLEntry(classNameId, curEntry.classPK)!"" />
30 <#if friendlyURLEntry?? && friendlyURLEntry!="" >
31 <#assign friendlyURLEntryLocalization = friendlyURLLocalService.getFriendlyURLEntryLocalization(friendlyURLEntry.getFriendlyURLEntryId(), themeDisplay.getLanguageId()) />
32 </#if>
33 <#if dlFileEntry.getSize() gt 0 && friendlyURLEntryLocalization?? >
34 <#assign documentUrlPrincipal = getDocumentUrl(repositoryFriendlyUrl, friendlyURLEntryLocalization.getUrlTitle(), false)/>
35 <#else>
36 <#assign documentUrlPrincipal = ""/>
37 </#if>
38
39 <#assign descripcion = dlFileEntry.getDescription() />
40 <#assign fileEntryType = dlFileEntryTypeLocalService.getFileEntryType(dlFileEntry.getFileEntryTypeId()) />
41 <#assign fileEntryMetadata = dlFileEntryMetadataLocalService.getFileEntryMetadata(fileEntryType.getDataDefinitionId(), dlFileEntry.getLatestFileVersion(true).getFileVersionId()) />
42 <#assign ddmFormValues = storageEngineManagerUtil.getDDMFormValues(fileEntryMetadata.getDDMStorageId()) />
43 <#assign ddmFormFieldValues = ddmFormValues.getDDMFormFieldValues()/>
44
45 <#-- start -->
46 <#list ddmFormFieldValues as field>
47 <#assign reference = field.getFieldReference() />
48 <#if reference=="titulo" >
49 <#assign documentTitulo = (field.getValue().getString(locale)?has_content)?then(field.getValue().getString(locale),dlFileEntry.fileName) />
50 <#elseif reference=="tituloUrl" >
51 <#assign documentTituloUrl = field.getValue().getString(locale)/>
52 <#elseif reference=="url" >
53 <#assign documentUrl = field.getValue().getString(locale)/>
54 <#elseif reference=="fecha">
55 <#assign documentFecha = field.getValue().getString(locale)/>
56 <#elseif reference=="ca_document" >
57 <#assign documentJsonRaw = field.getValue().getString(locale)!"{}" />
58 <#if documentJsonRaw?? && documentJsonRaw!="{}">
59 <#assign documentJson = documentJsonRaw?eval/>
60 <#assign classPKJson = documentJson.classPK!""/>
61 <#assign documentUrlCA = getDocumentUrl(repositoryFriendlyUrl, getUrlTitle(classPKJson,themeDisplay.getLanguageId()), false)/>
62 <#else>
63 <#assign documentUrlCA = "">
64 </#if>
65 <#elseif reference=="gl_document" >
66 <#assign documentJsonRaw = field.getValue().getString(locale) />
67 <#if documentJsonRaw?? && documentJsonRaw!="{}">
68 <#assign documentJson = documentJsonRaw?eval/>
69 <#assign classPKJson = documentJson.classPK!""/>
70 <#assign documentUrlGL = getDocumentUrl(repositoryFriendlyUrl, getUrlTitle(classPKJson,themeDisplay.getLanguageId()), false)/>
71 <#else>
72 <#assign documentUrlGL = "">
73 </#if>
74 <#elseif reference=="va_document" >
75 <#assign documentJsonRaw = field.getValue().getString(locale) />
76 <#if documentJsonRaw?? && documentJsonRaw!="{}">
77 <#assign documentJson = documentJsonRaw?eval/>
78 <#assign classPKJson = documentJson.classPK!""/>
79 <#assign documentUrlVA = getDocumentUrl(repositoryFriendlyUrl, getUrlTitle(classPKJson,themeDisplay.getLanguageId()), false)/>
80 <#else>
81 <#assign documentUrlVA = "">
82 </#if>
83 <#elseif reference=="eu_document" >
84 <#assign documentJsonRaw = field.getValue().getString(locale) />
85 <#if documentJsonRaw?? && documentJsonRaw!="{}">
86 <#assign documentJson = documentJsonRaw?eval/>
87 <#assign classPKJson = documentJson.classPK!""/>
88 <#assign documentUrlEU = getDocumentUrl(repositoryFriendlyUrl, getUrlTitle(classPKJson,themeDisplay.getLanguageId()), false)/>
89 <#else>
90 <#assign documentUrlEU = "">
91 </#if>
92 <#elseif reference=="en_document" >
93 <#assign documentJsonRaw = field.getValue().getString(locale) />
94 <#if documentJsonRaw?? && documentJsonRaw!="{}">
95 <#assign documentJson = documentJsonRaw?eval/>
96 <#assign classPKJson = documentJson.classPK!""/>
97 <#assign documentUrlEN = getDocumentUrl(repositoryFriendlyUrl, getUrlTitle(classPKJson,themeDisplay.getLanguageId()), false)/>
98 <#else>
99 <#assign documentUrlEN = "">
100 </#if>
101 </#if>
102
103 </#list>
104
105 <#-- html -->
106 <div class="mj-box__information--top-wrapper">
107 <#if documentTitulo?? && documentTitulo!="">
108 <p class="mj-box__information--title bold">
109 <#if documentUrlPrincipal?? && documentUrlPrincipal!="">
110 <a href="${documentUrlPrincipal}?download=false" target="_blank" title="<@liferay.language key='opens-new-window'/>">${htmlUtil.escape(documentTitulo)}
111 </a>
112 <#else>
113 ${htmlUtil.escape(documentTitulo)}
114 </#if>
115 </p>
116 </#if>
117 <#if documentTituloUrl?? && documentTituloUrl!="">
118 <a class="mj-link mb-10 d-inline-block" href="${htmlUtil.escape(documentUrl)}" target="_blank" aria-label="${languageUtil.format(locale, 'x-opens-new-window', htmlUtil.escape(documentTituloUrl), false)}">
119 ${htmlUtil.escape(documentTituloUrl)}
120 </a>
121 </#if>
122 <#if descripcion?? && descripcion!="">
123 <p class="mj-box__information--text">
124 ${htmlUtil.escape(descripcion)}
125 </p>
126 </#if>
127 </div>
128 <div class="mj-box__information--bottom-wrapper">
129 <div>
130 <#if documentUrlPrincipal?? && documentUrlPrincipal!="">
131 <a href="${documentUrlPrincipal}" class="mj-link-download mr-2" download aria-label="${languageUtil.format(locale, 'download-x', htmlUtil.escape(documentTitulo), false)}" title="<@liferay.language key='download' /> ${htmlUtil.escape(documentTitulo)}"><@liferay.language key="download" /></a>
132 </#if>
133 <#if documentUrlCA?? && documentUrlCA!="">
134 <@printDownloadFlag documentUrlCA "ca_es" />
135 </#if>
136 <#if documentUrlGL?? && documentUrlGL!="">
137 <@printDownloadFlag documentUrlGL "gl_es" />
138 </#if>
139 <#if documentUrlVA?? && documentUrlVA!="">
140 <@printDownloadFlag documentUrlVA "va_es" />
141 </#if>
142 <#if documentUrlEU?? && documentUrlEU!="">
143 <@printDownloadFlag documentUrlEU "eu_es" />
144 </#if>
145 <#if documentUrlEN?? && documentUrlEN!="">
146 <@printDownloadFlag documentUrlEN "en_gb" />
147 </#if>
148 </div>
149 <#if documentFecha?? && documentFecha!="">
150 <#assign documentFecha_DateObj = dateUtil.parseDate("yyyy-MM-dd", documentFecha, locale)>
151 <#assign documentFechaFormat = dateUtil.getDate(documentFecha_DateObj, "dd/MM/yyyy", locale)/>
152 <time class="mj-datetime" datetime="${documentFecha_DateObj?date?iso_utc}">${documentFechaFormat}</time>
153 </#if>
154 </div>
155 </li>
156 </#list>
157 </ul>
158</#if>
159
160<#function getUrlTitle classPK languageId>
161 <#assign urlTitle = "" />
162 <#if classPK?? && classPK?string!="">
163 <#assign dlFileEntry = dlFileEntryLocalService.getDLFileEntry(classPK) />
164 <#assign classNameId = classNameLocalService.getClassNameId("com.liferay.portal.kernel.repository.model.FileEntry") />
165 <#assign friendlyURLEntry = friendlyURLLocalService.fetchMainFriendlyURLEntry(classNameId, classPK)!"" />
166 <#if friendlyURLEntry?? && friendlyURLEntry!="" >
167 <#assign friendlyURLEntryLocalization = friendlyURLLocalService.getFriendlyURLEntryLocalization(friendlyURLEntry.getFriendlyURLEntryId(), languageId) />
168 <#if dlFileEntry.getSize() gt 0 && friendlyURLEntryLocalization?? >
169 <#assign urlTitle = friendlyURLEntryLocalization.getUrlTitle() />
170 </#if>
171 </#if>
172 </#if>
173 <#return urlTitle>
174</#function>
175
176<#function getDocumentUrl repositoryUrl urlTitle isDownload>
177 <#if repositoryUrl?? && repositoryUrl!="" && urlTitle?? && urlTitle!="" >
178 <#if isDownload?? && isDownload==true >
179 <#return "/documents/d"+repositoryUrl+"/"+urlTitle+"?download=true">
180 <#else>
181 <#return "/documents/d"+repositoryUrl+"/"+urlTitle >
182 </#if>
183 <#else>
184 <#return "">
185 </#if>
186</#function>
187
188<#macro printDownloadFlag documentUrl localeFlag>
189 <#if localeFlag == 'ca_es'>
190 <#assign language = 'catalán' />
191 <#elseif localeFlag == 'gl_es'>
192 <#assign language = 'gallego' />
193 <#elseif localeFlag == 'va_es'>
194 <#assign language = 'valenciano' />
195 <#elseif localeFlag == 'eu_es'>
196 <#assign language = 'euskera' />
197 <#elseif localeFlag == 'en_gb'>
198 <#assign language = 'inglés' />
199 </#if>
200
201 <a href="${documentUrl}" class="mr-1" download target="_blank" title="<@liferay.language key='download' /> ${htmlUtil.escape(documentTitulo)} > ${language}">
202 <img src="${imgUrlBase}${localeFlag}" />
203 </a>
204</#macro>
We use cookies to deliver personalized content, analyze trends, administer the site, track user movements on the site, and collect demographic information about our user base as a whole. Accept all cookies for the best possible experience on our website or manage your preferences. Visit our Privacy Policy
