Si è verificato un errore nell'elaborarazione del modello.
The following has evaluated to null or missing: ==> response.data.docs.getJSONObject(0) [in template "3572636#3572671#4212428" at line 27, column 24] ---- 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 doc = response.data.docs.getJ... [in template "3572636#3572671#4212428" at line 27, column 9] ----
1<#import "_TEMPLATE_CONTEXT_/3572636/3574130/23609/3793037" as d40>
2
3<#setting url_escaping_charset="UTF-8">
4
5<#assign
6 PUTIL = objectUtil("com.liferay.portal.kernel.util.PortalUtil")
7 uuid = themeDisplay.getURLCurrent()?keep_after("-/c/n/")?keep_before("?")?keep_after_last("_")
8 langId = locale?keep_before("_")
9 contentType = "event"
10 vueActions = ""
11 doc = ""
12 lat = "0"
13 lng = "0"
14 hasCoords = false
15/>
16<#-- <#assign z=request.setAttribute("ogTitle","title")>
17<#assign z=request.setAttribute("ogImage","imgg")>
18<#assign z=request.setAttribute("ogDesc","desc")> -->
19
20<#assign currentUrl = themeDisplay.getPortalURL() + themeDisplay.getURLCurrent() />
21<#assign z=request.setAttribute("ogUrl","${currentUrl}")>
22
23<#if uuid?has_content>
24 <#assign response = d40.fetchData("https://guestapp.d40.it/v1/search/apt-trento/${contentType}/?uuid=${uuid}&active=false")>
25
26 <#if !response.error && response.data.docs?has_content>
27 <#assign doc = response.data.docs.getJSONObject(0)>
28
29 ${request.session.removeAttribute("circularCategories")}
30 ${request.session.setAttribute("circularCategories", doc.details.assetCategoryIds)}
31 </#if>
32</#if>
33
34<#if doc?has_content>
35 <#if doc.details?? && doc.details.name[langId]?has_content>
36 ${PUTIL.setPageTitle(doc.details.name[langId], request)}
37 </#if>
38
39 <#assign vueActions = "getFavorites();">
40
41 <#if doc.details.location.geoCoords.lat?has_content && doc.details.location.geoCoords.lon?has_content>
42 <#assign
43 hasCoords = true
44 lat = doc.details.location.geoCoords.lat
45 lng = doc.details.location.geoCoords.lon
46 vueActions = "getFavorites();buildMap(${lat}, ${lng})"
47 />
48 </#if>
49</#if>
50
51<style>
52 .swiper-button-next:after{
53 content: "";
54 }
55 .swiper-button-prev:after{
56 content: "";
57 }
58 .bg-darkgray{
59 background-color: #e5e5e5 !important;
60 }
61 .min-h-12{
62 min-height: 3rem;
63 }
64 .-ml-5{
65 margin-left: -5%;
66 }
67</style>
68
69<div v-scope id="${d40.portletNamespace}" @vue:mounted="${vueActions}" v-cloak>
70 <#if doc?has_content>
71 <#if themeDisplay.getLayout().getAncestors()?has_content>
72 <section id="breadcrumb" class="z-15 mt-25">
73 <div class="container">
74 <ol class="breadcrumb flex lg:justify-center">
75 <li class="pl-1 text-sm mr-2 relative">${d40.getLabel("sei_in")}:</li>
76
77 <li class="breadcrumb-item">
78 <a href="/" class="breadcrumb-link" title="Home">
79 <span class="breadcrumb-text-truncate text-dark underline">Home</span>
80 </a>
81 </li>
82
83 <#list themeDisplay.getLayout().getAncestors()?reverse as ancestor>
84 <li class="breadcrumb-item">
85 <a href="${ancestor.getFriendlyURL()}" class="breadcrumb-link" title="${d40.escape(ancestor.getHTMLTitle(locale))}">
86 <span class="breadcrumb-text-truncate text-dark underline">
87 ${d40.escape(ancestor.getHTMLTitle(locale))}
88 </span>
89 </a>
90 </li>
91 </#list>
92
93 <li class="breadcrumb-item active">
94 <span class="breadcrumb-text-truncate text-dark">
95 ${doc.details.name[langId]}
96 </span>
97 </li>
98 </ol>
99 </div>
100 </section>
101 </#if>
102
103 <section class="relative mt-20">
104 <div class="container">
105 <div class="row">
106 <div class="col-12 col-lg-7">
107 <div class="card-row flex-col lg:flex-row mb-10">
108 <div class="autofit-col autofit-col-expand order-2 lg:order-1">
109 <div class="autofit-section">
110 <p class="text-dark font-semibold font-heading text-3xl lg:text-4xl uppercase">
111 ${doc.details.name[langId]}
112
113 <#assign z=request.setAttribute("ogTitle","${doc.details.name[langId]}")>
114
115 </p>
116 </div>
117 </div>
118 <div class="autofit-col justify-start order-1 lg:order-2 mb-3 lg:mb-0">
119 <div class="autofit-section">
120 <div class="flex space-x-4">
121 <button type="button" v-if="isFavorite('${doc.uuid}')" @click="removeFavorite($event, '${doc.uuid}')" class="btn btn-link px-2">
122 <i class="fas fa-heart text-dark fa-2x"></i>
123 </button>
124 <button type="button" v-else @click="setFavorite($event, {id: '${doc.uuid}', contentJSON: {title: '${doc.details.name[langId]?js_string}', previewDescription: '', description: '', geoRef: '', previewPicture: '${d40.getDTNPreview(doc)}', viewUrl: '${d40.getDTNUrl(doc.details.name[langId], doc.uuid, contentType)}'}})" class="btn btn-link px-2">
125 <i class="fal fa-heart text-dark fa-2x"></i>
126 </button>
127
128 <button type="button" @click="share('${doc.details.name[langId]}', '')" class="btn btn-link px-2">
129 <i class="fas fa-share-alt text-dark fa-2x"></i>
130 </button>
131 </div>
132 </div>
133 </div>
134 </div>
135
136 <#if doc.details.description[langId]?has_content>
137 <div class="underline-grow text-dark font-light lg:text-lg leading-loose">
138 ${doc.details.description[langId]}
139
140 <#if doc.details.description[langId]?length lt 160>
141 <#assign
142 z=request.setAttribute("ogDesc","${htmlUtil.stripHtml(doc.details.description[langId])}")
143 />
144 <#else>
145 <#assign
146 z=request.setAttribute("ogDesc","${htmlUtil.stripHtml(doc.details.description[langId])?substring(0,160)}")
147 />
148 </#if>
149
150 </div>
151 </#if>
152
153 <#if doc.timetables.timeDescription[langId]?has_content>
154 <div class="text-dark text-lg font-light mb-5 mt-10">
155 ${doc.timetables.timeDescription[langId]?keep_before("<br><p><b>")}
156 </div>
157 </#if>
158
159 <#if doc.details.howToArrive?has_content && doc.details.howToArrive[langId]?has_content>
160 <div class="text-dark text-lg font-light mb-5 mt-10">
161 <b>${d40.getLabel("come_arrivare")}:</b>
162 ${doc.details.howToArrive[langId]}
163 </div>
164 </#if>
165
166 <#-- <#if d40.isDev> -->
167 <#if doc.booking?has_content>
168 <#if doc.booking.bookable?has_content && doc.booking.bookable>
169 <#if doc.booking.standartPrices?has_content>
170 <#attempt>
171 <div class="text-dark text-lg font-light mb-5 mt-10">
172 <#list doc.booking.standartPrices.iterator() as single_price >
173 <#if single_price[langId]?has_content>
174
175 <#if single_price?index == 0>
176 <p class="mt-3"><b>${d40.getLabel("costo_biglietto")}:</b></p>
177 <ul style="padding-left:0;list-style: none;">
178 </#if>
179
180 <li>
181 • ${single_price[langId]}
182 </li>
183 </#if>
184 </#list>
185 </ul>
186 </div>
187 <#recover>
188 <div style="display:none !important;"></div>
189 </#attempt>
190 </#if>
191 </#if>
192 </#if>
193 <#-- </#if> -->
194
195 </div>
196
197 <div class="xl:absolute col-12 col-lg-5 xl:max-w-xl lg:right-0">
198 <div class="bg-light">
199 <div class="card-body px-5 pt-5 lg:px-10 lg:pt-10 pb-0">
200 <p class="text-dark font-bold uppercase text-lg mb-0">
201 ${d40.getLabel("informazioni_contatti")}
202 </p>
203 <#if doc.details.townLabel != "{}">
204 <p class="text-dark text-lg mb-0">
205 ${d40.getLabel("localita")}: <span class="text-capitalize">${doc.details.townLabel[langId]}</span>
206 </p>
207 </#if>
208 <#if doc.details.location.address.fulltext?? && doc.details.location.address.fulltext?has_content>
209 <p class="text-dark text-lg mb-0">
210 ${doc.details.location.address.fulltext}
211 </p>
212 </#if>
213 <#if doc.timetables.timeInfos?has_content>
214 <p class="text-dark font-bold text-lg mb-0 mt-3">
215 ${d40.getLabel("date_evento")}
216 </p>
217 </#if>
218 </div>
219
220 <#if doc.timetables.timeInfos?has_content>
221 <div class="flex min-h-12">
222 <details class="bg-darkgray w-full lg:w-105% right-0 -ml-5">
223 <summary class="btn btn-link text-dark no-underline my-1 ml-12">
224 <i class="fal fa-calendar-alt"></i>
225
226 <#attempt>
227 <#assign day_count = 0>
228
229 <#list doc.timetables.timeInfos.getJSONObject(0).openingDays.iterator()?keys as single_day >
230 <#assign day_count += 1>
231 </#list>
232
233 <div style="display:none !important;">
234 ${jsonFactoryUtil.looseSerialize(day_count)}
235 </div>
236 <#recover>
237 <#assign test = doc.timetables.timeInfos.getJSONObject(0).openingDays />
238 <div style="display:none !important;">
239
240 </div>
241 </#attempt>
242
243
244 <#assign
245 split_fdf = doc.timetables.timeRange.rangeFrom?split('-')
246 split_fdt = doc.timetables.timeRange.rangeTo?split('-')
247 fdf = split_fdf[2]+"."+split_fdf[1]+"."+split_fdf[0]
248 fdt = split_fdt[2]+"."+split_fdt[1]+"."+split_fdt[0]
249
250 />
251
252 <#if fdf == fdt>
253 ${fdf}
254 <#else>
255 ${d40.getLabel("dal")} ${fdf} ${d40.getLabel("al")} ${fdt}
256 </#if>
257
258 <i class="fal fa-chevron-down fa-lg ml-5"></i>
259 </summary>
260
261 <#if doc.timetables.timeDescription[langId]?has_content>
262 <div class="card-body px-5 lg:px-15" style="display:none">
263 <div class="text-dark">
264 ${doc.timetables.timeDescription[langId]?keep_after('<br>')?keep_before("<br><p><b>")}
265 </div>
266 </div>
267 </#if>
268
269 <#-- <#if d40.isDev> -->
270 <#if doc.booking?has_content>
271 <#if doc.booking.bookable?has_content && doc.booking.bookable>
272 <#if doc.booking.standartPrices?has_content && doc.booking.standartPrices.iterator()?has_content>
273 <#attempt>
274 <div class="card-body px-5 lg:px-15">
275 <#list doc.booking.standartPrices.iterator() as single_price >
276 <#if single_price[langId]?has_content>
277
278 <#if single_price?index == 0>
279 <p class="mt-3"><b>${d40.getLabel("costo_biglietto")}:</b></p>
280 <ul style="padding-left:0;list-style: none;">
281 </#if>
282
283 <li>
284 • ${single_price[langId]}
285 </li>
286 </#if>
287 </#list>
288 </ul>
289 </div>
290 <#recover>
291 <div style="display:none !important;"></div>
292 </#attempt>
293 </#if>
294 </#if>
295 </#if>
296 <#-- </#if> -->
297
298 <div class="card-body px-5 lg:px-10" >
299 <ul>
300 <#list doc.timetables.timeInfos.iterator() as datetime>
301 <li class="text-dark mb-1">
302
303 <#assign
304 split_df = datetime.dateFrom?split('-')
305 split_dt = datetime.dateTo?split('-')
306 df = split_df[2]+"."+split_df[1]+"."+split_df[0]
307 dt = split_dt[2]+"."+split_dt[1]+"."+split_dt[0]
308 tf = datetime.timeFrom
309 tt = datetime.timeTo
310 />
311
312 <#if df == dt>
313 ${d40.getLabel("il")} ${df} - ${tf} - ${tt}
314 <#else>
315 ${d40.getLabel("dal")} ${df} ${d40.getLabel("al")} ${dt} - ${tf} - ${tt}
316 </#if>
317 </li>
318 </#list>
319 </ul>
320 </div>
321 </details>
322 </div>
323 </#if>
324
325 <div class="card-body px-5 lg:px-10">
326 <#if doc.contacts.getJSONObject(0).address.fulltext?? && doc.contacts.getJSONObject(0).address.fulltext?has_content>
327 <p class="text-dark font-bold uppercase text-lg mb-0">
328 ${d40.getLabel("organizzazione")}
329 </p>
330 </#if>
331
332 <#if doc.contacts.getJSONObject(0).supplierName?? && doc.contacts.getJSONObject(0).supplierName?has_content>
333 <p class="text-dark text-lg mb-1 font-bold">
334 ${doc.contacts.getJSONObject(0).supplierName}
335 </p>
336 </#if>
337
338 <#if doc.contacts.getJSONObject(0).address.fulltext?? && doc.contacts.getJSONObject(0).address.fulltext?has_content>
339 <p class="text-dark text-lg mb-1">
340 ${doc.contacts.getJSONObject(0).address.fulltext}
341 </p>
342 </#if>
343
344 <#if doc.contacts.getJSONObject(0).telephone?? && doc.contacts.getJSONObject(0).telephone?has_content>
345 <#list doc.contacts.getJSONObject(0).telephone.iterator() as phone>
346 <#if phone?? && phone?has_content>
347 <a href="tel:${phone}" class="block no-underline text-dark text-lg space-x-2 mb-0">
348 <#assign clear_phone = phone?replace('+39', '')/>
349 <#if clear_phone?starts_with("0461")>
350 <#assign display_phone = clear_phone?replace('0461', '0461 ')/>
351 <#else>
352 <#attempt>
353 <#assign
354 pre_chunk = clear_phone[0..2]
355 display_phone = pre_chunk+" "+clear_phone[3..]
356 />
357 <#recover>
358 </#attempt>
359 </#if>
360
361 <#if display_phone?? && display_phone?has_content>
362 <i class="far fa-phone text-dark"></i>
363 <u>${display_phone}</u>
364 </#if>
365 </a>
366 </#if>
367 </#list>
368 </#if>
369 <#if doc.contacts.getJSONObject(0).mail?? && doc.contacts.getJSONObject(0).mail?has_content>
370 <a href="mailto:${doc.contacts.getJSONObject(0).mail}" class="block no-underline text-dark text-lg space-x-2 mb-0">
371 <i class="far fa-envelope text-dark"></i>
372 <u>${doc.contacts.getJSONObject(0).mail}</u>
373 </a>
374 </#if>
375 <#if doc.contacts.getJSONObject(0).websiteUrl[langId]?? && doc.contacts.getJSONObject(0).websiteUrl[langId]?has_content>
376 <a href="${doc.contacts.getJSONObject(0).websiteUrl[langId]}" class="block no-underline text-dark text-lg space-x-2 mb-0" target="_blank">
377 <i class="far fa-external-link text-dark"></i>
378 <u>${d40.getLabel("sito_web")}</u>
379 </a>
380 </#if>
381
382 <#if doc.contacts.getJSONObject(0).socialRefs.facebook?? && doc.contacts.getJSONObject(0).socialRefs.facebook?has_content>
383 <a href="${doc.contacts.getJSONObject(0).socialRefs.facebook[langId]}" class="block no-underline text-dark text-lg space-x-2 mb-0" target="_blank">
384 <i class="fab fa-facebook-square text-dark"></i>
385 <u>facebook</u>
386 </a>
387 </#if>
388
389 <#if doc.contacts.getJSONObject(0).socialRefs.twitter?? && doc.contacts.getJSONObject(0).socialRefs.twitter?has_content>
390 <a href="${doc.contacts.getJSONObject(0).socialRefs.twitter[langId]}" class="block no-underline text-dark text-lg space-x-2 mb-0" target="_blank">
391 <i class="fab fa-twitter-square text-dark"></i>
392 <u>twitter</u>
393 </a>
394 </#if>
395
396 <#if doc.contacts.getJSONObject(0).socialRefs.instagram?? && doc.contacts.getJSONObject(0).socialRefs.instagram?has_content>
397 <a href="${doc.contacts.getJSONObject(0).socialRefs.instagram[langId]}" class="block no-underline text-dark text-lg space-x-2 mb-0" target="_blank">
398 <i class="fab fa-instagram-square text-dark"></i>
399 <u>instagram</u>
400 </a>
401 </#if>
402
403 <#if langId == 'en'>
404 <#assign ri_url = "/contact-tourist-office-trento" />
405 <#elseif langId == 'de'>
406 <#assign ri_url = "/kontakt-info-anfrage-trento" />
407 <#else>
408 <#assign ri_url = "/richiesta-informazioni" />
409 </#if>
410
411 <a href="#contact-form" class="btn bg-green text-white font-bold uppercase px-4 py-2 rounded-0 mt-10">
412 ${d40.getLabel("richiedi_info")}
413 </a>
414 </div>
415 <#if hasCoords>
416 <div class="relative flex h-70">
417 <div class="absolute w-full lg:w-105% h-full right-0">
418 <div id="suggesto-map" class="monochrome-map size-full border-0"></div>
419 </div>
420 </div>
421
422 <div class="card-body p-5 lg:px-10">
423 <!-- https://www.google.com/maps/@${lat},${lng},14z -->
424 <a href="https://www.google.com/maps/dir/?api=1&travelmode=driving&destination=${lat},${lng}" class="d-block no-underline space-x-5" target="_blank">
425 <span class="font-bold text-dark uppercase">
426 ${d40.getLabel("indicazioni_stradali")}
427 </span>
428 <img src="${d40.icons_folder}/arrow_circle-dark.svg" class="w-20" />
429 </a>
430 </div>
431 </#if>
432 </div>
433 </div>
434 </div>
435 </div>
436 </section>
437
438 <#if doc.details.images?has_content>
439 <#assign usePreview = false>
440
441 <section id="gallery" class="relative overflow-x-hidden mt-20 lg:mt-40">
442 <div class="container">
443 <p class="text-dark uppercase text-lg lg:text-3xl mb-7">
444 ${d40.getLabel("galleria_immagini")}
445 </p>
446
447 <div class="swiper-container">
448 <div class="swiper-wrapper">
449 <#if doc.details.cover != "[]">
450 <#assign usePreview = true>
451
452 <#list doc.details.cover.iterator() as pic>
453 <div class="swiper-slide">
454 <a href="javascript:void(0);" class="card shadow-none border-0 bg-transparent no-underline" data-toggle="modal" data-target="#lightbox-modal" data-slider="${pic?index}" data-senna-off="true">
455 <div class="relative">
456 <img data-src="${d40.getKitPrefix(pic[langId], 'n-preview_h')}" loading="lazy" class="lazyload rounded-custom size-full fit-cover" alt="" />
457 </div>
458 </a>
459 </div>
460
461 <#-- assign z=request.setAttribute("ogImage","${pic[langId]}") -->
462 <#assign z=request.setAttribute("ogImage","${d40.getKitPrefix(pic[langId], 'n-preview_h')}")>
463
464 <#break>
465 </#list>
466 </#if>
467
468 <#list doc.details.images.iterator() as pic>
469 <#if usePreview>
470 <#assign counter = pic?counter>
471 <#else>
472 <#assign counter = pic?index>
473 </#if>
474
475 <div class="swiper-slide">
476 <a href="javascript:void(0);" class="card shadow-none border-0 bg-transparent no-underline" data-toggle="modal" data-target="#lightbox-modal" data-slider="${counter}" data-senna-off="true">
477 <div class="relative">
478 <img data-src="${d40.getKitPrefix(pic[langId], 'n-preview_h')}" loading="lazy" class="lazyload rounded-custom size-full fit-cover" alt="" />
479 </div>
480 </a>
481 </div>
482 </#list>
483 </div>
484 </div>
485 </div>
486 <div class="btn-square absolute btn-prev bg-white left-0">
487 <span class="sr-only">${d40.getLabel("precedente")}</span>
488 <i class="fas fa-chevron-left text-dark w-6 h-6"></i>
489 </div>
490 <div class="btn-square absolute btn-next bg-white right-0">
491 <span class="sr-only">${d40.getLabel("successivo")}</span>
492 <i class="fas fa-chevron-right text-dark w-6 h-6"></i>
493 </div>
494 </section>
495
496 <div id="lightbox-modal" tabindex="-1" role="dialog" class="modal fade">
497 <div class="modal-dialog modal-full-screen inset-0 border-0 shadow-none">
498 <div class="modal-content bg-transparent">
499 <div class="modal-body overflow-hidden">
500 <div class="absolute top-0 right-0 z-5">
501 <button type="button" data-dismiss="modal" class="btn btn-monospaced btn-secondary m-3">
502 <span class="sr-only">${d40.getLabel("chiudi")}</span>
503 <i class="fal fa-times fa-lg"></i>
504 </button>
505 </div>
506
507 <#-- lightbox -->
508 <div id="lightbox-swiper" class="swiper-container h-75 my-auto">
509 <div class="swiper-button-prev w-12 h-12">
510 <span class="sticker sticker-circle bg-green size-full">
511 <span class="sticker-overlay">
512 <i class="fas fa-chevron-left fa-2x text-white"></i>
513 </span>
514 </span>
515 </div>
516
517 <div class="swiper-button-next w-12 h-12">
518 <span class="sticker sticker-circle bg-green size-full">
519 <span class="sticker-overlay">
520 <i class="fas fa-chevron-right fa-2x text-white"></i>
521 </span>
522 </span>
523 </div>
524
525 <div class="swiper-wrapper h-full">
526 <#if doc.details.cover != "[]">
527 <#list doc.details.cover.iterator() as pic>
528 <div class="swiper-slide h-full">
529 <img data-src="${d40.getKitPrefix(pic[langId], 'n-full_hd')}" loading="lazy" class="lazyload flex h-full object-contain mx-auto" alt="">
530 </div>
531 <#break>
532 </#list>
533 </#if>
534
535 <#list doc.details.images.iterator() as pic>
536 <div class="swiper-slide h-full">
537 <img data-src="${d40.getKitPrefix(pic[langId], 'n-full_hd')}" loading="lazy" class="lazyload flex h-full object-contain mx-auto" alt="">
538 </div>
539 </#list>
540 </div>
541 </div>
542
543 <#-- thumbnails -->
544 <div id="thumbnail-swiper" class="swiper-container" thumbsSlider="">
545 <div class="swiper-wrapper">
546 <#if doc.details.cover != "[]">
547 <#list doc.details.cover.iterator() as pic>
548 <div class="swiper-slide">
549 <img data-src="${d40.getKitPrefix(pic[langId], 'n-preview_h')}" loading="lazy" class="lazyload object-cover cursor-pointer size-full" alt="">
550 </div>
551 <#break>
552 </#list>
553 </#if>
554
555 <#list doc.details.images.iterator() as pic>
556 <div class="swiper-slide">
557 <img data-src="${d40.getKitPrefix(pic[langId], 'n-preview_h')}" loading="lazy" class="lazyload object-cover cursor-pointer size-full" alt="">
558 </div>
559 </#list>
560 </div>
561 </div>
562 </div>
563 </div>
564 </div>
565 </div>
566 </#if>
567
568 <#-- SEZIONE NON USATA
569 <section class="mt-20">
570 <div class="container">
571 <div class="bg-light max-w-xl p-5 lg:p-10">
572 <div class="card-row space-x-5">
573 <div class="autofit-col">
574 <div class="autofit-section">
575 <i class="fas fa-download text-dark w-7 h-7"></i>
576 </div>
577 </div>
578 <div class="autofit-col autofit-col-expand">
579 <div class="autofit-section">
580 <p class="text-dark font-bold text-lg lg:text-xl uppercase mb-0"> Programma completo </p>
581 </div>
582 </div>
583 </div>
584 </div>
585
586 <div class="row mt-10 lg:mt-20">
587 <div class="col-12 col-lg-8">
588 <div class="space-y-10">
589 <p class="text-dark uppercase text-lg lg:text-3xl">
590 ${d40.getLabel("dettagli")}
591 </p>
592 <div class="space-y-5">
593 <div class="row">
594 <div class="col-12 col-md-3 col-lg-2">
595 <p class="text-dark font-bold uppercase">Data</p>
596 </div>
597 <div class="col-12 col-md-9 col-lg-10">
598 <div class="text-dark font-light text-lg">
599 Dettagli
600 </div>
601 </div>
602 </div>
603 </div>
604 </div>
605 </div>
606 </div>
607 </div>
608 </section>
609 -->
610
611 <#-- <section class="mt-20">
612 <div class="container">
613 <div class="bg-light">
614 <div class="space-y-10 p-5 lg:p-10">
615 <p class="text-dark uppercase text-lg lg:text-3xl mb-0">
616 ${d40.getLabel("organizzazione")}
617 </p>
618 <div class="space-y-2">
619 <#if doc.contacts.getJSONObject(0).address.fulltext?? && doc.contacts.getJSONObject(0).address.fulltext?has_content>
620 <p class="text-dark mb-0">
621 ${doc.contacts.getJSONObject(0).address.fulltext}
622 </p>
623 </#if>
624
625 <#if doc.contacts.getJSONObject(0).mail?? && doc.contacts.getJSONObject(0).mail?has_content>
626 <a href="mailto:${doc.contacts.getJSONObject(0).mail}" class="d-block text-dark underline">
627 ${doc.contacts.getJSONObject(0).mail}
628 </a>
629 </#if>
630
631 <#if doc.contacts.getJSONObject(0).telephone?? && doc.contacts.getJSONObject(0).telephone?has_content>
632 <#list doc.contacts.getJSONObject(0).telephone.iterator() as phone>
633 <p class="text-dark mb-0">
634 <span class="font-bold">${d40.getLabel("telefono")}:</span>
635 ${phone}
636 </p>
637 </#list>
638 </#if>
639
640 <#if doc.contacts.getJSONObject(0).socialRefs.facebook?? && doc.contacts.getJSONObject(0).socialRefs.facebook?has_content>
641 <a href="${doc.contacts.getJSONObject(0).socialRefs.facebook[langId]}" class="block no-underline text-dark text-lg space-x-2 mb-0" target="_blank">
642 <i class="fab fa-facebook-square text-dark"></i>
643 <u>facebook</u>
644 </a>
645 </#if>
646
647 <#if doc.contacts.getJSONObject(0).socialRefs.twitter?? && doc.contacts.getJSONObject(0).socialRefs.twitter?has_content>
648 <a href="${doc.contacts.getJSONObject(0).socialRefs.twitter[langId]}" class="block no-underline text-dark text-lg space-x-2 mb-0" target="_blank">
649 <i class="fab fa-twitter-square text-dark"></i>
650 <u>twitter</u>
651 </a>
652 </#if>
653
654 <#if doc.contacts.getJSONObject(0).socialRefs.instagram?? && doc.contacts.getJSONObject(0).socialRefs.instagram?has_content>
655 <a href="${doc.contacts.getJSONObject(0).socialRefs.instagram[langId]}" class="block no-underline text-dark text-lg space-x-2 mb-0" target="_blank">
656 <i class="fab fa-instagram-square text-dark"></i>
657 <u>instagram</u>
658 </a>
659 </#if>
660 </div>
661 </div>
662 </div>
663 </div>
664 </section> -->
665
666 <#-- SEZIONE NON USATA
667 <section class="mt-10">
668 <div class="container">
669 <p class="text-dark uppercase text-lg lg:text-3xl mb-7"> Info sezione </p>
670 <p class="text-dark text-lg font-light mb-0"> Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. </p>
671 </div>
672 </section>
673 -->
674 <#else>
675 <div class="text-center mt-35">
676 <p class="text-dark">
677 ${d40.getLabel("errore_caricamento_contenuto")}
678 </p>
679 </div>
680 </#if>
681</div>
682
683<script type="module">
684 import { createApp } from "https://cdnjs.cloudflare.com/ajax/libs/petite-vue/0.4.1/petite-vue.es.min.js";
685
686 createApp({
687 isMobile: window.innerWidth < 768,
688 favorites: [],
689 getFavorites() {
690 if(localStorage.getItem("favorites") !== null) {
691 this.favorites = JSON.parse(localStorage.getItem("favorites"));
692 }
693 },
694 setFavorite(e, item) {
695 e.preventDefault();
696 this.getFavorites();
697
698 var newFavorite = {
699 id: item.id,
700 contentJSON: {
701 title: item.contentJSON.title,
702 previewDescription: item.contentJSON.previewDescription,
703 description: item.contentJSON.description,
704 geoRef: item.contentJSON.geoRef,
705 previewPicture: item.contentJSON.previewPicture,
706 viewUrl: item.contentJSON.viewUrl,
707 type: "lfr",
708 }
709 };
710
711 this.favorites.push(newFavorite);
712 this.saveFavorites();
713 },
714 removeFavorite(e, itemId) {
715 e.preventDefault();
716 this.favorites = this.favorites.filter((obj) => obj.id !== itemId);
717 this.saveFavorites();
718 },
719 saveFavorites() {
720 localStorage.setItem("favorites", JSON.stringify(this.favorites));
721 },
722 isFavorite(itemId) {
723 if (this.favorites.some((e) => e.id == itemId)) {
724 return true;
725 }
726
727 return false;
728 },
729 buildMap(lat, lng) {
730 var map = new SuggestoMap("suggesto-map"),
731 location = [parseFloat(lat), parseFloat(lng)];
732
733 var svgIcon = L.divIcon({
734 html: `
735 <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 44.537 64.343">
736 <path d="M32.952,68c-4.491-5.935-9.221-11.692-12.837-18.251-3.4-6.175-5.892-12.453-4.094-19.725,2.422-9.787,12.253-17.363,22.112-16.878,11.322.558,20.189,8.638,21.649,19.385.8,5.867-1.25,10.892-3.84,15.837A105.38,105.38,0,0,1,43.958,65.889c-.687.844-1.309,1.739-1.96,2.611-.953,1.06-1.971,2.068-2.841,3.191-.965,1.245-1.729,1.629-2.844.1A50.506,50.506,0,0,0,32.952,68m4.722-46.328A14.156,14.156,0,0,0,23.76,35.59c-.168,7.053,6.542,13.748,13.813,13.783A14.234,14.234,0,0,0,51.46,35.693,14.138,14.138,0,0,0,37.674,21.676" transform="translate(-15.419 -13.129)" fill="#5098c6"/>
737 <path d="M31.941,63.206A50.288,50.288,0,0,1,35.3,67c1.116,1.526,1.878,1.142,2.844-.1.87-1.123,1.889-2.132,2.841-3.191a8.579,8.579,0,0,1,5.414,2.22c1.659,1.642,1.586,3.631-.455,4.627a21.209,21.209,0,0,1-16.871.723c-1.611-.565-3.293-1.51-3.092-3.645.19-2.018,1.855-2.718,3.511-3.342.833-.315,1.791-.363,2.447-1.079" transform="translate(-14.408 -8.331)" fill="#222"/>
738 <path d="M36.946,20.929A14.137,14.137,0,0,1,50.732,34.944,14.236,14.236,0,0,1,36.844,48.626c-7.27-.036-13.98-6.732-13.813-13.783A14.157,14.157,0,0,1,36.946,20.929m-.023,5.445a8.4,8.4,0,1,0,8.394,8.22,8.5,8.5,0,0,0-8.394-8.22" transform="translate(-14.69 -12.381)" fill="#fdfcf9"/>
739 <path d="M36.45,25.9a8.4,8.4,0,0,1,.077,16.809A8.405,8.405,0,1,1,36.45,25.9" transform="translate(-14.218 -11.905)" fill="#222"/>
740 </svg>`,
741 className: "",
742 iconSize: [44.537, 64.343],
743 iconAnchor: [22.287, 64.343],
744 });
745
746 var mapData = {
747 tilelayer: "osm",
748 gestureHandling: true,
749 fitBounds: false,
750 mapcenter: location,
751 zoom: 15,
752 markersFilter: "*",
753 markers: [],
754 layers: []
755 };
756
757 map.sm.createMap(mapData);
758
759 L.circleMarker(location, {
760 radius: 0,
761 color: "#000",
762 fillOpacity: 0,
763 weight: 0
764 }).addTo(map.sm.lmap);
765
766 L.marker(location, {
767 icon: svgIcon
768 }).addTo(map.sm.lmap);
769 },
770 share(title, desc, mode = "legacy") {
771 if (this.isMobile) {
772 var shareData = {
773 title: title,
774 text: desc,
775 url: window.location.href.replaceAll("{", "%7B").replaceAll("}", "%7D")
776 };
777
778 try {
779 navigator.share(shareData);
780 } catch (err) {
781 console.error("Error sharing: " + err);
782
783 if (mode == "legacy") {
784 this.legacyShare();
785 } else if (mode == "social") {
786 this.socialShare(title, desc);
787 }
788 }
789 } else {
790 if (mode == "legacy") {
791 this.legacyShare();
792 } else if (mode == "social") {
793 this.socialShare(title, desc);
794 }
795 }
796 },
797 legacyShare() {
798 var clip = document.createElement("input"),
799 toCopy = window.location.href.replaceAll("{", "%7B").replaceAll("}", "%7D");
800
801 document.body.appendChild(clip);
802 clip.value = toCopy;
803 clip.select();
804 clip.setSelectionRange(0, 999999);
805
806 navigator.clipboard.writeText(clip.value);
807 document.body.removeChild(clip);
808
809 alert("Link copiato");
810 },
811 socialShare(title, desc, image = "") {
812 var link = "#",
813 winHeight = 450,
814 winWidth = 600,
815 winTop = window.screen.height / 2 - winHeight / 2,
816 winLeft = window.screen.width / 2 - winWidth / 2,
817 params = "scrollbars=no,resizable=no,status=no,location=no,toolbar=no,menubar=no,width=" + winWidth + ",height=" + winHeight + ",left=" + winLeft + ",top=" + winTop;
818
819 link = "http://www.facebook.com/sharer.php?s=100&p[title]=" + encodeURIComponent(title) + "&p[summary]=" + encodeURIComponent(desc) + "&p[url]=" + window.location.href + "&p[images][0]=" + image;
820
821 window.open(link, "Facebook", params);
822 }
823 }).mount("#${d40.portletNamespace}");
824</script>
825
826<#if doc?has_content>
827 <script>
828 document.addEventListener("DOMContentLoaded", function(){
829
830 document.querySelectorAll('a[href^="#contact"]').forEach(anchor => {
831 anchor.addEventListener('click', function (e) {
832 e.preventDefault();
833
834 document.querySelector(this.getAttribute('href')).scrollIntoView({
835 behavior: 'smooth'
836 });
837 });
838 });
839
840
841 if(${(doc.details.images?has_content)?c}){
842 new Swiper("#gallery .swiper-container", {
843 slidesPerView: 1,
844 spaceBetween: 50,
845 centerSlides: true,
846 centerInsufficientSlides: true,
847 breakpoints: {
848 768: {
849 slidesPerView: 2,
850 spaceBetween: 25
851 },
852 992: {
853 slidesPerView: 3,
854 spaceBetween: 25
855 }
856 },
857 navigation: {
858 prevEl: "#gallery .btn-prev",
859 nextEl: "#gallery .btn-next"
860 }
861 });
862
863 var thumbnails = new Swiper("#thumbnail-swiper", {
864 spaceBetween: 10,
865 slidesPerView: 2,
866 centerInsufficientSlides: true,
867 freeMode: true,
868 watchSlidesVisibility: true,
869 watchSlidesProgress: true,
870 breakpoints: {
871 768: {
872 slidesPerView: 3
873 },
874 992: {
875 slidesPerView: 4
876 },
877 1200: {
878 slidesPerView: 5
879 }
880 },
881 });
882
883 var lightbox = new Swiper("#lightbox-swiper", {
884 spaceBetween: 10,
885 autoHeight: true,
886 observer: true,
887 observeSlideChildren: true,
888 keyboard: {
889 enabled: true
890 },
891 navigation: {
892 nextEl: ".swiper-button-next",
893 prevEl: ".swiper-button-prev"
894 },
895 thumbs: {
896 swiper: thumbnails
897 }
898 });
899
900 $("#lightbox-modal").on("shown.bs.modal", function(e){
901 lightbox.update();
902 thumbnails.update();
903 lightbox.slideTo($(e.relatedTarget).data("slider"));
904 lightbox.update();
905 });
906
907 $("#lightbox-modal .swiper-wrapper").on("click", function(e){
908 if($(e.target).attr("class").includes("swiper-slide")){
909 $("#lightbox-modal").modal("hide");
910 }
911 });
912
913 if ($(window).width() > 991) {
914 var left_col_h = $(".relative.mt-20 > .container > .row > .col-lg-7").outerHeight();
915 var right_col_h = $(".relative.mt-20 > .container > .row > .col-lg-5").outerHeight();
916 var marg_h = right_col_h - left_col_h + 40;
917
918 if(right_col_h > left_col_h)
919 {
920 $('#gallery').removeClass('lg:mt-40 mt-20');
921 $('#gallery').css({'margin-top':marg_h+'px'});
922 }
923 }
924 }
925 });
926 </script>
927</#if>
L'invio della richiesta è andata a buon fine
L'invio della richiesta non è andata a buon fine
Acconsento al passaggio dei miei dati personali al destinatario della mia richiesta per l'invio delle informazioni richieste (privacy policy)