Se ha producido un error al procesar la plantilla.
Syntax error in template "10154#10192#null" in line 52, column 15:
Encountered "-", but was expecting one of:
    "="
    "+="
    "-="
    "*="
    "/="
    "%="
    "++"
    "--"
    "in"
    ">"
1<#--##--> 
2<#--#### Scripts--> 
3<#--##--> 
4<script type="text/javascript" src="http://sadmin.brightcove.com/js/BrightcoveExperiences.js"></script> 
5<script type="text/javascript" src="http://sadmin.brightcove.com/js/BrightcoveExperiences_all.js"></script> 
6 
7<#--##--> 
8<#--#### Incluir plantilla de configuración--> 
9<#--##--> 
10<#assign templateKey = "349907" /> <#-- Cambiar la clave por la de la plantilla UrlConfiguration --> 
11<#include templatesPath + '/' + templateKey /> 
12 
13<#--#################################--> 
14<#--#####--> 
15<#--####### Carga de clases y datos--> 
16<#--#####--> 
17<#--#################################--> 
18 
19<#--##--> 
20<#--#### Carga de servicios--> 
21<#--##--> 
22<#assign assetLinkLocalService = serviceLocator.findService("com.liferay.portlet.asset.service.AssetLinkLocalService")  /> 
23<#assign journalArticleLocalService = serviceLocator.findService("com.liferay.portlet.journal.service.JournalArticleLocalService") /> 
24<#assign assetEntryLocalService = serviceLocator.findService("com.liferay.portlet.asset.service.AssetEntryLocalService") /> 
25<#assign classNameLocalService = serviceLocator.findService("com.liferay.portal.service.ClassNameLocalService") /> 
26<#assign assetTagLocalService = serviceLocator.findService("com.liferay.portlet.asset.service.AssetTagLocalService") /> 
27<#assign artworkLocalService = serviceLocator.findService("collections-common-portlet", "com.b2b2000.collections.common.service.ArtWorkLocalService") /> 
28<#assign artworkArtistLocalService = serviceLocator.findService("collections-common-portlet", "com.b2b2000.collections.common.service.ArtWorkArtistLocalService") /> 
29<#assign groupLocalService = serviceLocator.findService("com.liferay.portal.service.GroupLocalService") /> 
30<#assign dlFileEntryTypeLocalService = serviceLocator.findService("com.liferay.portlet.documentlibrary.service.DLFileEntryTypeLocalService") /> 
31<#assign dLFileEntryMetadataLocalService = serviceLocator.findService("com.liferay.portlet.documentlibrary.service.DLFileEntryMetadataLocalService") /> 
32<#assign dlFileEntryService = serviceLocator.findService("com.liferay.portlet.documentlibrary.service.DLFileEntryLocalService") /> 
33 
34<#assign storageEngineUtil = portal.getClass().forName("com.liferay.portlet.dynamicdatamapping.storage.StorageEngineUtil").newInstance() /> 
35<#assign collectionsUtil = portal.getClass().forName("com.b2b2000.collections.common.util.CollectionsUtil").newInstance() /> 
36<#assign journalArticleClassName = "com.liferay.portlet.journal.model.JournalArticle" /> 
37<#assign journalArticleClassNameId = classNameLocalService.getClassNameId(journalArticleClassName) /> 
38<#assign globalGroup = groupLocalService.getCompanyGroup(companyId) /> 
39<#assign supporters = [] /> 
40<#assign activities = [] /> 
41 
42<#--##--> 
43<#--#### Inicialización del Search Context--> 
44<#--##--> 
45<#assign searchContext = portal.getClass().forName("com.liferay.portal.kernel.search.SearchContext").newInstance() /> 
46<#assign searchContext = searchContext.setCompanyId(companyId) /> 
47<#assign searchContext = searchContext.setLocale(locale) /> 
48 
49<#--##--> 
50<#--#### Inicializacion de un theme display a partir del falso theme display que viene en la falsa request--> 
51<#--##--> 
52<#assign theme-display = request.get("theme-display") /> 
53<#assign themeDisplay = portal.getClass().forName("com.liferay.portal.theme.ThemeDisplay").newInstance() /> 
54<#assign themeDisplay = themeDisplay.setPathThemeImages(theme-display.path-theme-images) /> 
55<#assign themeDisplay = themeDisplay.setPortalURL(theme-display.url-portal) /> 
56<#assign themeDisplay = themeDisplay.setPathContext(theme-display.path-context) /> 
57<#assign themeDisplay = themeDisplay.setScopeGroupId(groupId) /> 
58 
59<#--##--> 
60<#--#### Carga de assets relacionados--> 
61<#--##--> 
62<#assign journalArticle = journalArticleLocalService.getArticle(groupId, reserved-article-id.data) /> 
63<#assign assetEntry = assetEntryLocalService.getEntry(journalArticleClassName, journalArticle.getResourcePrimKey()) /> 
64<#assign relatedItems = assetLinkLocalService.getDirectLinks(getterUtil.getLong(assetEntry.getEntryId())) /> 
65 
66<#list relatedItems as relatedItem> 
67    <#assign relatedAsset = assetEntryLocalService.getAssetEntry(relatedItem.getEntryId2()) /> 
68    <#--## En este caso, sólo tendran que mostrarse los JournalArticles asociados. Dependiendo de la estructura ocuparán un lugar u otro.--> 
69    <#--## 1 - ACTIVIDAD: Actividades relacionadas (0..*)--> 
70    <#--## 2 - COLABORADOR: Entidad colaboradora (0..*)--> 
71    <#--## 3 - ITINERANCIA: (1..1)--> 
72    <#--## 4 - UBICACION: Está relacionado con ITINERANCIA (1..1)-->     
73    <#if relatedAsset.getClassNameId() == journalArticleClassNameId> 
74        <#assign relatedArticle = journalArticleLocalService.getLatestArticle(relatedAsset.getClassPK()) /> 
75        <#if relatedArticle?has_content> 
76            <#if relatedArticle.getStructureId() =="ITINERANCIA"> 
77                <#assign roaming = relatedArticle />             
78                <#-- ## Si existe ITINERANCIA, es necesario localizar su UBICACION--> 
79                <#-- ## Se recorren todos los AssetLinks para localizarla--> 
80                <#if roaming??> 
81                    <#assign roamingRelatedItems = assetLinkLocalService.getDirectLinks(getterUtil.getLong(relatedItem.getEntryId2())) /> 
82                    <#list roamingRelatedItems as roamingRelatedItem> 
83                        <#assign roamingRelatedAsset = assetEntryLocalService.getAssetEntry(roamingRelatedItem.getEntryId2()) /> 
84                        <#if roamingRelatedAsset.getClassNameId() == journalArticleClassNameId > 
85                            <#assign roamingRelatedArticle = journalArticleLocalService.getLatestArticle(roamingRelatedAsset.getClassPK()) /> 
86                            <#if roamingRelatedArticle?? && roamingRelatedArticle.getStructureId() == "UBICACION"> 
87                                <#assign location = roamingRelatedArticle /> 
88                            </#if> 
89                        </#if> 
90                    </#list> 
91                </#if> 
92            <#elseif relatedArticle.getStructureId() =="ACTIVIDAD"> 
93            <#-- ## Se almacena el resultado de la operación de añadir para que no lo pinte en pantalla--> 
94                <#assign success = activities.add(relatedArticle) />         
95            <#elseif relatedArticle.getStructureId() == "COLABORADOR"> 
96            <#-- ## Se almacena el resultado de la operación de añadir para que no lo pinte en pantalla--> 
97                <#assign success = supporters.add(relatedArticle)> 
98            </#if> 
99        </#if> 
100    </#if> 
101</#list> 
102 
103<#--#################################--> 
104<#--#####--> 
105<#--####### Plantilla--> 
106<#--#####--> 
107<#--#################################--> 
108 
109<#assign node = saxReaderUtil.read(roaming.getContentByLocale("${locale}")) /> 
110<#assign roamingStartDate = node.selectSingleNode("//dynamic-element[@name='startDate']/dynamic-content").data /> 
111<#assign roamingEndDate = node.selectSingleNode("//dynamic-element[@name='endDate']/dynamic-content").data /> 
112 
113<#assign startDateCalendar = dateTool.toDate('dd/MM/yyyy', roamingStartDate) /> 
114<#assign endDateCalendar = dateTool.toDate('dd/MM/yyyy', roamingEndDate) /> 
115<#assign nowCalendar = dateTool.getDate() /> 
116 
117<#if startDateCalendar.compareTo(nowCalendar) gt 0> 
118    <#assign backURL= backFutureExhibitionURL /> 
119<#elseif endDateCalendar.compareTo(nowCalendar) lt 0> 
120    <#assign backURL= backOldExhibitionURL /> 
121<#else> 
122    <#assign backURL= ackCurrentExhibitionURL /> 
123</#if> 
124 
125<#if backURL??> 
126    <span class="volver"> 
127        <a href="${backURL}"> <@liferay.language key="es.colecciones.back" /> </a> 
128    </span> 
129</#if> 
130 
131 
132<div class="activity detail" itemscope itemtype="http://schema.org/Event"> 
133    <h2 itemprop="name"> ${title.data} </h2> 
134    <p class="when"> 
135        <#if roamingStartDate??> 
136            <span itemprop="startDate">${roamingStartDate}</span> - 
137        </#if> 
138 
139        <#if roamingEndDate??> 
140            <span itemprop="endDate">${roamingEndDate}</span> 
141        </#if> 
142    </p> 
143 
144    <p class="where" itemprop="location" itemscope itemtype="http://schema.org/Place"> 
145        <#assign node = saxReaderUtil.read(location.getContentByLocale("${locale}")) /> 
146        <#assign locationName = node.selectSingleNode("//dynamic-element[@name='title']/dynamic-content").data /> 
147 
148        <#if locationName??> 
149            <span itemprop="name">${locationName}</span> 
150        </#if> 
151    </p> 
152 
153    <div class="info"> 
154        <div class="description" itemprop="description"> 
155            <#if desc.data??> 
156                ${desc.data} 
157            </#if> 
158        </div> 
159 
160        <#if document.data?? || activities?has_content> 
161            <div class="details"> 
162                <#--## Material asociado--> 
163                <#if document.data??> 
164                    <ul> 
165                        <#list document.siblings as doc> 
166                            <#--##Trocear url documento--> 
167                            <#assign segments = doc.data.split('/') /> 
168                            <#--##uuid file--> 
169                            <#assign uuid = segments.get(5) />                             
170                            <#--##Documento--> 
171                            <#assign fileEntry = dlFileEntryService.getDLFileEntryByUuidAndGroupId(uuid, groupId) /> 
172                            <#if fileEntry??> 
173                                <li><a href="${doc.data}">${fileEntry.title}</a></li> 
174                            </#if> 
175                        </#list> 
176                    </ul> 
177                </#if> 
178 
179                <#--## Actividades relacionadas--> 
180                <#if activities?has_content> 
181                    <ul class="relatedActivities"> 
182                        <#list activities as activity> 
183                            <#assign node = saxReaderUtil.read(activity.getContentByLocale("${locale}")) /> 
184                            <#assign activityName = node.selectSingleNode("//dynamic-element[@name='title']/dynamic-content").data /> 
185                            <#assign activityUrl = "${exhibitionDetailURL}/${groupId}/${activity.articleId}" /> 
186         
187                            <li><a href="${activityUrl}">${activityName}</a></li> 
188                        </#list> 
189                    </ul> 
190                </#if> 
191 
192                <#if url_.data??> 
193                    <a href="${url_.data}"><@liferay.language key="read-more" /></a> 
194                </#if> 
195            </div> 
196        </#if> 
197 
198        <#--## Entidades colaboradoras--> 
199        <#if supporters?has_content> 
200            <div class="supporters"> 
201                <h3><@liferay.language key="ca.supporters" /></h3> 
202                <ul itemscope itemtype="http://schema.org/Organization"> 
203                    #foreach ($supporter in $supporters) 
204                    <#list supporters as supporter> 
205                        <#assign node = saxReaderUtil.read($supporter.getContentByLocale("${locale}")) /> 
206                        <#assign supporterTitle = node.selectSingleNode("//dynamic-element[@name='title']/dynamic-content").data /> 
207                        <#assign supporterUrl = node.selectSingleNode("//dynamic-element[@name='url_']/dynamic-content").data /> 
208                        <#assign supporterLogo = node.selectSingleNode("//dynamic-element[@name='logo']/dynamic-content").data /> 
209                        <li> 
210                            <span class="name" itemprop="name">${supporterTitle}</span> 
211                            <a itemprop="url" href="${supporterUrl}"> 
212                                <img itemprop="image" src="${supporterLogo}" alt="${supporterTitle}" /> 
213                            </a> 
214                        </li> 
215                    </#list> 
216                </ul> 
217            </div> 
218        </#if> 
219    </div> 
220 
221    <#--##--> 
222    <#--#### Los campos video e imagen, en la estructura, son repetibles.--> 
223    <#--#### Según el diseño acordado, unicamente se muestra un video o una imagen--> 
224    <#--#### por lo que se coge el primero y se ignoran el resto--> 
225    <#--##--> 
226    <div class="media"> 
227        <#if video.data??> 
228            <#--##Tipo de fichero Video--> 
229            <#assign dlFileEntryType = dlFileEntryTypeLocalService.getFileEntryType(groupId,'Video') /> 
230            <#assign listDDMStructures = dlFileEntryType.getDDMStructures() /> 
231            <#--##Trocear url documento--> 
232            <#assign trozosVideo = video.data.split('/') /> 
233            <#--##uuid file--> 
234            <#assign trozo = trozosVideo.get(5) /> 
235            <#--##Documento--> 
236            <#assign fileEntry = dlFileEntryService.getDLFileEntryByUuidAndGroupId(trozo, groupId) /> 
237            <#list listDDMStructures as item> 
238                <#assign fileEntryMetadata = dLFileEntryMetadataLocalService.getFileEntryMetadata(item.getStructureId(), fileEntry.getFileVersion().getFileVersionId()) /> 
239                <#assign fields = storageEngineUtil.getFields(fileEntryMetadata.getDDMStorageId()) /> 
240                <#assign fieldId = fields.get('fileId') /> 
241                <#assign fieldCode =fieldId.getValue() /> 
242            </#list> 
243            <#--##Brightcove--> 
244            <object id="<portlet:namespace/>_videoplayer" class="BrightcoveExperience"> 
245                <param name="bgcolor" value="#FFFFFF" /> 
246                <param name="width" value="300" /> 
247                <param name="height" value="200" /> 
248                <param name="playerID" value="1822475294001" /> 
249                <param name="playerKey" value="${keyBrightcove}" /> 
250                <param name="isVid" value="true" /> 
251                <param name="isUI" value="true" /> 
252                <param name="dynamicStreaming" value="true" /> 
253                <param name="wmode" value="transparent" /> 
254                <param name="secureConnections" value="true" /> 
255                <param name="secureHTMLConnections" value="true" /> 
256                <param name="@videoPlayer" value="${fieldCode}" /> 
257            </object> 
258        <#else> 
259            <#if image.data??> 
260                <img itemprop="image" src="${image.data}&imageThumbnail=3" alt="${title.data}" /> 
261                <#--##Incluir pie de imagen--> 
262                <#assign array = image.data.split("/") /> 
263                <#-- Plantilla "Pie Foto" --> 
264                <#assign templateKey = "1703204" /> <#-- Cambiar la clave por la de la plantilla Pie Foto --> 
265                <#include templatesPath + '/' + templateKey /> 
266            </#if> 
267        </#if> 
268 
269        <#--##--> 
270        <#--#### Carrusel de Obras de la exposición--> 
271        <#--#### Las obras se obtienen de los tags del contenidos--> 
272        <#--#### La etiqueta se corresponde con el identificador de la obra--> 
273        <#--##--> 
274        <#assign tags = assetTagLocalService.getTagNames(journalArticleClassNameId, journalArticle.getResourcePrimKey()) /> 
275        <#if tags?has_content> 
276            <h2><@liferay.language key="ca.artworks.exhibition" /></h2> 
277            <div class="suggestion"> 
278                <a class="buttons prev" href="javascript:void(0)">left</a> 
279                <div class="viewport"> 
280                    <ul class="overview"> 
281                        <#list tags as tag> 
282                            <#--## Obra--> 
283                            <#assign artwork = artworkLocalService.getArtworkByInventoryId(groupId, companyId, tag) /> 
284                            <#--## Miniatura--> 
285                            <#assign artworkThumbnail = collectionsUtil.getMiniatureArtworkURL(artwork, themeDisplay, searchContext, globalGroup) /> 
286                            <#--## Artistas--> 
287                            <#assign artists = artworkArtistLocalService.getArtist(artwork.companyId, artwork.groupId, artwork.inventoryId) /> 
288                            <li itemscope itemtype="http://schema.org/CreativeWork"> 
289                                <a itemprop="url" href="${artworkDetailURL}/${artwork.inventoryId}/${collectionsUtil.getName(artwork.getTitle(locale))}"> 
290                                    <img itemprop="image" src="http://${artworkThumbnail}" alt="${artwork.getTitle(locale)}"/> 
291                                </a> 
292                                <#if artists?has_content> 
293                                    <#list artists as artist> 
294                                        <div itemscope itemtype="http://schema.org/Person"> 
295                                            <p class="artist"> 
296                                                <a itemprop="url" href="${artistDetailURL}/${artist.constituentId}/${collectionsUtil.getName(artist.fullName)}"> 
297                                                    <span itemprop="name">${artist.fullName}</span> 
298                                                </a> 
299                                            </p> 
300                                        </div> 
301                                    </#list> 
302                                </#if> 
303                                <p itemprop="name" class="title"> 
304                                    <#assign artworkTitle = artwork.getTitle(locale) /> 
305                                    <#if artworkTitle??> 
306                                        <#if artworkTitle.length() < 50> 
307                                            ${artworkTitle} 
308                                        <#else> 
309                                            ${artworkTitle.substring(0, 50)} ... 
310                                        </#if> 
311                                    </#if> 
312                                    <span class="date"> 
313                                        <#if artwork.startDate??> 
314                                            <span itemprop="dateCreated">/ ${artwork.startDate}</span> 
315                                        </#if> 
316                                        <#if artwork.endDate && artwork.endDate != artwork.startDate> 
317                                            -  <span itemprop="datePublished">${artwork.endDate}</span> 
318                                        </#if> 
319                                    </span> 
320                                </p> 
321                            </li> 
322                        </#list> 
323                    </ul> 
324                </div> 
325                <a class="buttons next" href="javascript:void(0)">right</a> 
326            </div> 
327        </#if> 
328    </div> 
329</div>