- CHDuero
- Servicio al ciudadano
- Publicaciones
- Otras Publicaciones
Se ha producido un error al procesar la plantilla.
The following has evaluated to null or missing:
==> entries[0] [in template "20099#20135#425858" at line 91, column 20]
----
Tip: It's the final [] step that caused this error, not those before it.
----
Tip: If the failing expression is known to be legally refer to something that's sometimes null or missing, either specify a default value like myOptionalVar!myDefault, or use <#if myOptionalVar??>when-present<#else>when-missing</#if>. (These only cover the last step of the expression; to cover the whole expression, use parenthesis: (myOptionalVar.foo)!myDefault, (myOptionalVar.foo)??
----
----
FTL stack trace ("~" means nesting-related):
- Failed at: #assign pubName = entries[0].getCateg... [in template "20099#20135#425858" at line 91, column 1]
---- 1<style> 2 #publicaciones-chd .maderable-header{ 3 position: relative; 4 background: white; 5 } 6 7 #publicaciones-chd .header-title{ 8 position: relative; 9 border-left: 10px solid #1c7696; 10 padding: 10px 20px; 11 font-size: 2.4rem; 12 font-weight: bold; 13 color: black; 14 margin: 0; 15 word-break: break-word; 16 margin-bottom: 30px; 17 user-select: none; 18 } 19 20 #publicaciones-chd .lista_cajas_item{ 21 display: flex; 22 align-items: center; 23 padding: 30px 60px; 24 margin-bottom: 20px; 25 height: calc(100% - 20px); 26 min-height: 200px; 27 color: #1c7696; 28 box-shadow: none; 29 border: 1px solid #1c7696; 30 border-radius: 0.25rem; 31 } 32 33 #publicaciones-chd a:link{ 34 text-decoration:none; 35 } 36 37 #publicaciones-chd .imagen{ 38 margin-right: 60px; 39 width: 20%; 40 min-width: 100px; 41 } 42 43 #publicaciones-chd img{ 44 width: 100%; 45 } 46 47 #publicaciones-chd .titulo_interno{ 48 font-size: 1.2rem; 49 } 50 51 /*-------------------------- RESPONSIVE --------------------------*/ 52 @media screen and (max-width: 991px){ 53 #publicaciones-chd .lista_cajas_item{ 54 flex-direction: column; 55 padding: 30px; 56 justify-content: space-around; 57 } 58 59 #publicaciones-chd .imagen{ 60 margin-right: 0; 61 margin-bottom: 30px; 62 min-width: 120px; 63 } 64 65 #publicaciones-chd .titulo_interno{ 66 text-align: center; 67 font-size: 1.1rem; 68 } 69 } 70 71 @media screen and (max-width: 767px) and (orientation: portrait){ 72 #publicaciones-chd .header-title{ 73 border-left-width: 8px; 74 padding: 0.5rem 1rem; 75 font-size: 2rem; 76 } 77 } 78 79 @media screen and (max-width: 767px) and (orientation: landscape){ 80 #publicaciones-chd .header-title{ 81 font-size: 2.2rem; 82 border-left-width: 8px; 83 padding: 0.5rem 1rem; 84 } 85 } 86</style> 87 88<#assign dlFileEntryLocalService = serviceLocator.findService("com.liferay.document.library.kernel.service.DLFileEntryLocalService")> 89 90<#-- Obtenemos la categoria a la que pertenecen los documentos que se muestran en el publicador de contenidos --> 91<#assign pubName = entries[0].getCategories()[0].getName() /> 92 93<div class="row"> 94 <div id="publicaciones-chd" class="container-fluid-1280"> 95 <div class="row"> 96 <div class="col-12"> 97 <header class="publicaciones-header"> 98 <h2 class="header-title">${pubName}</h2> 99 </header> 100 <div class="row"> 101 <#list entries as curEntry> 102 <#assign renderer = curEntry.getAssetRenderer()> 103 <#assign className = renderer.getClassName()> 104 <#if (className == "com.liferay.journal.model.JournalArticle") > 105 <#assign article = renderer.getArticle()> 106 <#assign document = saxReaderUtil.read(article.getContent()) > 107 <#assign rootElement = document.getRootElement() > 108 <#assign xPathSelector = saxReaderUtil.createXPath("dynamic-element[@name='titulo']") > 109 <#assign titulo = xPathSelector.selectSingleNode(rootElement).getStringValue()?trim > 110 <#assign xPathSelector = saxReaderUtil.createXPath("dynamic-element[@name='enlace']") > 111 <#assign enlace = xPathSelector.selectSingleNode(rootElement).getStringValue()?trim > 112 <#assign xPathSelector = saxReaderUtil.createXPath("dynamic-element[@name='imagen']") > 113 <#assign imagenAux = xPathSelector.selectSingleNode(rootElement).getStringValue()?trim > 114 <#-- Parseamos el json que almacena la informacion de la imagen para obtener su URL. --> 115 <#if imagenAux != ""> 116 <#assign imgJSON = jsonFactoryUtil.createJSONObject(imagenAux) /> 117 <#assign dlFileEntry = dlFileEntryLocalService.getDLFileEntryByUuidAndGroupId(imgJSON.uuid, imgJSON.groupId?number) /> 118 <#assign imgURL = "/documents/"+ imgJSON.groupId +"/"+ dlFileEntry.getFileEntryId() +"/"+ imgJSON.title +"/"+ imgJSON.uuid /> 119 </#if> 120 121 <div class="col-md-6 col-sm-6 col-xs-12"> 122 <a target="_blank" href="${enlace}" aria-label="${titulo}"> 123 <div class="lista_cajas_item"> 124 <div class="imagen"> 125 <img src="${imgURL}" alt="Portada"> 126 </div> 127 <span class="titulo_interno"><b>${titulo}</b></span> 128 </div> 129 </a> 130 </div> 131 </#if> 132 </#list> 133 </div> 134 </div> 135 </div> 136 </div> 137</div>