Subscrever Notícias

Ocorreu um erro no processamento do modelo.
Expression Tipo_de_evento is undefined on line 59, column 6 in 254#294#73773.
1<#-- Configuration Variables --> 
2<#assign displayTags = false> <#-- Possible values are: true false --> 
3<#-- Template --> 
4 
5<#assign articleTitle = .vars['reserved-article-title'].data> 
6<#assign articleID = .vars['reserved-article-id'].data> 
7<#assign articleVersion = .vars['reserved-article-version'].data> 
8 
9<#if request['theme-display']??> 
10	<#assign themeDisplay = request['theme-display'] > 
11	<#assign layout = themeDisplay['plid'] > 
12	<#assign layoutService = serviceLocator.findService("com.liferay.portal.service.LayoutLocalService") > 
13	<#assign layoutObject = layoutService.getLayout(layout?number) > 
14	 
15	<#assign portalURL = httpUtil.getProtocol(request['attributes']['CURRENT_URL']) + "https://" + getterUtil.getString(request['theme-display']['portal-url']) > 
16	<#assign mainPath = layoutObject.getFriendlyURL(locale) > 
17	<#assign currentBaseURL = portalURL + themeDisplay['path-friendly-url-public'] + layoutObject.getGroup().getFriendlyURL() + mainPath> 
18	 
19	<#assign shareURL = currentBaseURL> 
20	<#if request['attributes']['CURRENT_URL']?contains("/-/journal_content/")> 
21		<#if request['attributes']['CURRENT_URL']?contains("?")> 
22			<#assign shareURL = portalURL + request['attributes']['CURRENT_URL']?split("?")[0]> 
23		<#else> 
24			<#assign shareURL = portalURL + request['attributes']['CURRENT_URL']> 
25		</#if> 
26	</#if> 
27</#if> 
28 
29<#assign Data_Data = getterUtil.getLong("0")> 
30<#if Data_iniço?? && Data_iniço.getData()?has_content> 
31	<#assign Data_Data = getterUtil.getLong(Data_iniço.getData())> 
32</#if> 
33               
34<#if (Data_Data > 0)> 
35	<#assign Data_DateObj = dateUtil.newDate(Data_Data)> 
36	<#assign eventStartDate = dateUtil.getDate(Data_DateObj, "dd/MMM/yyyy", locale)?lower_case> 
37<#else> 
38	<#assign eventStartDate = ""> 
39</#if> 
40 
41<#assign i = 0> 
42<#assign eventStartDay = ""> 
43<#assign eventStartMonth = ""> 
44<#if eventStartDate?contains("/")> 
45	<#list eventStartDate?split("/") as x> 
46	    <#if (i==0)> 
47			<#if x?starts_with("0")> 
48				<#assign eventStartDay = x?replace('0', '')> 
49			<#else> 
50				<#assign eventStartDay = x> 
51			</#if>	         
52	    <#elseif i == 1> 
53	        <#assign eventStartMonth = x> 
54	    </#if> 
55	    <#assign i = i + 1> 
56	</#list> 
57</#if> 
58 
59<#if Tipo_de_evento.getData() == "inf_d"> 
60    <#assign eventType = "O Infarmed divulga"> 
61    <#assign eventIcon = "feed"> 
62<#elseif Tipo_de_evento.getData() == "inf_o"> 
63    <#assign eventType = "O Infarmed organiza"> 
64    <#assign eventIcon = "home"> 
65<#elseif Tipo_de_evento.getData() == "inf_r"> 
66    <#assign eventType = "O Infarmed recebe"> 
67    <#assign eventIcon = "local"> 
68<#elseif Tipo_de_evento.getData() == "inf_p"> 
69    <#assign eventType = "O Infarmed participa"> 
70    <#assign eventIcon = "user"> 
71<#else> 
72    <#assign eventType = "O Infarmed divulga"> 
73    <#assign eventIcon = "feed"> 
74</#if> 
75 
76<#assign hasHours = Data.get("Hora")?? && Data.get("Hora").getData()?has_content> 
77<#assign hasLocal = Local?? && Local.getData()?has_content> 
78<#assign hasSubtitulo = Subtitulo?? && Subtitulo.getData()?has_content> 
79<#assign hasRegistLink = Link_para_inscrição?? && Link_para_inscrição.getData()?has_content> 
80<#assign hasSeparador = Separador?? && Separador.getData()?has_content> 
81<#assign hasImagem = Imagem?? && Imagem.getData()?has_content> 
82 
83<#assign hasRegistState = Estado_das_inscrições?? && Estado_das_inscrições.getData()?has_content> 
84 
85<script src="https://code.jquery.com/jquery-2.2.4.min.js"></script> <!-- Usado por causa das tabs --> 
86 
87<style> 
88	/* bootstrap hack: fix content width inside hidden tabs */ 
89	#${randomNamespace}Tabbable .tab-content > .tab-pane, .pill-content > .pill-pane { 
90	    display: block;    /* undo display:none          */ 
91	    height: 0;         /* height:0 is also invisible */  
92	    overflow: hidden;  /* no-overflow                */ 
93
94	#${randomNamespace}Tabbable .tab-content > .active, .pill-content > .active { 
95	    height: auto;      /* let the content decide it  */ 
96	} /* bootstrap hack end */ 
97</style> 
98 
99<style> 
100	.tabbable .tab-content.${randomNamespace}showOverflow {	 
101		overflow: visible; 
102
103	 
104	.tabbable li a.${randomNamespace}tabText {	 
105	    font-family: "Roboto", sans-serif; 
106	    font-size: 1.5em; 
107
108	 
109	#eventDetail .tabbable{ 
110    	margin-top: 30px; 
111
112     
113    #eventDetail .tabbable .nav-tabs li a{ 
114    	font-family: "Roboto", sans-serif; 
115        font-size: 1.5em; 
116
117	 
118</style> 
119 
120<div class="hide" style="display:none !important; mso-hide:all;"> 
121    <h1 style="color:#ffffff;"> Acessibilidade </h1> 
122    <a href="#titulo"></a> 
123</div> 
124 
125<div id="eventDetail"> 
126	<div class="hero-banner simple-banner break-free"> 
127		<div class="container-medium inside"> 
128			<div class="banner-group"> 
129			    <#if hasImagem> 
130			        <div class="banner-image" style="background-image: url(${Imagem.getData()})"> 
131			        </div> 
132			    <#else> 
133			        <div class="banner-image" style="background-image: url(/infarmed-theme/images/tmp/event1.jpg)" "> 
134			        </div> 
135			    </#if> 
136				<div class="banner-text "> 
137					<div class="text-wrap "> 
138						<article class="event event-detail-header "> 
139							<div class="event-link "> 
140								<time class="date "> 
141								    <#if eventStartDay != ""> 
142                                        <strong>${eventStartDay}</strong> 
143								    </#if> 
144									<#if eventStartMonth != ""> 
145									     <span>${eventStartMonth}</span> 
146									</#if> 
147								</time> 
148								<header class="event-header "> 
149									<div class="event-type "> 
150										<div class="wrap "> 
151											<span class="font-icon ico-${eventIcon}"></span>${eventType} 
152										</div> 
153									</div> 
154									<h1 id="titulo" class="title "> 
155										${articleTitle} 
156									</h1> 
157								</header> 
158							</div> 
159						</article> 
160					</div> 
161				</div> 
162			</div> 
163		</div> 
164		<div class="banner-meta-wrap "> 
165			<div class="container-medium inside "> 
166				<div class="event-wrap-footer "> 
167					<div class="event event-detail-footer "> 
168						<div class="event-meta "> 
169						    <#if hasHours> 
170							    <time>${Data.get("Hora").getData()}</time> 
171							</#if> 
172							<#if hasLocal> 
173							    <div class="location "> 
174    							    ${Local.getData()} 
175    							</div> 
176							</#if> 
177						</div> 
178					</div> 
179					<div class="action-call"> 
180					    <#if hasRegistState> 
181    					    <#if Estado_das_inscrições.getData() != "notPresent"> 
182        					    <#if Estado_das_inscrições.getData() == "openRegistation"> 
183        					        <#if hasRegistLink> 
184        					            <#assign cur_Link_URL = Link_para_inscrição.getData()> 
185                                    	<#assign URL_target = ""> 
186                                    	<#if !cur_Link_URL?starts_with("/") && !cur_Link_URL?contains("infarmed.pt")> 
187                                    		<#assign URL_target = "_blank">					 
188                                    	</#if> 
189                                    	<#if !cur_Link_URL?starts_with("/") && !cur_Link_URL?starts_with("http")> 
190                                    		<#assign cur_Link_URL = "http://" + cur_Link_URL> 
191                                    	</#if> 
192            					        <a href="${cur_Link_URL}" target="${URL_target}"> 
193            					    <#else> 
194            					        <a href="#"> 
195            					    </#if> 
196                						    <span class="button large filled rounded ">Inscrições abertas</span> 
197                						</a> 
198        					    <#else> 
199        					        <span style="cursor:default;" class="button large filled rounded ">Inscrições encerradas</span> 
200        					    </#if> 
201        					</#if> 
202        				</#if> 
203					</div> 
204					<#if request['theme-display']??> 
205						<div class="actions "> 
206							<a href="javascript:${randomNamespace}printPage();" class="print">Imprimir  
207							    <div class="fa fa-print" aria-hidden="true"> 
208							    </div> 
209							</a> 
210							<#if request['theme-display']??> 
211	    						<#assign portletPreferencesService = serviceLocator.findService("com.liferay.portal.service.PortletPreferencesLocalService") > 
212	    						<#assign portletPreferencesInLayout = portletPreferencesService.getPortletPreferencesByPlid(layout?number)> 
213	    						<#assign portletInstanceId = "56_INSTANCE_0000"> 
214	    						<#list portletPreferencesInLayout as curPortletPreferences> 
215	    							<#if curPortletPreferences.getPortletId()?starts_with("56")>			 
216	    								<#assign preferencesXML = saxReaderUtil.read(curPortletPreferences.getPreferences())> 
217	    								<#if preferencesXML.selectSingleNode("/portlet-preferences/preference[name[text()=\"articleId\"]]/value")??> 
218	    									<#assign XMLnode = preferencesXML.selectSingleNode("/portlet-preferences/preference[name[text()=\"articleId\"]]/value")> 
219	    									<#if XMLnode.getText() == articleID> 
220	    										<#assign portletInstanceId = curPortletPreferences.getPortletId()> 
221	    										<#break> 
222	    									</#if> 
223	    								</#if> 
224	    							</#if> 
225	    						</#list> 
226	    						<script> 
227	    							function ${randomNamespace}printPage() { 
228										if(window.location.href.indexOf("viewMode=print")>=0){ 
229											window.print(); 
230
231										else{ 
232	                                        window.open('${currentBaseURL}/-/journal_content/${portletInstanceId}/${scopeGroupId}/${articleID}?p_p_state=pop_up&_${portletInstanceId}_page=1&_${portletInstanceId}_viewMode=print', '', "directories=0,height=480,left=80,location=1,menubar=1,resizable=1,scrollbars=yes,status=0,toolbar=0,top=180,width=640"); 
233
234
235	    						</script> 
236							</#if> 
237							<div class="share-inline"> 
238								<#assign fbPageURLToShare = "https://www.facebook.com/sharer/sharer.php"> 
239								<#assign fbPageURLToShare = httpUtil.addParameter(fbPageURLToShare, "u", shareURL)> 
240								<#assign fbPageURLToShare = httpUtil.addParameter(fbPageURLToShare, "title", articleTitle)> 
241								<#assign fbPageURLToShare = httpUtil.addParameter(fbPageURLToShare, "description", "Infarmed")> 
242								<#if hasImagem?? && hasImagem> 
243									<#assign fbPageURLToShare = httpUtil.addParameter(fbPageURLToShare, "picture", portalURL + Imagem.getData())> 
244								<#else> 
245									<#assign fbPageURLToShare = httpUtil.addParameter(fbPageURLToShare, "picture", portalURL + "/infarmed-theme/images/infarmed-coloured.png")> 
246								</#if> 
247								<#assign twitterPageURLToShare = "https://twitter.com/intent/tweet"> 
248								<#assign twitterPageURLToShare = httpUtil.addParameter(twitterPageURLToShare, "text", articleTitle)> 
249								<#assign twitterPageURLToShare = httpUtil.addParameter(twitterPageURLToShare, "url", shareURL)> 
250								 
251								<#assign linkedinPageURLToShare = "https://www.linkedin.com/shareArticle"> 
252								<#assign linkedinPageURLToShare = httpUtil.addParameter(linkedinPageURLToShare, "mini", true)> 
253								<#assign linkedinPageURLToShare = httpUtil.addParameter(linkedinPageURLToShare, "url", shareURL)> 
254								<#assign linkedinPageURLToShare = httpUtil.addParameter(linkedinPageURLToShare, "title", articleTitle)> 
255								<#assign linkedinPageURLToShare = httpUtil.addParameter(linkedinPageURLToShare, "summary", "Infarmed")> 
256								 
257								<#assign emailToURLToShare = "mailto:?subject="> 
258								<#assign emailToURLToShare = emailToURLToShare + httpUtil.encodeURL(articleTitle, true)> <#-- Não seguiu a abordagem anterior porque o encode dos espaços fica com '+' em vez de '%20' -->						 
259								<#assign emailToURLToShare = emailToURLToShare + "&body=" + httpUtil.encodeURL(shareURL, true)> 
260								 
261								<span class="label-text"><@liferay.language key="share" /></span> 
262								<ul> 
263									<li><a href="${fbPageURLToShare}" title="Facebook" target="_blank"><div class="fa fa-facebook"></div></a></li> 
264									<li><a href="${linkedinPageURLToShare}" title="LinkedIn" target="_blank"><div class="fa fa-linkedin"></div></a></li> 
265									<li><a href="${twitterPageURLToShare}" title="Twitter" target="_blank"><div class="fa fa-twitter"></div></a></li> 
266									<li><a href="${emailToURLToShare}" title="E-mail"><div class="fa fa-envelope-o"></div></a></li> 
267								</ul> 
268							</div> 
269						</div> 
270					</#if> 
271				</div> 
272			</div> 
273		</div> 
274	</div> 
275	<div class="container-medium "> 
276		<div class="event-detail-body "> 
277			<div class="cms-editor "> 
278			    <#if hasSubtitulo> 
279			        <p><strong>${Subtitulo.getData()}</strong></p> 
280			    </#if> 
281				<p>${Corpo_do_conteudo.getData()} 
282				</p> 
283			</div> 
284			 
285			<#if Separador.getSiblings()?size lte 1> 
286				<#assign hasAnexoSingleSeparador = Separador.get("Anexo")?? && Separador.get("Anexo").getSiblings()?has_content && Separador.get("Anexo").getSiblings()[0].getData()?has_content> 
287				<#if hasAnexoSingleSeparador> 
288					<section class="section "> 
289						<header class="section-header "> 
290							<#if Separador.getData()?has_content> 
291								<h2 class="title black ">${Separador.getData()}</h2> 
292							<#else> 
293								<h2 class="title black ">Anexos</h2> 
294							</#if> 
295							 
296						</header> 
297						<div class="section-content "> 
298								<ul class="list-links"> 
299									<#list Separador.get("Anexo").getSiblings() as cur_Anexo> 
300										<#if cur_Anexo?? && cur_Anexo.getData()?has_content && cur_Anexo.getData() != ""> 
301											<#assign GetterUtil = staticUtil["com.liferay.portal.kernel.util.GetterUtil"]/> 
302											<#assign DLFileEntryLocalService = serviceLocator.findService("com.liferay.portlet.documentlibrary.service.DLFileEntryLocalService")> 
303											<#assign docAttrs = cur_Anexo.getData()?split("/")> 
304											<#assign groupId = docAttrs[2]> 
305											<#if docAttrs[5]?index_of("?") != -1> 
306												<#assign uuid = docAttrs[5]?substring(0, docAttrs[5]?index_of("?"))> 
307											<#else> 
308												<#assign uuid = docAttrs[5]> 
309											</#if> 
310											<#if DLFileEntryLocalService.getFileEntryByUuidAndGroupId(uuid, GetterUtil.getLong(groupId))??> 
311												<#assign entry = DLFileEntryLocalService.getFileEntryByUuidAndGroupId(uuid, GetterUtil.getLong(groupId))> 
312										 
313												<#assign anexoDesc = entry.getDescription()> 
314												<li> 
315													<a href="${cur_Anexo.getData()}" target="_blank"> 
316														<#if cur_Anexo.get("Nome_a_apresentar")?? && cur_Anexo.get("Nome_a_apresentar").getData()?has_content> 
317															${cur_Anexo.get("Nome_a_apresentar").getData()} 
318														<#else> 
319															${anexoDesc} 
320														</#if> 
321													</a> 
322												</li> 
323											</#if> 
324										</#if> 
325									</#list> 
326								</ul> 
327						</div> 
328					</section> 
329				</#if> 
330			<#else> 
331				<div class="tabbable" id="${randomNamespace}Tabbable"> <!-- Only required for left/right tabs --> 
332					<ul class="nav nav-tabs" id="${randomNamespace}TabbedContent"> 
333						<#if Separador.getSiblings()?has_content> 
334							<#list Separador.getSiblings() as cur_Tab> 
335								<#if cur_Tab_index==0> 
336									<li class="active"> 
337								<#else> 
338									<li> 
339								</#if> 
340										<a href="#${randomNamespace}tab${cur_Tab_index}" data-toggle="tab">${cur_Tab.getData()}</a> 
341									</li> 
342							</#list> 
343						</#if> 
344					</ul> 
345 
346					<div class="tab-content ${randomNamespace + "showOverflow"}"> 
347						<#if Separador.getSiblings()?has_content> 
348							<#list Separador.getSiblings() as cur_Tab> 
349								<#assign active = ""> 
350								<#if cur_Tab_index==0> 
351									<#assign active = "active"> 
352								</#if> 
353								<#assign tabID = randomNamespace + "tab" + cur_Tab_index> 
354								<div class="tab-pane ${active}" id="${tabID}"> 
355									<@drawTabContent cur_Tab tabID/> 
356								</div> 
357							</#list> 
358						</#if> 
359					</div> 
360				</div> 
361			</#if> 
362			<#if displayTags> 
363				<@drawTags/> 
364			</#if> 
365		</div> 
366		<div class="page-bottom-actions "> 
367			<a href="javascript:window.history.back();" class="back "> 
368			    <div class="fa fa-angle-left " aria-hidden="true "></div> Voltar 
369			</a> 
370		</div> 
371	</div> 
372</div> 
373 
374<script> 
375	$( document ).ready(function() { 
376		$('#${randomNamespace}TabbedContent a').click(function (e) { 
377			e.preventDefault(); 
378			$(this).tab('show'); 
379		}) 
380	}); 
381</script> 
382 
383<script src="https://maxcdn.bootstrapcdn.com/twitter-bootstrap/2.3.2/js/bootstrap.min.js"></script>  
384 
385<#macro drawTabContent tab tabID> 
386	<div class="section-content "> 
387		<#assign hasAnexo = tab.get("Anexo")?? && tab.get("Anexo").getSiblings()?has_content && tab.get("Anexo").getSiblings()[0].getData()?has_content> 
388        <#if hasAnexo> 
389			<ul class="list-links"> 
390				<#list tab.get("Anexo").getSiblings() as cur_Anexo> 
391					<#if cur_Anexo?? && cur_Anexo.getData()?has_content && cur_Anexo.getData() != ""> 
392						<#assign GetterUtil = staticUtil["com.liferay.portal.kernel.util.GetterUtil"]/> 
393						<#assign DLFileEntryLocalService = serviceLocator.findService("com.liferay.portlet.documentlibrary.service.DLFileEntryLocalService")> 
394						<#assign docAttrs = cur_Anexo.getData()?split("/")> 
395						<#assign groupId = docAttrs[2]> 
396						<#if docAttrs[5]?index_of("?") != -1> 
397							<#assign uuid = docAttrs[5]?substring(0, docAttrs[5]?index_of("?"))> 
398						<#else> 
399							<#assign uuid = docAttrs[5]> 
400						</#if> 
401						<#if DLFileEntryLocalService.getFileEntryByUuidAndGroupId(uuid, GetterUtil.getLong(groupId))??> 
402							<#assign entry = DLFileEntryLocalService.getFileEntryByUuidAndGroupId(uuid, GetterUtil.getLong(groupId))> 
403					 
404							<#assign anexoDesc = entry.getDescription()> 
405							<li> 
406								<a href="${cur_Anexo.getData()}" target="_blank"> 
407									<#if cur_Anexo.get("Nome_a_apresentar")?? && cur_Anexo.get("Nome_a_apresentar").getData()?has_content> 
408										${cur_Anexo.get("Nome_a_apresentar").getData()} 
409									<#else> 
410										${anexoDesc} 
411									</#if> 
412								</a> 
413							</li> 
414						</#if> 
415					</#if> 
416				</#list> 
417			</ul> 
418		</#if> 
419	</div> 
420</#macro> 
421 
422<#macro drawTags> 
423	<#if request['theme-display']??> 
424		<#assign journalArticleService = serviceLocator.findService("com.liferay.portlet.journal.service.JournalArticleLocalService") > 
425		<#assign assetEntryService = serviceLocator.findService("com.liferay.portlet.asset.service.AssetEntryLocalService")> 
426		<#assign assetTagService = serviceLocator.findService("com.liferay.portlet.asset.service.AssetTagLocalService")> 
427		 
428		<#assign journalArticleObject = journalArticleService.fetchArticle(scopeGroupId?number, articleID, articleVersion?number)> 
429 
430		<#assign entryObject = assetEntryService.getEntry("com.liferay.portlet.journal.model.JournalArticle", journalArticleObject.getResourcePrimKey())> 
431		<#assign articleTags = assetTagService.getAssetEntryAssetTags(entryObject.getEntryId())> 
432				 
433		<#if articleTags?has_content> 
434			<section class="section "> 
435				<header class="section-header "> 
436					<h2 class="title "><@liferay.language key="topics" /></h2> 
437				</header> 
438				<div class="section-content "> 
439					<ul id="${randomNamespace}contentTagsList" class="topic-list contentTagsList" style="max-height:6em; overflow-y:hidden; padding-right: 10px;"> 
440						<div id="${randomNamespace}tagsCarret" class="hidden tagsCarret fa fa-caret-down fa-2x" aria-hidden="true"></div> 
441						<#list articleTags as articleTag> 
442							<#assign tagSearchURL = "?p_p_id=3&p_p_lifecycle=0&p_p_state=maximized&p_p_mode=view&_3_struts_action=%2Fsearch%2Fsearch&_3_assetTagNames=" + articleTag.getName()> 
443							<li><a href="${currentBaseURL}${tagSearchURL}" class="button rounded small">${articleTag.getName()}</a></li> 
444						</#list> 
445					</ul> 
446				</div> 
447			</section>		 
448 
449			<script> 
450				$(document).ready(function() { 
451					var contentTags = $("#${randomNamespace}contentTagsList"); 
452					var tagsCarrets = $("#${randomNamespace}tagsCarret"); 
453			 
454					if(contentTags.overflown()) { 
455						tagsCarrets.removeClass("hidden"); 
456
457					 
458					tagsCarrets.click(function(){ 
459						if($(this).hasClass('fa-caret-down')){ 
460							$(this).removeClass('fa-caret-down'); 
461							$(this).addClass('fa-caret-up'); 
462						} else{ 
463							$(this).removeClass('fa-caret-up'); 
464							$(this).addClass('fa-caret-down'); 
465
466						if(this.parentElement.style.maxHeight == 'none' ){ 
467							this.parentElement.style.maxHeight = '6em'; 
468						} else{ 
469							this.parentElement.style.maxHeight = 'none'; 
470
471					}); 
472				}); 
473			</script>			 
474		</#if> 
475	</#if> 
476</#macro>