angle-left Innovaciones en la construcción del Tercer Juego de Esclusas del Canal de Panamá
Se ha producido un error al procesar la plantilla.
The following has evaluated to null or missing:
==> respparts  [in template "16924578#16924624#30950" at line 95, column 111]

----
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 respParts = stringUtil.split(...  [in template "16924578#16924624#30950" at line 95, column 73]
----
1<#assign journalArticleId = .vars['reserved-article-id'].data> 
2 
3<#assign JournalArticleLocalService = serviceLocator.findService("com.liferay.journal.service.JournalArticleLocalService")> 
4<#assign AssetCategoryLocalService = serviceLocator.findService("com.liferay.asset.kernel.service.AssetCategoryLocalService")> 
5<#assign AssetVocabularyLocalService = serviceLocator.findService("com.liferay.asset.kernel.service.AssetVocabularyLocalService")> 
6<#assign AssetTagLocalService = serviceLocator.findService("com.liferay.asset.kernel.service.AssetTagLocalService")> 
7<#assign AssetEntryLocalService = serviceLocator.findService("com.liferay.asset.kernel.service.AssetEntryLocalService")> 
8<#assign DLAppLocalService = serviceLocator.findService("com.liferay.document.library.kernel.service.DLAppLocalService")> 
9<#assign ImageToolUtil = serviceLocator.findService("com.liferay.portal.kernel.image.ImageToolUtil")> 
10 
11<#assign blogVocabulary = AssetVocabularyLocalService.getGroupVocabulary(groupId, "Blog")> 
12 
13<#if separator.getSiblings()?has_content> 
14    <#list separator.getSiblings() as separatorField> 
15     
16        <#assign postTitle = separatorField.title.getData() > 
17 
18		<#if separatorField.intro?? && separatorField.intro.getData()?has_content> 
19            <#assign postIntro = separatorField.intro.getData() > 
20		</#if> 
21		<#if separatorField.image.getData()?has_content> 
22            <#assign postImage = separatorField.image.getData() > 
23		</#if> 
24		<#if separatorField.youtubeInsertionCode?? && separatorField.youtubeInsertionCode.getData()?has_content> 
25        	<#assign postYoutubeInsertionCode = separatorField.youtubeInsertionCode.getData() > 
26		</#if> 
27        <#assign postContent = separatorField.content.getData() > 
28 
29        <#-- Recuperamos el web content --> 
30		<#assign article = JournalArticleLocalService.fetchArticle(groupId, journalArticleId)> 
31	 
32		<#-- Recuperamos las categorías del web content --> 
33		<#assign articleCategories = AssetCategoryLocalService.getCategories("com.liferay.journal.model.JournalArticle", article.getResourcePrimKey())> 
34     
35		<#-- Recuperamos los tags del web content --> 
36		<#assign articleTags = AssetTagLocalService.getTags("com.liferay.journal.model.JournalArticle", article.getResourcePrimKey())> 
37 
38		<div id="main"> 
39			<article id="post-${journalArticleId}" class="post-${journalArticleId} post type-post status-publish format-standard hentry"> 
40			 
41				<div class="post-header"> 
42					<span class="cat"> 
43						<#if articleCategories?has_content> 
44							<#list articleCategories as articleCategory> 
45								<#-- Categorías del vocabulario Blog --> 
46								<#if articleCategory.getVocabularyId() == blogVocabulary.getVocabularyId() > 
47									<#assign categoryName = articleCategory.getName()?upper_case /> 
48									<#assign categoryID = articleCategory.getCategoryId() /> 
49									<#assign categoryURL = '/cat/-/categories/' + categoryID /> 
50									<a href="${categoryURL}" rel="category tag">${categoryName}</a> 
51								</#if> 
52							</#list> 
53						</#if> 
54					</span> 
55 
56					<h1>${postTitle}</h1> 
57					<span class="title-divider"></span> 
58					<span class="post-date"> 
59                        <#if (locale == "es_ES") > 
60                            <span class="post-date">${article.getDisplayDate()?string["dd/MM/yyyy"]}</span> 
61                        <#else> 
62                            <span class="post-date">${article.getDisplayDate()?string["MM/dd/yyyy"]}</span> 
63                        </#if> 
64					</span> 
65 
66					<#if postIntro?? > 
67						<div class="post-entry-intro"> 
68							${postIntro} 
69						</div> 
70					</#if> 
71				</div> 
72				 
73				<#if postYoutubeInsertionCode?? && (postYoutubeInsertionCode?length > 10) > 
74					<div class="embed-container">${postYoutubeInsertionCode}</div> 
75				<#elseif postImage?? > 
76					<#assign parts = stringUtil.split(postImage, "/")> 
77					<#assign parts = stringUtil.split(parts?last, "?")> 
78					<#assign uuid = parts[0]> 
79					<#assign fileEntry = DLAppLocalService.getFileEntryByUuidAndGroupId(uuid, groupId)> 
80					<#assign fileEntryContentStrean = fileEntry.getContentStream()> 
81					<#assign image = ImageToolUtil.getImage(fileEntryContentStrean)> 
82					<#assign imageWidth = image.width > 
83					<#assign imageHeight = image.height > 
84					<#assign srcset = "" > 
85					<#assign sizes = ", " + imageWidth + "px" > 
86					<#assign useResponsiveImages = false > 
87 
88 
89					<#if separatorField.image.responsiveImage?? > 
90						<#if separatorField.image.responsiveImage.getSiblings()?has_content> 
91							<#list separatorField.image.responsiveImage.getSiblings() as responsiveImageField> 
92								<#assign responsiveImage = responsiveImageField.getData() > 
93								<#if responsiveImage?has_content > 
94									<#assign respParts = stringUtil.split(responsiveImage, "/")> 
95									<#assign respParts = stringUtil.split(respparts?last, "?")> 
96									<#assign respUuuid = respParts[0]> 
97									<#assign respFileEntry = DLAppLocalService.getFileEntryByUuidAndGroupId(respUuuid, groupId)> 
98									<#assign respFileEntryContentStrean = respFileEntry.getContentStream()> 
99									<#assign respImage = ImageToolUtil.getImage(respFileEntryContentStrean)> 
100									<#assign respImageWidth = respImage.width > 
101									<#assign srcset = srcset + responsiveImage + " " + respImageWidth + "w " > 
102									<#assign sizes = sizes + ", " + respImageWidth + "px" > 
103									<#assign useResponsiveImages = true > 
104								</#if> 
105							</#list> 
106						</#if> 
107					</#if> 
108 
109					<#if useResponsiveImages > 
110							<div class="post-img"> 
111								<img src="${postImage}" class="attachment-full-thumb size-full-thumb wp-post-image" srcset="${srcset}" sizes="(max-width: ${imageWidth}px) 100vw${sizes}" width="${imageWidth}" height="${imageHeight}"> 
112							</div> 
113					<#else> 
114						<div class="post-img"> 
115							<img src="${postImage}" class="attachment-full-thumb size-full-thumb wp-post-image"> 
116 
117						</div> 
118					</#if> 
119 
120                </#if> 
121 
122				<div class="post-entry"> 
123				    <div class="post-entry-content"> 
124					    ${postContent} 
125			        </div> 
126 
127				    <#if articleTags?has_content> 
128    					<div class="post-tags"> 
129    			            <#list articleTags as articleTag> 
130                                <#assign tagName = articleTag.getName()?upper_case /> 
131                                <#assign tagURL = '/tag/-/tag/' + tagName /> 
132    			                <a href="${tagURL}" rel="tag">${tagName}</a> 
133        		            </#list> 
134    					</div> 
135                    </#if> 
136						 
137				</div>			 
138				 
139				<div class="post-share"> 
140				 
141                    <#assign serviceContext = staticUtil["com.liferay.portal.kernel.service.ServiceContextThreadLocal"].getServiceContext()> 
142                    <#assign themeDisplay = serviceContext.getThemeDisplay() /> 
143                    <#assign currentUrl = themeDisplay.getPortalURL() + themeDisplay.getURLCurrent() /> 
144                     
145					<div class="post-share-box share-buttons"> 
146						<a target="_blank" href="https://www.facebook.com/sharer/sharer.php?u=${currentUrl}"> 
147							<i class="fa fa-facebook"></i> 
148						</a> 
149						<a target="_blank" href="https://twitter.com/intent/tweet?text=Check%20out%20this%20article:%20${postTitle}&amp;url=${currentUrl}"> 
150							<i class="fa fa-twitter"></i> 
151						</a> 
152						<a target="_blank" href="https://www.linkedin.com/shareArticle?mini=true&url=${currentUrl}&title=${postTitle}"> 
153							<i class="fa fa-linkedin"></i> 
154						</a> 
155<!--						 
156                        <#if postImage??> 
157                            <#assign pinterestImageUrl = themeDisplay.getPortalURL() + postImage /> 
158							<a data-pin-do="none" target="_blank" href="https://pinterest.com/pin/create/button?url=${currentUrl}&amp;media=${pinterestImageUrl}&amp;description=${postTitle}"> 
159    							<i class="fa fa-pinterest"></i> 
160    						</a> 
161    					</#if> 
162						<a target="_blank" href="https://plus.google.com/share?url=${currentUrl}"> 
163							<i class="fa fa-google-plus"></i> 
164						</a> 
165--> 
166					</div> 
167				</div> 
168 
169        		<#-- Buscamos artículos relacionados por la primera categoría --> 
170        	    <#if articleCategories?has_content> 
171					<#list articleCategories as articleCategory> 
172						<#-- Categorías del vocabulario Blog --> 
173						<#if articleCategory.getVocabularyId() == blogVocabulary.getVocabularyId() > 
174							<#assign category = articleCategory > 
175							<#break> 
176						</#if> 
177					</#list> 
178 
179                    <#assign assetEntries = AssetEntryLocalService.getAssetCategoryAssetEntries(category.getCategoryId()) > 
180                    <#if assetEntries?has_content> 
181        				<div class="post-related"> 
182        					<div class="post-box"> 
183        						<h4 class="post-box-title"> 
184									<#if (locale == "es_ES") > 
185										<span>Tambi&eacute;n podr&iacute;a gustarte</span> 
186									<#else> 
187										<span>You may also like</span> 
188									</#if> 
189        						</h4> 
190        					</div> 
191        					 
192        					<#--<div class="row"> --> 
193         
194                                <#-- #assign relatedAssetEntries = assetEntries?reverse?chunk(4)?first --> 
195                                <#assign relatedAssetEntries = assetEntries?reverse > 
196                                 
197                                <#if relatedAssetEntries?has_content> 
198                                    <#assign counter = 0 > 
199                                    <#list relatedAssetEntries as relatedAssetEntry> 
200                                        <#if relatedAssetEntry.getClassPK() != article.getResourcePrimKey() && relatedAssetEntry.getVisible() > 
201                                            <#assign relatedArticle = JournalArticleLocalService.fetchLatestArticle (relatedAssetEntry.getClassPK()) > 
202                                            <#if relatedArticle.getDDMStructureKey() == article.getDDMStructureKey() > 
203     
204                                    			<#-- Recuperamos la url de visualización del artículo --> 
205                                                <#assign relatedArticleURL = '/-/' + relatedArticle.getUrlTitle() /> 
206         
207                                                <#-- Extraemos los campos del web content recorriendo su estructura --> 
208                                                <#assign document = saxReaderUtil.read(relatedArticle.getContent()) /> 
209                                                <#assign rootElement = document.getRootElement() /> 
210                                                <#assign xPathSelector = saxReaderUtil.createXPath("dynamic-element[@name='separator']") > 
211                                                <#list xPathSelector.selectNodes(rootElement) as separatorNode> 
212                                                	<#assign titleXPathSelector = saxReaderUtil.createXPath("dynamic-element[@name='title']") > 
213                                                	<#list titleXPathSelector.selectNodes(separatorNode) as title> 
214                                                		<#assign relatedArticleTitle = title.getStringValue() /> 
215                                                	</#list> 
216                                                	<#assign imageXPathSelector = saxReaderUtil.createXPath("dynamic-element[@name='image']") > 
217                                                	<#list imageXPathSelector.selectNodes(separatorNode) as image> 
218                                                		<#if image.getData()?has_content > 
219                                                			<#assign relatedArticleImage = image.getStringValue()?trim /> 
220                                                		</#if>     
221                                                	</#list> 
222                                                </#list> 
223     
224                            				<#--	<div class="col-xs-12 col-lg-4">  --> 
225                                					<div class="item-related"> 
226                                					    <#if relatedArticleImage?has_content > 
227                                    						<a href="${relatedArticleURL}"><img src="${relatedArticleImage}" class="attachment-misc-thumb size-misc-thumb wp-post-image" alt="" width="520" height="400"></a> 
228                                						</#if> 
229                                												 
230                                						<h3> 
231                                							<a href="${relatedArticleURL}">${relatedArticleTitle}</a> 
232                                						</h3> 
233                                						 
234                                                        <#if (locale == "es_ES") > 
235                                                            <span class="date">${relatedArticle.getDisplayDate()?string["dd/MM/yyyy"]}</span> 
236                                                        <#else> 
237                                                            <span class="date">${relatedArticle.getDisplayDate()?string["MM/dd/yyyy"]}</span> 
238                                                        </#if> 
239                                							 
240                                					</div> 
241                            				<#--	</div>  --> 
242     
243                                                <#assign counter = counter + 1 > 
244                                            </#if> 
245                                        </#if> 
246                                         
247                                        <#if counter == 3> 
248                                            <#break> 
249                                        </#if> 
250                                    </#list> 
251                                </#if> 
252                            <#--</div>  --> 
253                        </div> 
254                    </#if> 
255        	    </#if> 
256			</article> 
257		</div> 
258	</#list> 
259</#if> 

SÍGUENOS EN FACEBOOK

VIDEOS INNOVACIÓN

VIDEOS IFRIDAYS

CONTACTO SACYR

Condesa de Venadito, 7
28027 - Madrid (España)
Teléfono: +34 91 545 50 00

www.sacyr.com