-
Certificaciones
-
Cultura
-
Sobre la institución
Resultados de búsqueda
/o/ic-theme-spritemap/spritemap.6405efe3615b5f3f5004b415c7bacee5ce525505.svg
An error occurred while processing the template.
Error while invoking the "tarjetas-pictograma" JSP custom tag; see cause exception
----
FTL stack trace ("~" means nesting-related):
- Failed at: @ricoh_dinamycTemplate["tarjetas-pict... [in template "69728804861567#20120#386255" at line 711, column 11]
----
1<p class="search-total-label-tag invisible mb-space-0">
2 ${searchContainer.getTotal()}
3</p>
4<#assign _entries = entries![]>
5 <#assign debugImageParameter = paramUtil.getString(request, "debugImage")?lower_case />
6 <#assign debugImage = debugImageParameter == "1" || debugImageParameter == "true" />
7 <#if debugImage>
8 <!-- image-debug enabled -->
9 </#if>
10 <div class="search-result-taglib">
11<#if _entries?size == 0>
12 <div id="no-results-message" class="container-fluid container-fluid-max-xl px-space-16 px-lg-space-0 pb-space-64 pb-space-80">
13 <p class="t-encabezado-m mb-space-24 text-rojo-cervantes">
14 Vaya, parece que no hay resultados
15 </p>
16 <p class="t-text-l text-azul-acero">
17 No hemos encontrado ningún resultado con estas características. Por favor, prueba a escoger otras opciones de filtro.
18 </p>
19 </div>
20<#else>
21
22 <#assign jal = serviceLocator.findService("com.liferay.journal.service.JournalArticleLocalService")! />
23 <#assign sax = (saxReaderUtil??)?then(saxReaderUtil, serviceLocator.findService("com.liferay.portal.kernel.xml.SAXReader")!) />
24 <#assign aes = serviceLocator.findService("com.liferay.asset.kernel.service.AssetEntryLocalService")! />
25 <#assign gls = serviceLocator.findService("com.liferay.portal.kernel.service.GroupLocalService")! />
26 <#assign dlas = serviceLocator.findService("com.liferay.document.library.kernel.service.DLAppService")! />
27 <#assign lang = locale?string />
28 <#assign spr = (siteSpritemap!'')?has_content?then(siteSpritemap, "/o/ic-theme-spritemap/spritemap.svg") />
29
30 <#assign assetVocabularyLocalService = serviceLocator.findService("com.liferay.asset.kernel.service.AssetVocabularyLocalService") />
31 <#assign globalGroupId = themeDisplay.getCompany().getGroupId() />
32 <#assign vocabularies = assetVocabularyLocalService.getGroupVocabularies(globalGroupId) />
33
34 <#function field xml ref>
35 <#local v = "" />
36 <#if sax?? && xml?has_content>
37 <#local doc = sax.read(xml) />
38 <#local n = doc.selectSingleNode("/root/dynamic-element[@field-reference='${ref}']/dynamic-content[@language-id='${lang}']")! />
39 <#if !n?has_content><#local n = doc.selectSingleNode("/root/dynamic-element[@field-reference='${ref}']/dynamic-content[1]")! /></#if>
40 <#if !n?has_content><#local n = doc.selectSingleNode("/root/dynamic-element[@name='${ref}']/dynamic-content[@language-id='${lang}']")! /></#if>
41 <#if !n?has_content><#local n = doc.selectSingleNode("/root/dynamic-element[@name='${ref}']/dynamic-content[1]")! /></#if>
42 <#if n?has_content><#local v = n.getText()!"" /></#if>
43 </#if>
44 <#return v>
45 </#function>
46
47 <#-- Atributo dynamic-content -->
48 <#function fieldAttr xml ref attr>
49 <#local v = "" />
50 <#if sax?? && xml?has_content>
51 <#local doc = sax.read(xml) />
52 <#local n = doc.selectSingleNode("/root/dynamic-element[@field-reference='${ref}']/dynamic-content[@language-id='${lang}']")! />
53 <#if !n?has_content><#local n = doc.selectSingleNode("/root/dynamic-element[@field-reference='${ref}']/dynamic-content[1]")! /></#if>
54 <#if !n?has_content><#local n = doc.selectSingleNode("/root/dynamic-element[@name='${ref}']/dynamic-content[@language-id='${lang}']")! /></#if>
55 <#if !n?has_content><#local n = doc.selectSingleNode("/root/dynamic-element[@name='${ref}']/dynamic-content[1]")! /></#if>
56 <#if n?has_content><#local v = n.valueOf('@' + attr)!"" /></#if>
57 </#if>
58 <#return v>
59 </#function>
60
61 <#function jsonGet s key>
62 <#if s?has_content && s?starts_with("{")>
63 <#-- (?s) = dotall ; captura primera coincidencia "key":"value" -->
64 <#local rx = '(?s).*"' + key + '"\\s*:\\s*"(.*?)".*' />
65 <#local v = s?replace(rx, '$1', 'r') />
66 <#if v != s><#return v /></#if>
67 </#if>
68 <#return "" />
69 </#function>
70
71 <#-- Si es JSON, devuelve su "url", si no devuelve s -->
72 <#function mediaUrl s>
73 <#if !s?has_content>
74 <#return "" />
75 </#if>
76 <#local sTrim = s?trim />
77 <#if sTrim?starts_with("{")>
78 <#local u = jsonGet(sTrim, "url") />
79 <#return (u?has_content)?then(u, "") />
80 </#if>
81 <#return sTrim />
82 </#function>
83
84 <#function resolveFileEntryUrl fileEntryId fallbackUrl>
85 <#if !fileEntryId?has_content || !dlas??>
86 <#return fallbackUrl />
87 </#if>
88 <#attempt>
89 <#assign fileEntry = dlas.getFileEntry(fileEntryId?number)! />
90 <#if fileEntry??>
91 <#return themeDisplay.getPortalURL() + themeDisplay.getPathContext()
92 + "/documents/" + fileEntry.getGroupId() + "/" + fileEntry.getFolderId()
93 + "/" + fileEntry.getFileName() + "/" + fileEntry.getUuid()
94 + "?t=" + fileEntry.getModifiedDate()?long />
95 </#if>
96 <#recover>
97 </#attempt>
98 <#return fallbackUrl />
99 </#function>
100
101 <#-- Añade una etiqueta evitando duplicados (sin distinguir mayúsculas/minúsculas) -->
102 <#function addUnique values value>
103 <#local cleanValue = (value!"")?trim />
104 <#if !cleanValue?has_content>
105 <#return values />
106 </#if>
107 <#list values as existing>
108 <#if (existing!"")?trim?lower_case == cleanValue?lower_case>
109 <#return values />
110 </#if>
111 </#list>
112 <#return values + [cleanValue] />
113 </#function>
114
115 <#-- Booleanos de estructura que pueden venir como true/si/sí/1/yes -->
116 <#function isTruthy value>
117 <#local v = (value!"")?trim?lower_case />
118 <#return v == "true" || v == "si" || v == "sí" || v == "1" || v == "yes" />
119 </#function>
120
121 <#-- Tipo funcional del contenido -->
122 <#function getContentTypeLabel structureKey>
123 <#local key = (structureKey!"")?upper_case />
124
125 <#if key?contains("HISPANISTAS_ASOCIACIONES")>
126 <#return "Asociación" />
127 <#elseif key?contains("HISPANISTAS_DEPARTAMENTOS")>
128 <#return "Departamentos" />
129 <#elseif key?contains("HISPANISTAS_EMPLEO_Y_BECAS")>
130 <#return "Empleo y Becas" />
131 <#elseif key?contains("HISPANISTAS_NOTICIAS")>
132 <#return "Noticia" />
133 <#elseif key?contains("HISPANISTAS_PROYECTO_INVESTIGACION")>
134 <#return "Proyecto" />
135 <#elseif key?contains("HISPANISTAS_TRIBUNAS")>
136 <#return "Tribuna" />
137 <#elseif key?contains("HISPANISTAS")>
138 <#return "Hispanista" />
139 <#elseif key?contains("PUBLICACIONES")>
140 <#return "Publicación" />
141 <#elseif key?contains("NOTICIAS")>
142 <#return "Noticia" />
143 <#elseif key?contains("EXAMEN")>
144 <#return "Examen" />
145 <#elseif key?contains("CURSO")>
146 <#return "Curso" />
147 <#elseif key?contains("73205") || key?contains("ACTIV")>
148 <#return "Actividad" />
149 <#elseif key?contains("PROGRAMA")>
150 <#return "Programa" />
151 </#if>
152
153 <#return "" />
154 </#function>
155
156<div id="search-results-tablib" class="row row-gap-space-32">
157 <#list _entries as e>
158 <#assign className = (e.getClassName()!e.getEntryClassName()!"") />
159 <#assign classPK = (e.getClassPK()!e.getEntryClassPK()!0)?number />
160 <#if className == "" || classPK == 0><#continue></#if>
161
162 <#assign isPage = className == "com.liferay.portal.kernel.model.Layout" />
163
164 <#assign isJournalArticle = className == "com.liferay.journal.model.JournalArticle" />
165 <#assign hasJournalArticle = false />
166 <#if isJournalArticle && jal??>
167 <#assign ja = jal.fetchLatestArticle(classPK)! />
168 <#if ja?has_content>
169 <#assign hasJournalArticle = true />
170 </#if>
171 </#if>
172 <#if isJournalArticle && !hasJournalArticle><#continue></#if>
173
174 <#assign t = (e.getTitle()!e.getHighlightedTitle()!"") />
175 <#assign structureKey = "" />
176 <#assign xml = "" />
177 <#assign href = (e.getViewURL()!"") />
178 <#assign imageUrl = (e.getThumbnailURLString()!"") />
179 <#assign originalImageUrl = imageUrl />
180 <#assign imageAlt = t />
181 <#assign imageFileEntryId = "" />
182 <#assign authorName = "" />
183 <#assign erc = "" />
184
185 <#if hasJournalArticle>
186
187 <#assign isPrivate = themeDisplay.getLayout().isPrivateLayout() />
188 <#if isPrivate>
189 <#assign friendlyPath = themeDisplay.getPathFriendlyURLPrivateGroup() />
190 <#else>
191 <#assign friendlyPath = themeDisplay.getPathFriendlyURLPublic() />
192 </#if>
193
194 <#--
195 Traza funcional: resolver el site real del contenido para evitar enlaces
196 rotos cuando el resultado pertenece a un grupo distinto al scope actual.
197 -->
198 <#assign detailGroupFriendlyURL = themeDisplay.getScopeGroup().getFriendlyURL() />
199 <#if gls??>
200 <#assign detailGroup = gls.fetchGroup(ja.getGroupId())! />
201
202 <#-- Traza funcional: si es staging, usar live para friendly URL pública -->
203 <#if detailGroup?? && detailGroup.isStagingGroup()>
204 <#assign liveGroup = gls.fetchGroup(detailGroup.getLiveGroupId())! />
205 <#if liveGroup??>
206 <#assign detailGroup = liveGroup />
207 </#if>
208 </#if>
209
210 <#if detailGroup?? && detailGroup.getFriendlyURL()?has_content>
211 <#assign detailGroupFriendlyURL = detailGroup.getFriendlyURL() />
212 </#if>
213 </#if>
214
215 <#assign groupPath = themeDisplay.getPortalURL() + friendlyPath + detailGroupFriendlyURL />
216
217 <#-- URL de detalle, requiere tener Display Page -->
218 <#assign articleURL = groupPath + "/w/" + ja.getUrlTitle(locale) />
219 <#assign href = articleURL />
220 <#assign xml = ja.getDocument().asXML() />
221 <#assign structureKey = ja.getDDMStructureKey()!"" />
222 <#assign sk = structureKey?upper_case />
223 <#else>
224 <#assign contentTypeLabel = (e.getModelResource()!"") />
225 <#assign sk = "" />
226 </#if>
227
228 <#--
229 Traza funcional: para cualquier estructura no contemplada en ramas específicas,
230 el enlace por defecto debe apuntar al detalle del contenido.
231 -->
232 <#-- Tipo funcional -->
233 <#if hasJournalArticle>
234 <#assign contentTypeLabel = getContentTypeLabel(sk) />
235 <#else>
236 <#assign contentTypeLabel = (e.getModelResource()!"") />
237 </#if>
238 <#if isPage>
239 <#assign contentTypeLabel = "" />
240 </#if>
241
242 <#-- Categorías para LISTADO: se conservan todas las significativas,
243 transformando los Si/No especiales igual que en las aperturas. -->
244 <#assign cats = "" />
245 <#assign names = [] />
246 <#assign excludedVocabularyIds = [] />
247
248 <#if aes??>
249 <#assign ae = aes.getEntry(className, classPK)! />
250 <#if ae??>
251 <#attempt>
252
253 <#-- Vocabularios especiales -->
254 <#list vocabularies as vocab>
255 <#assign vocabName = (vocab.getName()!"") />
256
257 <#-- Hispanistas: el vocabulario de tipo ya está representado por contentTypeLabel -->
258 <#if sk?contains("HISPANISTAS_ASOCIACIONES") && vocabName == "hispanistas_tipo_asociacion">
259 <#assign excludedVocabularyIds = excludedVocabularyIds + [vocab.getVocabularyId()] />
260 <#elseif sk?contains("HISPANISTAS_DEPARTAMENTOS") && vocabName == "hispanistas_tipo_departamento">
261 <#assign excludedVocabularyIds = excludedVocabularyIds + [vocab.getVocabularyId()] />
262 <#elseif sk?contains("HISPANISTAS_EMPLEO_Y_BECAS") && vocabName == "hispanistas_tipo_convocatoria">
263 <#assign excludedVocabularyIds = excludedVocabularyIds + [vocab.getVocabularyId()] />
264 </#if>
265
266 <#-- Actividades culturales: booleanos con etiqueta humana -->
267 <#if vocabName == "pl_actividadc_hispanoamerica"
268 || vocabName == "pl_actividadc_ioj"
269 || vocabName == "pl_actividadc_subtitulado"
270 || vocabName == "pl_actividadc_coordinasede"
271 || vocabName == "pl_actividadc_actividadcompartida"
272 || vocabName == "pl_requisitostecnicos">
273
274 <#list ae.getCategories() as c>
275 <#if c.getVocabularyId() == vocab.getVocabularyId()
276 && (c.getName()!"")?trim?lower_case == "si">
277
278 <#assign label = "" />
279
280 <#if vocabName == "pl_actividadc_hispanoamerica">
281 <#assign label = "Hispano américa" />
282 <#elseif vocabName == "pl_actividadc_ioj">
283 <#assign label = "Infantil o juvenil" />
284 <#elseif vocabName == "pl_actividadc_subtitulado">
285 <#assign label = "Subtitulado" />
286 <#elseif vocabName == "pl_actividadc_coordinasede">
287 <#assign label = "Coordinado por sede" />
288 <#elseif vocabName == "pl_actividadc_actividadcompartida">
289 <#assign label = "Actividad compartida" />
290 <#elseif vocabName == "pl_requisitostecnicos">
291 <#assign label = "Requisitos técnicos" />
292 </#if>
293
294 <#assign names = addUnique(names, label) />
295 </#if>
296 </#list>
297 </#if>
298
299 <#-- Exámenes: Centro acreditado / Centro accesible -->
300 <#if vocabName == "pl_examen_centroAcreditado"
301 || vocabName == "pl_examen_centroAccesible">
302
303 <#list ae.getCategories() as c>
304 <#if c.getVocabularyId() == vocab.getVocabularyId()
305 && (c.getName()!"")?trim?lower_case == "si">
306
307 <#if vocabName == "pl_examen_centroAcreditado">
308 <#assign names = addUnique(names, "Centro acreditado") />
309 <#else>
310 <#assign names = addUnique(names, "Centro accesible") />
311 </#if>
312 </#if>
313 </#list>
314 </#if>
315 </#list>
316
317 <#-- Resto de categorías normales -->
318 <#list ae.getCategories() as c>
319 <#assign categoryName = (c.getName()!"")?trim />
320 <#assign categoryNameLower = categoryName?lower_case />
321 <#assign categoryTitle = (c.getTitle(locale)!categoryName)?trim />
322 <#assign excludedVocabulary = excludedVocabularyIds?seq_contains(c.getVocabularyId()) />
323
324 <#if !excludedVocabulary
325 && categoryNameLower != "si"
326 && categoryNameLower != "sí"
327 && categoryNameLower != "no">
328 <#assign names = addUnique(names, categoryTitle) />
329 </#if>
330 </#list>
331
332 <#recover>
333 <#assign names = [] />
334 </#attempt>
335 </#if>
336 </#if>
337
338 <#-- Fallbacks/peculiaridades que en las aperturas no siempre son categorías reales -->
339 <#if sk?contains("EXAMEN")>
340 <#if isTruthy(field(xml, "E_centroAcreditado"))>
341 <#assign names = addUnique(names, "Centro acreditado") />
342 </#if>
343 <#if isTruthy(field(xml, "E_centroAccesible"))>
344 <#assign names = addUnique(names, "Centro accesible") />
345 </#if>
346 </#if>
347
348 <#if sk?contains("NOTICIAS") && !sk?contains("HISPANISTAS")>
349 <#assign noticiaTipo = field(xml, "NoticiaTipo")?trim />
350 <#if noticiaTipo?has_content>
351 <#if noticiaTipo?lower_case == "notas prensa">
352 <#assign noticiaTipo = "notas de prensa" />
353 </#if>
354 <#assign names = addUnique(names, noticiaTipo) />
355 </#if>
356 </#if>
357
358 <#if sk?contains("PUBLICACIONES")>
359 <#assign publicacionTipologia = field(xml, "publicacionTipologia")?trim />
360 <#if publicacionTipologia?has_content>
361 <#assign names = addUnique(names, publicacionTipologia) />
362 </#if>
363 </#if>
364
365 <#assign cats = names?join("|") />
366
367 <#-- Valores para invocar taglib -->
368 <#assign precio="" tipo="" modalidad="" lugar="" iconUrl="" fechaInicio="" />
369 <#assign renderer = "calendarizada" />
370
371 <#-- ACTIVIDADES -->
372 <#if sk == "STR_ACTIVIDADES">
373 <#assign renderer = "calendarizada" />
374 <#assign t = field(xml,"A_titulo_largo") />
375 <#assign precio = field(xml,"A_precio") />
376 <#assign tipo = field(xml,"A_tipo") />
377 <#assign modalidad = field(xml,"A_modalidad") />
378 <#assign lugar = field(xml,"A_lugar") />
379
380 <#-- ICON -->
381 <#assign iconRaw = field(xml,"icon") />
382 <#assign iconUrl = mediaUrl(iconRaw) />
383
384 <#-- IMAGEN -->
385 <#assign imgRaw = field(xml,"A_imagen") />
386 <#assign imageUrl = mediaUrl(imgRaw) />
387 <#assign imageAlt = (fieldAttr(xml,"A_imagen","alt"))!"" />
388 <#if !imageAlt?has_content><#assign imageAlt = jsonGet(imgRaw,"alt") /></#if>
389 <#assign imageFileEntryId = (fieldAttr(xml,"A_imagen","fileEntryId"))!"" />
390 <#if !imageFileEntryId?has_content><#assign imageFileEntryId = jsonGet(imgRaw,"fileEntryId") /></#if>
391
392 <#assign fechaInicio = field(xml,"A_fecha_inicio") />
393 <#assign href = articleURL />
394
395 <#-- ACTIVIDADES CULTURALES -->
396 <#elseif sk == "STR_ACTIVIDADESCULTURALES">
397 <#assign renderer = "calendarizada" />
398
399 <#-- IMAGEN -->
400 <#assign imgRaw = field(xml,"AC_Imagen") />
401 <#assign imageUrl = mediaUrl(imgRaw) />
402 <#assign imageAlt = (fieldAttr(xml,"AC_Imagen","alt"))!"" />
403 <#if !imageAlt?has_content>
404 <#assign imageAlt = jsonGet(imgRaw,"alt") />
405 </#if>
406 <#assign imageFileEntryId = (fieldAttr(xml,"AC_Imagen","fileEntryId"))!"" />
407 <#if !imageFileEntryId?has_content>
408 <#assign imageFileEntryId = jsonGet(imgRaw,"fileEntryId") />
409 </#if>
410
411 <#assign href = articleURL />
412
413 <#-- CURSOS -->
414 <#elseif sk?contains("CURSO")>
415 <#assign renderer = "calendarizada" />
416 <#assign t = field(xml,"C_titulo_largo") />
417 <#assign precio = field(xml,"C_precio") />
418 <#assign tipo = field(xml,"C_tipo") />
419 <#assign modalidad = field(xml,"C_modalidad") />
420 <#assign lugar = field(xml,"C_lugar") />
421 <#assign iconUrl = "" />
422 <#assign fechaInicio = field(xml,"C_fecha_inicio") />
423 <#assign href = articleURL />
424
425 <#-- EXÁMENES -->
426 <#elseif sk?contains("EXAMEN")>
427 <#assign renderer = "calendarizada" />
428 <#assign t = field(xml,"E_examen") />
429 <#assign tipo = field(xml,"E_convocatoria") />
430 <#assign modalidad = "Presencial" />
431 <#assign lugar = field(xml,"E_lugarPruebasEscritas") />
432 <#if !lugar?has_content><#assign lugar = field(xml,"E_lugarPruebasOrales") /></#if>
433 <#if !lugar?has_content><#assign lugar = field(xml,"E_direccionCentro") /></#if>
434 <#if !lugar?has_content><#assign lugar = field(xml,"E_nombreCentro") /></#if>
435 <#assign fechaInicio = field(xml,"E_fechaPruebasReferencia") />
436 <#assign href = articleURL />
437 <#assign disponibilidad = field(xml,"E_disponibilidadPlazas")?lower_case />
438 <#assign precioNum = field(xml,"E_precio") />
439 <#if disponibilidad == "completo">
440 <#assign precio = "full" />
441 <#elseif (precioNum?has_content) && (precioNum == "0" || precioNum?lower_case == "gratis" || precioNum?lower_case == "free")>
442 <#assign precio = "free" />
443 <#else>
444 <#assign precio = "open" />
445 </#if>
446 <#elseif sk?contains("NOTICIAS")>
447 <#assign renderer = "basica-vertical" />
448
449 <#assign t = field(xml, "NoticiaTitulo") />
450 <#if !t?has_content>
451 <#assign t = ja.getTitle(locale)!"" />
452 </#if>
453
454 <#assign imgRaw = field(xml, "NoticiaImage") />
455 <#assign imageUrl = mediaUrl(imgRaw) />
456
457 <#assign imageAlt = (fieldAttr(xml, "NoticiaImage", "alt"))!"" />
458 <#if !imageAlt?has_content>
459 <#assign imageAlt = jsonGet(imgRaw, "alt") />
460 </#if>
461
462 <#assign imageFileEntryId = (fieldAttr(xml, "NoticiaImage", "fileEntryId"))!"" />
463 <#if !imageFileEntryId?has_content>
464 <#assign imageFileEntryId = jsonGet(imgRaw, "fileEntryId") />
465 </#if>
466
467 <#assign href = articleURL />
468
469 <#assign authorName = "" />
470 <#if hasJournalArticle>
471 <#assign userLocalService = serviceLocator.findService("com.liferay.portal.kernel.service.UserLocalService") />
472 <#assign author = userLocalService.fetchUser(ja.getUserId())! />
473 <#if author??>
474 <#assign authorName = author.getFullName() />
475 </#if>
476 </#if>
477
478 <#assign erc = (ja.getExternalReferenceCode())!"" />
479 <#assign structureKey = ja.getDDMStructureKey() />
480
481
482 <#elseif sk?contains("PUBLICACIONES")>
483 <#assign renderer = "tarjetas-pictograma" />
484 <#assign t = field(xml,"publicacionTitle") />
485
486 <#-- Si no encuentra por field-reference, intenta por nombre de campo -->
487 <#if !t?has_content>
488 <#assign t = field(xml,"Titulo") />
489 </#if>
490
491 <#-- IMAGEN de publicación -->
492 <#assign imgRaw = field(xml,"publicacionImagen") />
493 <#if !imgRaw?has_content>
494 <#assign imgRaw = field(xml,"Imagen") />
495 </#if>
496
497 <#assign imageUrl = mediaUrl(imgRaw) />
498 <#assign imageAlt = (fieldAttr(xml,"publicacionImagen","alt"))!"" />
499 <#if !imageAlt?has_content>
500 <#assign imageAlt = (fieldAttr(xml,"Imagen","alt"))!"" />
501 </#if>
502 <#if !imageAlt?has_content>
503 <#assign imageAlt = jsonGet(imgRaw,"alt") />
504 </#if>
505
506 <#assign imageFileEntryId = (fieldAttr(xml,"publicacionImagen","fileEntryId"))!"" />
507 <#if !imageFileEntryId?has_content>
508 <#assign imageFileEntryId = (fieldAttr(xml,"Imagen","fileEntryId"))!"" />
509 </#if>
510 <#if !imageFileEntryId?has_content>
511 <#assign imageFileEntryId = jsonGet(imgRaw,"fileEntryId") />
512 </#if>
513
514 <#-- Autor -->
515 <#assign authorName = "" />
516 <#if hasJournalArticle>
517 <#assign userLocalService = serviceLocator.findService("com.liferay.portal.kernel.service.UserLocalService") />
518 <#assign author = userLocalService.fetchUser(ja.getUserId())! />
519 <#if author??>
520 <#assign authorName = author.getFullName() />
521 </#if>
522 </#if>
523
524 <#-- External Reference Code -->
525 <#assign erc = (ja.getExternalReferenceCode())!"" />
526
527 <#-- Structure Key -->
528 <#assign structureKey = ja.getDDMStructureKey() />
529
530 <#-- Limpiar campos vacíos que no aplican a publicaciones -->
531 <#assign precio = "" />
532 <#assign tipo = "" />
533 <#assign modalidad = "" />
534 <#assign lugar = "" />
535 <#assign iconUrl = "" />
536 <#assign fechaInicio = "" />
537
538 <#assign href = articleURL />
539 <#-- PROGRAMAS -->
540 <#elseif sk?contains("PROGRAMA")>
541 <#assign renderer = "tarjetas-pictograma" />
542
543 <#-- Título desde MP_apertura.MP_apertura_titulo -->
544 <#assign t = field(xml,"MP_apertura_titulo") />
545 <#if !t?has_content>
546 <#assign t = field(xml,"apertura_titulo") />
547 </#if>
548
549 <#-- IMAGEN desde MP_apertura.MP_apertura_imagen_fondo -->
550 <#assign imgRaw = field(xml,"MP_apertura_imagen_fondo") />
551 <#if !imgRaw?has_content>
552 <#assign imgRaw = field(xml,"apertura_imagen_fondo") />
553 </#if>
554
555 <#assign imageUrl = mediaUrl(imgRaw) />
556 <#assign imageAlt = (fieldAttr(xml,"MP_apertura_imagen_fondo","alt"))!"" />
557 <#if !imageAlt?has_content>
558 <#assign imageAlt = (fieldAttr(xml,"apertura_imagen_fondo","alt"))!"" />
559 </#if>
560 <#if !imageAlt?has_content>
561 <#assign imageAlt = jsonGet(imgRaw,"alt") />
562 </#if>
563
564 <#assign imageFileEntryId = (fieldAttr(xml,"MP_apertura_imagen_fondo","fileEntryId"))!"" />
565 <#if !imageFileEntryId?has_content>
566 <#assign imageFileEntryId = (fieldAttr(xml,"apertura_imagen_fondo","fileEntryId"))!"" />
567 </#if>
568 <#if !imageFileEntryId?has_content>
569 <#assign imageFileEntryId = jsonGet(imgRaw,"fileEntryId") />
570 </#if>
571
572 <#-- iFrame Video desde MP_apertura.MP_apertura_iframe_video -->
573 <#assign iframeVideo = field(xml,"MP_apertura_iframe_video") />
574 <#if !iframeVideo?has_content>
575 <#assign iframeVideo = field(xml,"apertura_iframe_video") />
576 </#if>
577
578 <#-- iFrame Audio desde MP_apertura.MP_apertura_iframe_audio -->
579 <#assign iframeAudio = field(xml,"MP_apertura_iframe_audio") />
580 <#if !iframeAudio?has_content>
581 <#assign iframeAudio = field(xml,"apertura_iframe_audio") />
582 </#if>
583
584 <#-- Autor -->
585 <#assign authorName = "" />
586 <#if hasJournalArticle>
587 <#assign userLocalService = serviceLocator.findService("com.liferay.portal.kernel.service.UserLocalService") />
588 <#assign author = userLocalService.fetchUser(ja.getUserId())! />
589 <#if author??>
590 <#assign authorName = author.getFullName() />
591 </#if>
592 </#if>
593
594 <#-- External Reference Code -->
595 <#assign erc = (ja.getExternalReferenceCode())!"" />
596
597 <#-- Structure Key -->
598 <#assign structureKey = ja.getDDMStructureKey() />
599
600 <#-- Limpiar campos que no aplican a programas -->
601 <#assign precio = "" />
602 <#assign tipo = "" />
603 <#assign modalidad = "" />
604 <#assign lugar = "" />
605 <#assign iconUrl = "" />
606 <#assign fechaInicio = "" />
607
608 <#assign href = articleURL />
609 </#if>
610
611
612 <#if !t?has_content && hasJournalArticle>
613 <#assign t = ja.getTitle(locale)!"" />
614 </#if>
615
616 <#assign resolvedImageUrl = resolveFileEntryUrl(imageFileEntryId, imageUrl) />
617 <#if resolvedImageUrl?has_content>
618 <#assign imageUrl = resolvedImageUrl />
619 </#if>
620
621 <#if debugImage>
622 <!--
623 image-debug className=${className?html}
624 structureKey=${sk?html}
625 rawImage=${(imgRaw!"")?string?replace("--", "__")?html}
626 imageFileEntryId=${imageFileEntryId?html}
627 originalImageUrl=${originalImageUrl?html}
628 resolvedImageUrl=${imageUrl?html}
629 -->
630 </#if>
631
632 <#-- Fallback accesible: estas tarjetas siempre deben enviar un alt no vacío. -->
633 <#if !imageAlt?has_content>
634 <#if t?has_content>
635 <#assign imageAlt = t />
636 <#elseif sk?contains("PUBLICACIONES")>
637 <#assign imageAlt = "Imagen de publicación" />
638 <#elseif sk?contains("NOTICIAS")>
639 <#assign imageAlt = "Imagen de noticia" />
640 <#elseif sk?contains("73205") || sk?contains("ACTIV")>
641 <#assign imageAlt = "Imagen de actividad" />
642 </#if>
643 </#if>
644
645 <#-- =========================================================
646 ETIQUETAS POR VISTA
647 GRID: solo tipo de contenido.
648 LIST: tipo primero + categorías/peculiaridades + avisos informativos.
649 ========================================================= -->
650
651 <#assign gridCats = contentTypeLabel />
652 <#assign gridCatsJson = contentTypeLabel?has_content?then('["' + contentTypeLabel + '"]', '[]') />
653
654 <#assign listNames = [] />
655
656 <#if contentTypeLabel?has_content>
657 <#assign listNames = addUnique(listNames, contentTypeLabel) />
658 </#if>
659
660 <#if cats?has_content>
661 <#list cats?split("|") as cn>
662 <#assign listNames = addUnique(listNames, cn) />
663 </#list>
664 </#if>
665
666 <#-- Los avisos funcionales se conservan también en listado.
667 basica-horizontal los mostrará como una etiqueta más; si después se quiere
668 clonar exactamente el aspecto verde/rojo de calendarizada, se puede afinar
669 únicamente ese JSP sin tocar esta lógica. -->
670 <#assign statusLabel = "" />
671
672 <#if precio == "free">
673 <#assign statusLabel = languageUtil.get(locale, "ic.tarjeta-calendarizada.gratuita") />
674 <#elseif precio == "full">
675 <#assign statusLabel = languageUtil.get(locale, "ic.tarjeta-calendarizada.aforo-completo") />
676 <#elseif precio == "cancelled">
677 <#assign statusLabel = languageUtil.get(locale, "ic.tarjeta-calendarizada.cancelado") />
678 <#elseif precio == "expired">
679 <#assign statusLabel = languageUtil.get(locale, "ic.tarjeta-calendarizada.fuera-de-plazo") />
680 <#elseif precio == "open">
681 <#assign statusLabel = languageUtil.get(locale, "ic.tarjeta-calendarizada.inscripcion-abierta") />
682 <#elseif precio == "last-spots">
683 <#assign statusLabel = languageUtil.get(locale, "ic.tarjeta-calendarizada.ultimas-plazas") />
684 </#if>
685
686 <#if statusLabel?has_content>
687 <#assign listNames = addUnique(listNames, statusLabel) />
688 </#if>
689
690 <#if modalidad?has_content && modalidad?trim?lower_case == "en directo">
691 <#assign listNames = addUnique(
692 listNames,
693 languageUtil.get(locale, "ic.tarjeta-calendarizada.en-directo")
694 ) />
695 </#if>
696
697 <#assign listCats = listNames?join("|") />
698
699 <#-- *** BOOTSTRAP: filas de 3 / 2 /1 *** -->
700
701 <div data-modeView="grid" class="d-none col-12 col-md-6 col-lg-4">
702 <#if !hasJournalArticle>
703 <@ricoh_dinamycTemplate["basica-vertical"]
704 className=className
705 classPK=classPK
706 title=t
707 spritemap=spr
708 href=href
709 />
710 <#elseif sk?contains("PUBLICACIONES") || sk?contains("PROGRAMA")>
711 <@ricoh_dinamycTemplate["tarjetas-pictograma"]
712 title=t
713 authorName=authorName
714 categoriesJson=gridCatsJson
715 imageUrl=imageUrl
716 imageAlt=imageAlt
717 imageFileEntryId=imageFileEntryId
718 href=href
719 erc=erc
720 spritemap=spr
721 structureKey=structureKey
722 />
723 <#elseif sk?contains("HISPANISTAS")>
724 <#assign dlAppService = serviceLocator.findService("com.liferay.document.library.kernel.service.DLAppService")>
725 <#assign dlFileEntryLocalService = serviceLocator.findService("com.liferay.document.library.kernel.service.DLFileEntryLocalService")>
726
727 <#assign fallbackImageTitle = "Virgulilla textura viento de solano recortada" />
728 <#assign structureLabel = "Hispanista" />
729
730 <#if sk?contains("HISPANISTAS_ASOCIACIONES")>
731 <#assign fallbackImageTitle = "Virgulilla textura armadura sagrada recortada" />
732 <#assign structureLabel = "Asociación" />
733
734 <#elseif sk?contains("HISPANISTAS_DEPARTAMENTOS")>
735 <#assign fallbackImageTitle = "Virgulilla textura sierra de don Quijote recortada" />
736 <#assign structureLabel = "Departamentos" />
737
738 <#elseif sk?contains("HISPANISTAS_EMPLEO_Y_BECAS")>
739 <#assign fallbackImageTitle = "Virgulilla textura montura del silencio" />
740 <#assign structureLabel = "Empleo y Becas" />
741
742 <#elseif sk?contains("HISPANISTAS_NOTICIAS")>
743 <#assign fallbackImageTitle = "Virgulilla textura sierra de don Quijote recortada" />
744 <#assign structureLabel = "Noticia" />
745
746 <#elseif sk?contains("HISPANISTAS_PROYECTO_INVESTIGACION")>
747 <#assign fallbackImageTitle = "Virgulilla textura gigante de los valles recortada" />
748 <#assign structureLabel = "Proyecto" />
749
750 <#elseif sk?contains("HISPANISTAS_TRIBUNAS")>
751 <#assign fallbackImageTitle = "Virgulilla textura gigante de los valles recortada" />
752 <#assign structureLabel = "Tribuna" />
753 </#if>
754 <#assign imageURL = "" />
755 <#assign imageFileEntryId = "" />
756 <#attempt>
757 <#assign fileEntries = dlFileEntryLocalService.getFileEntries(-1, -1)>
758 <#list fileEntries as fe>
759 <#if fe.getTitle()?lower_case == fallbackImageTitle?lower_case>
760 <#assign fileEntry = dlAppService.getFileEntry(fe.getFileEntryId())>
761 <#assign imageURL = themeDisplay.getPortalURL() + themeDisplay.getPathContext() + "/documents/" + fileEntry.getGroupId() + "/" + fileEntry.getUuid() />
762 <#assign imageFileEntryId = fileEntry.getFileEntryId()?string>
763 <#break>
764 </#if>
765 </#list>
766 <#recover>
767 </#attempt>
768 <@ricoh_dinamycTemplate["hispanistas-recurso-grafico-virgulilla"]
769 className=className
770 classPK=classPK
771
772 title=t
773 imageUrl=imageURL
774 imageAlt=fallbackImageTitle
775 imageFileEntryId=imageFileEntryId
776 friendlyUrl=href
777 categories="[]"
778 structureLabel=structureLabel
779 />
780 <#elseif sk?contains("NOTICIAS")>
781 <@ricoh_dinamycTemplate[renderer]
782 type = "SSinFecha"
783 className=className
784 classPK=classPK
785
786 title=t
787 precio=precio
788 tipo=tipo
789 modalidad=modalidad
790 lugar=lugar
791
792 iconUrl=iconUrl
793
794 imageUrl=imageUrl
795 imageAlt=imageAlt
796 imageFileEntryId=imageFileEntryId
797
798 fechaInicio=fechaInicio
799 durationMin=60
800
801 spritemap=spr
802 href=href
803
804 categories=gridCats
805 />
806 <#else>
807 <@ricoh_dinamycTemplate[renderer]
808 className=className
809 classPK=classPK
810
811 title=t
812 precio=precio
813 tipo=tipo
814 modalidad=modalidad
815 lugar=lugar
816
817 iconUrl=iconUrl
818
819 imageUrl=imageUrl
820 imageAlt=imageAlt
821 imageFileEntryId=imageFileEntryId
822
823 fechaInicio=fechaInicio
824 durationMin=60
825
826 spritemap=spr
827 href=href
828
829 categories=gridCats
830 />
831 </#if>
832 </div>
833 <div data-modeView="list" class="d-none">
834 <@ricoh_dinamycTemplate["basica-horizontal"]
835 type = "M"
836 className=className
837 classPK=classPK
838
839 title=t
840 spritemap=spr
841 imageUrl=imageUrl
842 imageAlt=imageAlt
843
844 friendlyUrl=href
845
846 entryId=imageFileEntryId
847 href=""
848 categories=listCats
849 />
850 </div>
851
852 </#list>
853 </div>
854</#if>
855</div>