Saltar al contenido
Se ha producido un error al procesar la plantilla.
Expression entry.publishDate is undefined on line 150, column 59 in 20155#20195#49483.
1<#assign liferay_ui = taglibLiferayHash["/WEB-INF/tld/liferay-ui.tld"] /> 
2 
3<style> 
4    .view-all-news { 
5        text-align: right; 
6        border-top: 3px solid #52B654; 
7        margin-left: 0px; 
8
9     
10    .view-all-news a { 
11        color: #52B654; 
12
13     
14    .view-all-news a:hover { 
15        color: #52B654; 
16
17     
18    .view-all-news a p { 
19        margin-top: 0.8em; 
20
21     
22    .content-title { 
23        padding: 0px; 
24        text-align: left; 
25        font-size: 1.2em; 
26        color: #FFF; 
27        cursor: default; 
28        position: relative; 
29        z-index: 1; 
30    }     
31     
32    .portlet-asset-publisher .asset-content { 
33        clear: right; 
34        margin-bottom: 10px; 
35        margin-left: 0px; 
36        margin-right: 10px; 
37
38 
39	.portlet-asset-publisher .asset-content a { 
40		color: #02b849 !important;	 
41    } 	 
42     
43    .portlet-asset-publisher .asset-abstract .asset-content p { 
44        margin-top: 0.8em; 
45
46	 
47	.plantilla-txt-der-content{ 
48		margin-left: 0px; 
49		margin-right: 20px; 
50		text-align: left; 
51		padding: 0px; 
52		word-break: keep-all; 
53		-moz-hyphens: none; 
54
55	 
56	.plantilla-img-izq-txt-der-content { 
57	    margin-left: 0px; 
58		padding: 0px; 
59
60	 
61	.plantilla-img-izq-txt-der-title { 
62		margin: 0px !important; 
63	}	 
64 
65	.portlet-asset-publisher h1 { 
66		margin-left: 0px; 
67
68	 
69</style> 
70 
71<section class="ctx" role="region"> 
72	<div class="content-title"> 
73        <#if locale == 'es_ES'> 
74            <h1 class="sectionTitle">Prensa</h1> 
75        <#elseif locale == 'en_US'> 
76            <h1 class="sectionTitle">Prensa</h1> 
77        </#if>		 
78	</div> 
79 
80<#list entries as entry> 
81	<#assign entry = entry /> 
82 
83	<#assign assetRenderer = entry.getAssetRenderer() /> 
84 
85	<#assign entryTitle = htmlUtil.escape(assetRenderer.getTitle(locale)) /> 
86 
87	<#assign viewURL = assetPublisherHelper.getAssetViewURL(renderRequest, renderResponse, entry) /> 
88 
89	<#if assetLinkBehavior != "showFullContent"> 
90		<#assign viewURL = assetPublisherHelper.getAssetViewURL(renderRequest, renderResponse, entry, true) /> 
91	</#if> 
92	 
93	<#assign viewURLSinParametros = viewURL?substring(0,viewURL?index_of("?")) /> 
94 
95	<div class="asset-abstract"> 
96		<div class="lfr-meta-actions asset-actions"> 
97			<@getPrintIcon /> 
98 
99			<@getFlagsIcon /> 
100 
101			<@getEditIcon /> 
102		</div> 
103 
104		<@getMetadataField fieldName="tags" /> 
105 
106		<@getMetadataField fieldName="create-date" /> 
107		 
108		 
109 
110		<@getMetadataField fieldName="view-count" /> 
111 
112		<div class="asset-content"> 
113			<@getSocialBookmarks /> 
114 
115			<div class="asset-summary"> 
116 
117<div class="plantilla-img-izq-txt-der-container">      
118         
119		<#assign docXml = saxReaderUtil.read(entry.getAssetRenderer().getArticle().getContent()) /> 
120		<#assign fieldImagen = docXml.valueOf("//dynamic-element[@name='Imagen']/dynamic-content/text()") /> 
121		<#assign fieldTextoAlternativoImagen = docXml.valueOf("//dynamic-element[@name='Imagen']/dynamic-element[@name='TextoAlternativoImagen']/dynamic-content/text()") /> 
122        <#assign fieldResumen = docXml.valueOf("//dynamic-element[@name='Resumen']/dynamic-content/text()") /> 
123         
124         <#assign fieldFuente = docXml.valueOf("//dynamic-element[@name='Fuente']/dynamic-content/text()") />	 
125          
126         <#assign fieldEnlaceFuente = docXml.valueOf("//dynamic-element[@name='EnlaceFuente']/dynamic-content/text()") /> 
127          
128          
129		<#assign rootElement = docXml.getRootElement() /> 
130		<#assign xPathSelector = saxReaderUtil.createXPath("dynamic-element[@name='Imagen']") /> 
131		<#assign imgMasTextoAlternativo = xPathSelector.selectSingleNode(rootElement).getStringValue() /> 
132		<#assign comienzoImagen = imgMasTextoAlternativo?index_of("/") /> 
133		<#if comienzoImagen != -1> 
134			<#assign img = imgMasTextoAlternativo?substring(imgMasTextoAlternativo?index_of("/")) /> 
135		<#else> 
136			<#assign img = fieldImagen> 
137		</#if> 
138 
139          
140          
141		 <#if img?has_content> 
142				<div class="plantilla-img-izq-txt-der-imagen"> 
143					<img alt="${fieldTextoAlternativoImagen}" src="${img}" width="200"/> 					 
144				</div>  
145				 
146				<div class="plantilla-img-izq-txt-der-content"> 							 
147						<h2 class="plantilla-img-izq-txt-der-title"> <a href="${viewURLSinParametros}">${entryTitle}</a> </h2>  
148						 
149						<span class="plantilla-img-izq-txt-der-fecha"> 
150							${entry.publishDate?string["dd.MM.yyyy"]} 
151						</span> 
152							 
153						<p>${fieldResumen}</p> 		 
154						 
155						<#if fieldFuente != ''> 
156                            <a href="${fieldEnlaceFuente}" title="${fieldFuente}" target="_blank">${fieldFuente}</a> 
157                        </#if>  						 
158				</div> 				 
159		<#else>	 
160				<div class="plantilla-txt-der-content"> 							 
161						<h2 class="plantilla-img-izq-txt-der-title"> <a href="${viewURLSinParametros}">${entryTitle}</a> </h2>  
162						 
163						<span class="plantilla-img-izq-txt-der-fecha"> 
164							${entry.publishDate?string["dd.MM.yyyy"]} 
165						</span> 
166							 
167						<p>${fieldResumen}</p> 	 
168 
169						<#if fieldFuente != ''> 
170                            <a href="${fieldEnlaceFuente}" title="${fieldFuente}" target="_blank">${fieldFuente}</a> 
171                        </#if>  						 
172				</div> 		 
173		</#if> 
174		 
175 
176</div> 				 
177 
178			</div> 
179 
180			<@getRatings /> 
181 
182			<@getRelatedAssets /> 
183 
184			<@getDiscussion /> 
185		</div> 
186	</div> 
187 
188</#list> 
189 
190</section> 
191 
192<#macro getDiscussion> 
193	<#if validator.isNotNull(assetRenderer.getDiscussionPath()) && (enableComments == "true")> 
194		<br /> 
195 
196		<#assign discussionURL = renderResponse.createActionURL() /> 
197 
198		${discussionURL.setParameter("struts_action", "/asset_publisher/" + assetRenderer.getDiscussionPath())} 
199 
200		<@liferay_ui["discussion"] 
201			className=entry.getClassName() 
202			classPK=entry.getClassPK() 
203			formAction=discussionURL?string 
204			formName="fm" + entry.getClassPK() 
205			ratingsEnabled=enableCommentRatings == "true" 
206			redirect=portalUtil.getCurrentURL(request) 
207			userId=assetRenderer.getUserId() 
208		/> 
209	</#if> 
210</#macro> 
211 
212<#macro getEditIcon> 
213	<#if assetRenderer.hasEditPermission(themeDisplay.getPermissionChecker())> 
214		<#assign redirectURL = renderResponse.createRenderURL() /> 
215 
216		${redirectURL.setParameter("struts_action", "/asset_publisher/add_asset_redirect")} 
217		${redirectURL.setWindowState("pop_up")} 
218 
219		<#assign editPortletURL = assetRenderer.getURLEdit(renderRequest, renderResponse, windowStateFactory.getWindowState("pop_up"), redirectURL)!"" /> 
220 
221		<#if validator.isNotNull(editPortletURL)> 
222			<#assign title = languageUtil.format(locale, "edit-x", entryTitle) /> 
223 
224			<@liferay_ui["icon"] 
225				image="edit" 
226				message=title 
227				url="javascript:Liferay.Util.openWindow({dialog: {width: 960}, id:'" + renderResponse.getNamespace() + "editAsset', title: '" + title + "', uri:'" + htmlUtil.escapeURL(editPortletURL.toString()) + "'});" 
228			/> 
229		</#if> 
230	</#if> 
231</#macro> 
232 
233<#macro getFlagsIcon> 
234	<#if enableFlags == "true"> 
235		<@liferay_ui["flags"] 
236			className=entry.getClassName() 
237			classPK=entry.getClassPK() 
238			contentTitle=entry.getTitle(locale) 
239			label=false 
240			reportedUserId=entry.getUserId() 
241		/> 
242	</#if> 
243</#macro> 
244 
245<#macro getMetadataField fieldName> 
246	<#if stringUtil.split(metadataFields)?seq_contains(fieldName)> 
247		<span class="metadata-entry metadata-"${fieldName}"> 
248			<#assign dateFormat = "dd MMM yyyy - HH:mm:ss" /> 
249 
250			<#if fieldName == "author"> 
251				<@liferay.language key="by" /> ${portalUtil.getUserName(assetRenderer.getUserId(), assetRenderer.getUserName())} 
252			<#elseif fieldName == "categories"> 
253				<@liferay_ui["asset-categories-summary"] 
254					className=entry.getClassName() 
255					classPK=entry.getClassPK() 
256					portletURL=renderResponse.createRenderURL() 
257				/> 
258			<#elseif fieldName == "create-date"> 
259				${dateUtil.getDate(entry.getCreateDate(), dateFormat, locale)} 
260			<#elseif fieldName == "expiration-date"> 
261				${dateUtil.getDate(entry.getExpirationDate(), dateFormat, locale)} 
262			<#elseif fieldName == "modified-date"> 
263				${dateUtil.getDate(entry.getModifiedDate(), dateFormat, locale)} 
264			<#elseif fieldName == "priority"> 
265				${entry.getPriority()} 
266			<#elseif fieldName == "publish-date"> 
267				${dateUtil.getDate(entry.getPublishDate(), dateFormat, locale)} 
268			<#elseif fieldName == "tags"> 
269				<@liferay_ui["asset-tags-summary"] 
270					className=entry.getClassName() 
271					classPK=entry.getClassPK() 
272					portletURL=renderResponse.createRenderURL() 
273				/> 
274			<#elseif fieldName == "view-count"> 
275				<@liferay_ui["icon"] 
276					image="history" 
277				/> 
278 
279				${entry.getViewCount()} <@liferay.language key="views" /> 
280			</#if> 
281		</span> 
282	</#if> 
283</#macro> 
284 
285<#macro getPrintIcon> 
286	<#if enablePrint == "true" > 
287		<#assign printURL = renderResponse.createRenderURL() /> 
288 
289		${printURL.setParameter("struts_action", "/asset_publisher/view_content")} 
290		${printURL.setParameter("assetEntryId", entry.getEntryId()?string)} 
291		${printURL.setParameter("viewMode", "print")} 
292		${printURL.setParameter("type", entry.getAssetRendererFactory().getType())} 
293 
294		<#if (validator.isNotNull(assetRenderer.getUrlTitle()))> 
295			<#if (assetRenderer.getGroupId() != themeDisplay.getScopeGroupId())> 
296				${printURL.setParameter("groupId", assetRenderer.getGroupId()?string)} 
297			</#if> 
298 
299			${printURL.setParameter("urlTitle", assetRenderer.getUrlTitle())} 
300		</#if> 
301 
302		${printURL.setWindowState("pop_up")} 
303 
304		<@liferay_ui["icon"] 
305			image="print" 
306			message="print" 
307			url="javascript:Liferay.Util.openWindow({id:'" + renderResponse.getNamespace() + "printAsset', title: '" + languageUtil.format(locale, "print-x-x", ["hide-accessible", entryTitle]) + "', uri: '" + htmlUtil.escapeURL(printURL.toString()) + "'});" 
308		/> 
309	</#if> 
310</#macro> 
311 
312<#macro getRatings> 
313	<#if (enableRatings == "true")> 
314		<div class="asset-ratings"> 
315			<@liferay_ui["ratings"] 
316				className=entry.getClassName() 
317				classPK=entry.getClassPK() 
318			/> 
319		</div> 
320	</#if> 
321</#macro> 
322 
323<#macro getRelatedAssets> 
324	<#if enableRelatedAssets == "true"> 
325		<@liferay_ui["asset-links"] 
326			assetEntryId=entry.getEntryId() 
327		/> 
328	</#if> 
329</#macro> 
330 
331<#macro getSocialBookmarks> 
332	<#if enableSocialBookmarks == "true"> 
333		<@liferay_ui["social-bookmarks"] 
334			displayStyle="${socialBookmarksDisplayStyle}" 
335			target="_blank" 
336			title=entry.getTitle(locale) 
337			url=viewURL 
338		/> 
339	</#if> 
340</#macro>