Se ha producido un error al procesar la plantilla.
Java method "com.liferay.portal.kernel.util.DateUtil_IW.getDate(Date, String, Locale)" threw an exception when invoked on com.liferay.portal.kernel.util.DateUtil_IW object "com.liferay.portal.kernel.util.DateUtil_IW@6ef2a703"; see cause exception in the Java stack trace.

----
FTL stack trace ("~" means nesting-related):
	- Failed at: ${dateUtil.getDate(endDate_Data, form...  [in template "842907#842945#35142" at line 514, column 37]
	- Reached through: #assign dates = dates + ["${dateUtil...  [in template "842907#842945#35142" in function "getDateText" at line 514, column 9]
	- Reached through: #assign dateTexts = dateTexts + [getD...  [in template "842907#842945#35142" at line 63, column 5]
----
1<!-- SERVICES --> 
2<#assign assetHelperLocalService = serviceLocator.findService("net.bizkaia.bipo.core.utils.service.AssetHelperLocalService")> 
3<#assign journalArticleLocalService = serviceLocator.findService("com.liferay.journal.service.JournalArticleLocalService")> 
4<#assign assetCategoryLocalService = serviceLocator.findService("com.liferay.asset.kernel.service.AssetCategoryLocalService") > 
5<#assign assetEntryLocalService = serviceLocator.findService("com.liferay.asset.kernel.service.AssetEntryLocalService")> 
6<#assign assetLinkLocalService = serviceLocator.findService("com.liferay.asset.kernel.service.AssetLinkLocalService") /> 
7<#assign dDMStructureLocalService = serviceLocator.findService("com.liferay.dynamic.data.mapping.service.DDMStructureLocalService") /> 
8<#assign fileEntryService = serviceLocator.findService("com.liferay.document.library.kernel.service.DLFileEntryLocalService") > 
9<#assign structureLocalService = serviceLocator.findService("com.liferay.dynamic.data.mapping.service.DDMStructureLocalService")> 
10<#assign classNameLocalService = serviceLocator.findService("com.liferay.portal.kernel.service.ClassNameLocalService")> 
11 
12 
13<#assign serviceContext = staticUtil["com.liferay.portal.kernel.service.ServiceContextThreadLocal"].getServiceContext()> 
14     
15<#assign urlEncoder = staticUtil["java.net.URLEncoder"]> 
16<#assign textFormatter = staticUtil["com.liferay.portal.kernel.util.TextFormatter"]> 
17 
18<!-- VARIABLES --> 
19<#assign articleId = .vars['reserved-article-id'].data > 
20<#assign articleTitle = .vars['reserved-article-title'].data > 
21<#assign journalArticle = journalArticleLocalService.getArticle(articleGroupId, articleId) > 
22<#assign articlePK = journalArticle.getResourcePrimKey() > 
23<#assign journalArticleClassName = "com.liferay.journal.model.JournalArticle"> 
24<#assign classNameId = classNameLocalService.getClassNameId(journalArticleClassName)> 
25<#assign vocabularyScheduleRegionId = propsUtil.get("bipo.vocabulary.scheduleRegion")> 
26 
27<#if request?has_content> 
28    <#assign portletNamespace = request["theme-display"]["portlet-display"]["id"] + "_" > 
29   <#assign completeCurrentUrl = urlEncoder.encode((request["attributes"]["CURRENT_COMPLETE_URL"])?string?split("?")[0]?string, "UTF-8")> 
30 <#assign pathThemeImages = themeDisplay.getPathThemeImages()> 
31     
32    <#assign imagesPath = request['theme-display']['path-theme-images']> 
33<#else> 
34    <#assign portletNamespace = articleId + '_'> 
35    <#assign completeCurrentUrl = 'http://web.bizkaia.eus'> 
36    <#assign imagesPath = '/bipo-bizkaia-eus-theme/images'> 
37</#if> 
38 
39<#assign encodedTitle = urlEncoder.encode(articleTitle, "UTF-8")> 
40 
41 
42<#assign structure = structureLocalService.getStructure(company.groupId, classNameId, journalArticle.structureId) > 
43 
44<#assign categories = assetCategoryLocalService.getCategories(journalArticleClassName, articlePK) /> 
45 
46<#assign categoryNames = []> 
47<#assign categoryIds = []> 
48<#list categories as category> 
49    <#if validator.equals(category.vocabularyId?string,vocabularyScheduleRegionId?string)> 
50    <#assign categoryNames = categoryNames + [ "${category.getTitle(locale)}" ] /> 
51    <#assign categoryIds = categoryIds + [ category.categoryId ] /> 
52  </#if> 
53</#list> 
54 
55<#assign format = []> 
56<#assign format = format + ["dd"] > 
57<#assign format = format + ["MM"] > 
58<#assign format = format + ["yyyy"] > 
59<#assign dateFormat = languageUtil.format(locale, "dateFormat.dd-mm-yyyy", format)> 
60<#assign dateTexts = []> 
61<#assign dateTimes = []> 
62<#list dates.getSiblings() as date> 
63    <#assign dateTexts = dateTexts + [getDateText(date.startDate.getData(), date.endDate.getData(), date.allDay.getData(), dateFormat)]> 
64    <#assign dateTimes = dateTimes + [date.eventTime]> 
65</#list> 
66 
67<!--RELATED ASSETS--> 
68<#assign journalArticleAssetEntry = assetEntryLocalService.getEntry("com.liferay.journal.model.JournalArticle", articlePK) /> 
69<#assign journalArticleAssetEntryId = journalArticleAssetEntry.getEntryId() /> 
70<#assign journalArticleRelatedLinks = assetLinkLocalService.getDirectLinks(journalArticleAssetEntryId) /> 
71 
72<#assign espaciosStructureId = propsUtil.get("bipo.estructure.espacios")> 
73<#assign espaciosStructure = dDMStructureLocalService.getDDMStructure(espaciosStructureId?number)> 
74<#assign related_articles = []> 
75<#list journalArticleRelatedLinks as related_entry> 
76    <#assign relatedAssetEntryId = related_entry.getEntryId2() /> 
77    <#assign relatedAssetEntry = assetEntryLocalService.getEntry(relatedAssetEntryId) /> 
78    <#assign renderer = relatedAssetEntry.getAssetRenderer()> 
79    <#assign relatedArticle = renderer.getArticle() > 
80    <#assign relatedArticleStructureId = relatedArticle.getStructureId() /> 
81     
82    <#if validator.equals(relatedArticleStructureId, espaciosStructure.getStructureKey())> 
83        <#assign related_articles = related_articles + [relatedArticle]> 
84    </#if> 
85</#list> 
86 
87 
88 
89<script src="${httpUtil.getProtocol(completeCurrentUrl)}://connect.facebook.net/${locale}/all.js#xfbml=1"></script> 
90 
91<div class="bipo_gurebizkaia_detalle bg_gray"> 
92  <div class="container"> 
93        <div class="row"> 
94            <div class="col-xxs-12 col-xxs-offset-0 col-xs-10 col-xs-offset-1 col-sm-10 col-sm-offset-1 col-md-offset-1 col-md-10"> 
95                <h1><span>${articleTitle}</span></h1> 
96            </div> 
97        </div> 
98    </div> 
99    <!-- Redes sociales, entradilla, contenido 1 y audio -->           
100    <div class="container"> 
101        <div class="row"> 
102            <#if !validator.equals("", eventImage.getData())> 
103            <div class="col-xxs-12 col-xxs-offset-0 col-xs-10 col-xs-offset-1 col-sm-10 col-sm-offset-1 col-md-8 col-md-offset-1"> 
104              <img src="${eventImage.getData()}" alt="${htmlUtil.escape(eventImage.getChild('alt').getData())}"> 
105            </div> 
106            </#if> 
107         
108            <div class="info-derecha col-xxs-12 col-xxs-offset-0 col-xs-10 col-xs-offset-1 col-sm-10 col-sm-offset-1 col-md-3 col-md-offset-0"> 
109                <div class="bipo_detalle_info"> 
110                    <ul class="row"> 
111                         
112                        <#if dateTexts?has_content> 
113                          <#list dateTexts as dateText> 
114                            <li class="col-xxs-6 col-xs-6 col-sm-6 col-md-12"> 
115                                <p><span class="bipoicon icon-calendario_02"></span><@liferay.language key="gbi-agenda-detalle.when" /></p> 
116                                <p>${dateText}</p> 
117                            </li> 
118                            <#if dateTimes[dateText_index]?has_content && !validator.equals("", dateTimes[dateText_index].getData())> 
119                              <li class="col-xxs-6 col-xs-6 col-sm-6 col-md-12"> 
120                                <p><span class="bipoicon icon-clock"></span><@liferay.language key="hour" /></p> 
121                                <p>${dateTimes[dateText_index].getData()}</p> 
122                              </li> 
123                            </#if> 
124                          </#list> 
125                        </#if> 
126                        <#if related_articles?has_content> 
127                            <li class="col-xxs-6 col-xs-6 col-sm-6 col-md-12"> 
128                                <p><span class="bipoicon icon-localizador"></span><@liferay.language key="gbi-agenda-detalle.where" /></p> 
129                                <p> 
130                                    <#list related_articles as related_article> 
131                                        <#assign espacioViewURL = related_article.getUrlTitle() > 
132                                        <#assign espacioTitle = related_article.getTitle(locale)> 
133                                         
134                                        <a href="${espacioViewURL}">${espacioTitle}</a> 
135                                        <#if related_articles?last != related_article> 
136                                            <br /> 
137                                        </#if> 
138                                    </#list> 
139                                </p> 
140                            </li> 
141                        </#if> 
142                        <#if !validator.equals("", eventWeb.getData())> 
143                            <#assign targetTitle = getTitle(eventWeb.getChild('target').getData()) /> 
144                             
145              <li class="col-xxs-6 col-xs-6 col-sm-6 col-md-12"> 
146                <p><span class="bipoicon icon-link"></span><@liferay.language key="gbi-agenda-detalle.web" /></p> 
147                <p><a href="${eventWeb.getData()}" target="${getTarget(eventWeb.getChild('target').getData())}" ${targetTitle}><@liferay.language key="gbi-agenda-detalle.to-visit" /></a></p> 
148              </li> 
149                        </#if> 
150                    </ul> 
151                </div> 
152            </div> 
153             
154             
155            <div class="col-xxs-12 col-xxs-offset-0 col-xs-10 col-xs-offset-1 col-sm-10 col-sm-offset-1 col-md-8 col-md-offset-1"> 
156                <div class="bg_white"> 
157                    <div class="row"> 
158                        <div class="col-xxs-12 col-xxs-offset-0 col-xs-10 col-xs-offset-1 col-sm-10 col-sm-offset-1 col-md-10 col-md-offset-2"> 
159                             <#if !validator.equals("0", categoryNames?size?string)> 
160                    <p class="bipo_detalle_categoria"> 
161                  <#list categoryNames as curCategory > 
162                    <#if !validator.equals("", curCategory)> 
163                      ${curCategory} 
164                    </#if> 
165                  </#list> 
166                    </p> 
167                </#if> 
168                        </div> 
169                    </div> 
170                    <div class="row"> 
171                        <div class="hidden-xxs col-md-1 col-md-offset-1 bipo_container_social"> 
172                            <@social /> 
173                        </div> 
174                        <div class="col-xxs-10 col-xxs-offset-1 col-xs-10 col-xs-offset-1 col-sm-10 col-sm-offset-1 col-md-10 col-md-offset-0"> 
175                            <div class="row"> 
176                                <div class="col-md-10 bipo_contenido"> 
177                                    ${body.getData()}       
178                                </div> 
179                            </div> 
180              <!-- Tabs Información / Observaciones y Localización --> 
181              <div class="bipo_info_tabs row"> 
182                <div class="col-md-12"> 
183                  <ul class="bipo_tabs" role="tablist"> 
184                    <#assign tabActive = false> 
185                    <#if !validator.equals("",information.getChild('schedule').getData()) || !validator.equals("", information.getChild('document').getSiblings()?first.getData()) || !validator.equals("", information.getChild('moreInformation').getData())>                            <#assign tabActive = true > 
186                      <li class="active" id="${portletNamespace}bipo_enlace_informacion"> 
187                        <a href="#${portletNamespace}tab_informacion" aria-controls="${portletNamespace}tab_informacion" class="" role="tab" data-toggle="tab" aria-expanded="false"><@liferay.language key="gbi-agenda-detalle.information" /></a> 
188                      </li> 
189                    </#if> 
190                    <#if !validator.equals("", observations.getData())> 
191                      <#if tabActive> 
192                        <li class="" id="${portletNamespace}bipo_enlace_observacion"> 
193                      <#else> 
194                        <li class="active" id="${portletNamespace}bipo_enlace_observacion"> 
195                          <#assign tabActive = true> 
196                      </#if> 
197                          <a href="#${portletNamespace}tab_observaciones" aria-controls="${portletNamespace}tab_observaciones" role="tab" data-toggle="tab" aria-expanded="true"><@liferay.language key="gbi-agenda-detalle.observations" /></a> 
198                        </li> 
199                    </#if> 
200                    <#if !validator.equals("", locationAddress.getData())> 
201                      <#if tabActive> 
202                        <li class="" id="${portletNamespace}bipo_enlace_localizacion"> 
203                      <#else> 
204                        <li class="active" id="${portletNamespace}bipo_enlace_localizacion"> 
205                      </#if> 
206                          <a href="#${portletNamespace}tab_localizacion" aria-controls="${portletNamespace}tab_localizacion" role="tab" data-toggle="tab" aria-expanded="true"><@liferay.language key="gbi-agenda-detalle.location" /></a> 
207                        </li> 
208                    </#if> 
209                  </ul> 
210                </div> 
211                <div class="row"> 
212                  <div class="col-md-10 bipo_contenido"> 
213                    <div class="tab-content"> 
214                      <#assign tabActive = false> 
215                      <#if !validator.equals("",information.getChild('schedule').getData()) || !validator.equals("", information.getChild('document').getSiblings()?first.getData()) || !validator.equals("",information.getChild('moreInformation').getData())>                           <#assign tabActive = true> 
216                        <div class="tab-pane fade in active" role="tabpanel" id="${portletNamespace}tab_informacion"> 
217                          <#if !validator.equals("",information.getChild('schedule').getData())> 
218                            <div class="bipo_descargas"> 
219                              <h2 class="bipo_titulo"><@liferay.language key="gbi-agenda-detalle.schedule" /></h2> 
220                              ${information.getChild('schedule').getData()} 
221                            </div> 
222                          </#if> 
223                             
224                          <#if !validator.equals("", information.getChild('document').getSiblings()?first.getData())>  
225                            <div class="bipo_descargas"> 
226                              <h2 class="bipo_titulo"><@liferay.language key="gbi-agenda-detalle.downloads" /></h2> 
227                              <ul> 
228                                <#list information.getChild('document').getSiblings() as curDocument> 
229                                  <#if !validator.equals("", curDocument.getData())> 
230                                    <#assign fileEntry = getFileEntry(curDocument.getData()) > 
231                                    <#assign size = textFormatter.formatStorageSize(fileEntry.size, locale) > 
232                                    <li> 
233                                      <span class="bipoicon icon-descargar"></span> 
234                                      <a href="${curDocument.getData()}" target="_blank" title="<@liferay.language key='opens-new-window' />"> 
235                                        ${fileEntry.title} 
236                                        <span>(${fileEntry.extension}, ${size})</span> 
237                                      </a> 
238                                    </li> 
239                                  </#if> 
240                                </#list> 
241                              </ul> 
242                            </div> 
243                          </#if> 
244                          <#if !validator.equals("", information.getChild('moreInformation').getData())> 
245                            <div class="bipo_sumario"> 
246                              <h2 class="bipo_titulo"><@liferay.language key="gbi-agenda-detalle.more-information" /></h2> 
247                              ${information.getChild('moreInformation').getData()} 
248                            </div> 
249                          </#if> 
250                        </div> 
251                      </#if> 
252                           
253                      <#if !validator.equals("", observations.getData())> 
254                        <#if tabActive > 
255                          <div class="tab-pane fade" role="tabpanel" id="${portletNamespace}tab_observaciones"> 
256                        <#else> 
257                          <div class="tab-pane fadein active" role="tabpanel" id="${portletNamespace}tab_observaciones"> 
258                            <#assign tabActive = true> 
259                        </#if> 
260                            ${observations.getData()} 
261                          </div> 
262                      </#if> 
263                           
264                      <#if !validator.equals("", locationPlace.getData()) && !validator.equals("", locationAddress.getData())> 
265                        <#if tabActive > 
266                          <div class="tab-pane fade" role="tabpanel" id="${portletNamespace}tab_localizacion"> 
267                        <#else> 
268                          <div class="tab-pane fade in active" role="tabpanel" id="${portletNamespace}tab_localizacion"> 
269                            <#assign tabActive = true> 
270                        </#if> 
271                            <div id="${portletNamespace}map" style="height:400px;width:100%"></div> 
272                          </div> 
273                      </#if> 
274                    </div> 
275                  </div> 
276                </div> 
277              </div> 
278 
279            </div> 
280          </div> 
281          <div class="visible-xxs col-xxs-10 col-xxs-offset-1 hidden-xs hidden-sm hidden-md hidden-lg"> 
282            <@social /> 
283          </div> 
284          <!-- Fin Contenido 2 y sumario --> 
285             
286        </div> 
287    </div> 
288     
289  <div class="container"> 
290      </div> 
291    </div> 
292    <@showRelated /> 
293  </div> 
294</div> 
295 
296<#macro social> 
297  <div class="m-redes_sociales"> 
298    <ul> 
299        <li> 
300            <div class="taglib-social-bookmark-facebook" > 
301                    <div class="fb-like" data-href="${completeCurrentUrl}" data-layout="box_count" data-action="like" data-show-faces="false" data-share="false"></div> 
302                </div> 
303        </li> 
304      <li> 
305        <a class="facebook" href="http://www.facebook.com/sharer/sharer.php?u=${completeCurrentUrl}" target="_blank" title="<@liferay.language key='opens-new-window' />"> 
306          <span class="sr-only"><@liferay.language key="share-facebook" /></span><span class="bipoicon icon-facebook"></span> 
307        </a> 
308      </li> 
309      <li> 
310        <a class="twitter twitter-share-button" href="https://twitter.com/intent/tweet?url=${completeCurrentUrl}&text=${encodedTitle}" target="_blank" title="<@liferay.language key='opens-new-window' />" data-size="large"> 
311          <span class="sr-only"><@liferay.language key="share-twitter" /></span><span class="bipoicon icon-twitter"></span> 
312        </a> 
313      </li> 
314      <li> 
315        <a class="googleplus" href="https://plus.google.com/share?url=${completeCurrentUrl}" target="_blank" title="<@liferay.language key='opens-new-window' />" onclick="javascript:window.open(this.href, '', 'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=600,width=600');return false;"> 
316            <span class="sr-only"><@liferay.language key="share-google-plus" /></span><span class="bipoicon icon-google-plus"></span> 
317        </a> 
318      </li> 
319      <li> 
320        <a class="whatsapp" href="whatsapp://send?text=${completeCurrentUrl}" target="_blank" title="<@liferay.language key='opens-new-window' />"> 
321          <span class="sr-only"><@liferay.language key="share-whatsapp" /></span><span class="bipoicon icon-whatsapp"></span> 
322        </a> 
323      </li> 
324    </ul> 
325  </div> 
326</#macro> 
327 
328<#macro showRelated> 
329    <#if !validator.equals("0", categoryIds?size?string) > 
330        <#assign assetEntryQuery = assetHelperLocalService.createAssetEntryQuery() /> 
331        ${assetEntryQuery.setClassTypeIds([getterUtil.getLong(structure.structureId)])} 
332        ${assetEntryQuery.setAllCategoryIds(categoryIds)} 
333         
334        ${assetEntryQuery.setOrderByCol1("ddm/" + structure.structureId + "/important")} 
335        ${assetEntryQuery.setOrderByType1("DESC")} 
336        ${assetEntryQuery.setOrderByCol2("ddm/" + structure.structureId + "/startDate")} 
337        ${assetEntryQuery.setOrderByType2("DESC")} 
338         
339        <#assign httpServletRequest = serviceContext.getRequest()> 
340         
341         
342        <#assign hits = assetHelperLocalService.assetUtilSearch(httpServletRequest, assetEntryQuery, 0, 4)> 
343        <#assign results = assetHelperLocalService.assetUtilGetAssetEntries(hits) > 
344         
345        <#assign maxRelated = results?size > 
346        <#if maxRelated gt 3> 
347            <#assign maxRelated = 3 /> 
348        </#if> 
349         
350        <#assign numRelated = 0> 
351         
352        <#if !validator.equals("1", maxRelated?string) > 
353            <div class="bg_white"> 
354               
355         
356                  <div class="row"> 
357                      <div class="col-xxs-12 col-xxs-offset-0 col-xs-10 col-xs-offset-1 col-sm-10 col-sm-offset-1 col-md-12 col-md-offset-0"> 
358                          <div class="bipo_borde_inferior_b"> 
359                              <h2> <span><@liferay.language key="gbi-agenda-detalle.plus" /></span></h2> 
360                          </div> 
361                      </div> 
362         
363                  </div> 
364                  <div class="row"> 
365                       <div class="col-xxs-12 col-xxs-offset-0 col-xs-10 col-xs-offset-1 col-sm-10 col-sm-offset-1 col-md-12 col-md-offset-0"> 
366                          <div class="bipo_listagenda"> 
367                              <ul> 
368                                  <#list results as entry> 
369                                      <#assign title = entry.getTitle(locale)  /> 
370                                      <#assign renderer = entry.getAssetRenderer()> 
371                                      <#assign className = renderer.getClassName() > 
372         
373                                      <#if validator.equals(className?string, journalArticleClassName) > 
374                                          <#assign journalArticle = renderer.getArticle() > 
375                                          <#assign document = saxReaderUtil.read(journalArticle.getContentByLocale(locale)) > 
376                                          <#assign rootElement = document.getRootElement() > 
377                                            <#assign image = "", alt="", place = "", allDates = []> 
378                                             
379                                           
380                                            <#assign place = saxReaderUtil.createXPath("dynamic-element[@name='locationPlace']/dynamic-content").selectSingleNode(rootElement).getStringValue()  > 
381                                            <#assign image = saxReaderUtil.createXPath("dynamic-element[@name='eventImage']/dynamic-content").selectSingleNode(rootElement).getStringValue()  > 
382                                            <#assign alt = saxReaderUtil.createXPath("dynamic-element[@name='eventImage']/dynamic-element[@name='alt']/dynamic-content").selectSingleNode(rootElement).getStringValue()  > 
383                                            <#assign allStarDates = saxReaderUtil.createXPath("dynamic-element[@name='dates']/dynamic-element[@name='startDate']/dynamic-content").selectNodes(rootElement)  > 
384				                        	<#assign allEndDates = saxReaderUtil.createXPath("dynamic-element[@name='dates']/dynamic-element[@name='endDate']/dynamic-content").selectNodes(rootElement)  > 
385					                        <#assign allAllDays = saxReaderUtil.createXPath("dynamic-element[@name='dates']/dynamic-element[@name='allDay']/dynamic-content").selectNodes(rootElement)  > 
386 
387                                             
388                                            <#assign dateTexts = []> 
389                                            <#assign dateTimes = []> 
390                                            <#list allStarDates as startDate> 
391                                              <#assign dateTexts = dateTexts + [getDateText(startDate.getStringValue(), allEndDates[startDate_index].getStringValue(), allAllDays[startDate_index].getStringValue(), "dd/MM/yyyy")]> 
392                                            </#list> 
393                                             
394                                            <#if request?has_content> 
395                                              <#assign viewURL = assetHelperLocalService.getURLViewInContext(journalArticle, themeDisplay) > 
396                                            <#else> 
397                                                <#assign viewURL = 'http://web.bizkaia.eus'> 
398                                            </#if> 
399                                             
400                                          <#assign categories = assetCategoryLocalService.getCategories(className, journalArticle.resourcePrimKey) > 
401                                          <#assign categoryNames = []> 
402                                    <#list categories as category> 
403                                      <#if validator.equals(category.vocabularyId?string,vocabularyScheduleRegionId?string)> 
404                                        <#assign categoryNames = categoryNames + [ "${category.getTitle(locale)}" ] /> 
405                                      </#if> 
406                                    </#list> 
407                                      </#if> 
408         
409                                      <#if !validator.equals(journalArticle.getArticleId()?string, articleId?string)> 
410                                          <#if validator.equals(numRelated?string, maxRelated?string)> 
411                                              <#break> 
412                                          </#if> 
413                                           
414                                          <li class="col-xxs-12 col-xs-6 col-sm-6 col-md-4"> 
415                                              <div class="bipo_contentagenda"> 
416                                                  <div class="bipo_img"> 
417                                                     <!-- <a href="${viewURL}"><img src="${image}" alt='${htmlUtil.escape(alt)}'></a> --> 
418                                                      <a href="${viewURL}"><img src="${image}" alt='${htmlUtil.escape(title)}'></a> 
419                                                  </div> 
420         
421                                                    <#if !validator.equals("0", categoryNames?size?string)> 
422                                                  <p class="bipo_categoria"> 
423                                                      <#list categoryNames as category> 
424                                                          ${category}  
425                                                      </#list> 
426                                                  </p> 
427                                                  </#if> 
428         
429                                                  <h3 class="bipo_titagenda"> 
430                                                      <a href="${viewURL}">${title}</a>  
431                                                  </h3> 
432         
433                                                  <div class="bipo_hora_lugar"> 
434                                                    <ul> 
435                                                          <#if !validator.equals("", place)> 
436                                                            <li> 
437                                                                <span class="bipoicon icon-localizador"> 
438                                                                    <span class="sr-only"><@liferay.language key="place" /></span> 
439                                                                </span>${place} 
440                                                            </li> 
441                                                          </#if> 
442                                                          <#if dateTexts?has_content> 
443                                                            <#list dateTexts as dateText> 
444                                                              <li> 
445                                                                <span class="bipoicon icon-calendario_02"> 
446                                                                  <span class="sr-only"><@liferay.language key="date" /></span> 
447                                                                </span>  
448                                                                <#if !validator.equals("",dateText)> 
449                                                                  ${dateText} 
450                                                                </#if> 
451                                                                <#if dateTimes[dateText_index]?has_content> 
452                                                                  - ${dateTimes[dateText_index].getData()} 
453                                                                </#if> 
454                                                              </li> 
455                                                            </#list> 
456                                                          </#if> 
457                                                    </ul> 
458                              </div> 
459                                              </div> 
460                                          </li> 
461                                          <#assign numRelated = numRelated + 1 /> 
462                                      </#if> 
463                                  </#list> 
464                              </ul> 
465                          </div> 
466                      </div> 
467                   
468            </div> 
469          </div> 
470        </#if> 
471    </#if> 
472</#macro> 
473 
474<#function getFileEntry url > 
475  <#assign parts = url?split("/")> 
476   
477  <#assign group_id = getterUtil.getLong(parts[2]) /> 
478   
479  <#assign parts = parts[5]?split("?") /> 
480  <#assign uuid = parts[0] /> 
481   
482  <#return fileEntryService.getDLFileEntryByUuidAndGroupId(uuid?string, group_id) /> 
483</#function> 
484 
485<#function getDateText startDate endDate allDay format> 
486     
487    <#assign dates = []> 
488    <#assign dateText = ""> 
489     
490    <#if validator.isNotNull(startDate)> 
491    	<#assign startDate_Data = dateUtil.parseDate("yyyy-MM-dd", startDate, locale)> 
492    </#if> 
493    <#if validator.isNotNull(endDate)> 
494    	<#assign endDate_Data = dateUtil.parseDate("yyyy-MM-dd", endDate, locale)> 
495    </#if> 
496 
497    <#if getterUtil.getBoolean(allDay)> 
498         
499        <#assign dateText = dateUtil.getDate(startDate_Data, format, locale) > 
500    <#elseif (!validator.equals("0", startDate?string)) && (validator.equals("0", endDate?string)) > 
501         
502         
503        <#assign dates = dates + [ '${dateUtil.getDate(startDate_Data, format, locale)}' ] > 
504                   
505      <#assign dateText = languageUtil.format(locale, "from-date", dates) > 
506    <#elseif (validator.equals("0", startDate?string)) && (!validator.equals("0", endDate?string)) > 
507         
508        <#assign dates = dates + [ '${dateUtil.getDate(endDate_Data, format, locale)}' ] > 
509                   
510      <#assign dateText = languageUtil.format(locale, "to-date", dates) > 
511    <#elseif (!validator.equals("0", startDate?string)) && (!validator.equals("0", endDate?string)) > 
512         
513        <#assign dates = dates + [ '${dateUtil.getDate(startDate_Data, format, locale)}' ] > 
514        <#assign dates = dates + [ '${dateUtil.getDate(endDate_Data, format, locale)}' ] > 
515         
516        <#assign dateText = languageUtil.format(locale, "from-to-date", dates) > 
517    </#if> 
518    <#return dateText /> 
519</#function> 
520 
521 
522<#if !validator.equals("", locationAddress.getData())> 
523    <@scriptMap /> 
524</#if> 
525 
526<#macro scriptMap > 
527  <script src="https://maps.googleapis.com/maps/api/js?key=AIzaSyBMctVq13ErDz69AxaIHMb93TR4DA4qioU"></script> 
528   
529  <script> 
530    var map; 
531    var place = "${locationPlace.getData()?string}"; 
532    var address = "${locationAddress.getData()}"; 
533    var latitude; 
534    var longitude; 
535    var punto; 
536    var imagesFolder = "${imagesPath}"; 
537   
538      var geocoder = new google.maps.Geocoder(); 
539      geocoder.geocode({ 'address': address}, function(results, status) { 
540          if (status == google.maps.GeocoderStatus.OK) { 
541              latitude = results[0].geometry.location.lat(); 
542              longitude = results[0].geometry.location.lng(); 
543              punto = new google.maps.LatLng(latitude, longitude); 
544              initialize(); 
545
546      }); 
547   
548      function initialize() { 
549          var styleArray = [ 
550            {featureType: "all",            elementType: "geometry",     stylers: [{color: "#F7F7F7"}]}, 
551            {featureType: "road",           elementType: "geometry",     stylers: [{color: "#FFFFFF"}]}, 
552            {featureType: "poi.park",       elementType: "geometry",     stylers: [{color: "#E5E5E5"}]}, 
553            {featureType: "water",          elementType: "geometry",     stylers: [{color: "#EDEDED"}]}, 
554            {featureType: 'administrative', elementType: 'labels',       stylers: [{visibility: 'off'}]}, 
555            {featureType: 'poi',            elementType: 'labels',       stylers: [{ visibility: 'off' }]}, 
556                {featureType: 'transit',        elementType: 'labels',       stylers: [{ visibility: 'off' }]}, 
557                {featureType: 'road.arterial',  elementType: 'labels',       stylers: [{ visibility: 'off' }]}, 
558        ]; 
559           
560          var punto = new google.maps.LatLng(latitude, longitude); 
561        var mapOptions = { 
562          zoom: 17, 
563          center: punto, 
564          disableDoubleClickZoom: true, 
565          draggable: false, 
566          zoomControl:false, 
567          mapTypeControl: false, 
568          rotateControl: false, 
569          scaleControl: false, 
570          scrollwheel: false, 
571          streetViewControl: false, 
572          mapTypeId: google.maps.MapTypeId.ROADMAP, 
573          styles: styleArray 
574        }; 
575         
576          map = new google.maps.Map(document.getElementById("${portletNamespace}map"), mapOptions); 
577   
578          var latitudeLongitude = {lat: latitude, lng: longitude}; 
579          var marker = new google.maps.Marker({ 
580              position: latitudeLongitude, 
581              map: map, 
582              icon : imagesFolder + '/bizkaia/icon_location_mapa.png', 
583              title : place 
584          }); 
585          marker.setMap(map); 
586
587      
588        $('a[data-toggle="tab"]').on('shown.bs.tab', function (e) { 
589            initialize(); 
590        }) 
591  </script> 
592</#macro> 
593 
594<#function getTarget(element)> 
595    <#if getterUtil.getBoolean(element)> 
596        <#assign target = "_blank" /> 
597    <#else> 
598        <#assign target = "_self" /> 
599    </#if> 
600    <#return target /> 
601</#function> 
602 
603<#function getTitle element > 
604  <#if getterUtil.getBoolean(element)> 
605    <#return "title='" + languageUtil.get(locale, "opens-new-window") + "'" > 
606  <#else> 
607    <#return "" > 
608  </#if> 
609</#function>