Briciole di pane

Si è verificato un errore nell'elaborarazione del modello.
The following has evaluated to null or missing:
==> pebService.getEvento(cur_URI.getData())  [in template "37601#37631#64377" at line 220, column 51]

----
Tip: If the failing expression is known to 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 pebObj = pebService.getEvento...  [in template "37601#37631#64377" at line 220, column 33]
----
1<#assign PortalUtil = staticUtil["com.liferay.portal.kernel.util.PortalUtil"] /> 
2<#assign VOID = PortalUtil.addPortletBreadcrumbEntry(request, Titolo.getData()?truncate(60, '...'), '', null, false)/> 
3 
4<#assign pebService = serviceLocator.findService("it.inera.peb.api.service.PEBService") /> 
5<#assign  
6    serviceContext = staticUtil["com.liferay.portal.kernel.service.ServiceContextThreadLocal"].getServiceContext() 
7    themeDisplay = serviceContext.getThemeDisplay() 
8    group_id = themeDisplay.getScopeGroupId()                     
9    JournalArticleLocalService = serviceLocator.findService("com.liferay.journal.service.JournalArticleLocalService") 
10    virgola = "" 
11
12 
13<div class="container"> 
14    <div class="row mb-5"> 
15        <div class="col-12 mb-2"> 
16          <div class="title-block title-block-1 title-block-1-2 title-block-1-2-2"> 
17            <div class="title-block-title">${Titolo.getData()}</div> 
18            <#assign hasAuthors = false> 
19            <#if WebContent28z8?? && WebContent28z8.getSiblings()?has_content> 
20                <span> 
21            	<#list WebContent28z8.getSiblings() as cur_bio> 
22            		<#assign 
23            			webContentData = jsonFactoryUtil.createJSONObject(cur_bio.getData()) 
24            		/> 
25            		<#if cur_bio.getData()?has_content && cur_bio.getData()?trim != ""> 
26            		<#assign  
27            		    hasAuthors = true 
28                        cur_webContent_map = cur_bio.getData()?eval 
29                        cur_webContent_classPK = cur_webContent_map.classPK 
30                        article = JournalArticleLocalService.getLatestArticle(cur_webContent_classPK?number) 
31                        langId = themeDisplay.getLanguageId() 
32                        contentByLocale = article.getContentByLocale(langId) 
33                        ddms_structure = article.getDDMStructure().getName() 
34                        document = saxReaderUtil.read(contentByLocale) 
35                        rootElement = document.getRootElement() 
36                        xPathNome = saxReaderUtil.createXPath("dynamic-element[@name='Nome']") 
37                        nome = xPathNome.selectSingleNode(rootElement).getStringValue() 
38
39                	${virgola}<a  style="font-size:1.5rem;" data-toggle="collapse" href="#BIO${cur_webContent_classPK}" role="button" aria-expanded="false" aria-controls="${cur_webContent_classPK}">${nome?trim}</a> 
40                    <#assign virgola = ", "/> 
41                    </#if> 
42            	</#list> 
43            	</span> 
44            	<#list WebContent28z8.getSiblings() as cur_bio> 
45            		<#assign 
46            			webContentData = jsonFactoryUtil.createJSONObject(cur_bio.getData()) 
47            		/> 
48            		<#if cur_bio.getData()?has_content && cur_bio.getData()?trim != ""> 
49            		<#assign  
50                        cur_webContent_map = cur_bio.getData()?eval 
51                        cur_webContent_classPK = cur_webContent_map.classPK 
52                        article = JournalArticleLocalService.getLatestArticle(cur_webContent_classPK?number) 
53                        langId = themeDisplay.getLanguageId() 
54                        contentByLocale = article.getContentByLocale(langId) 
55                        ddms_structure = article.getDDMStructure().getName() 
56                        document = saxReaderUtil.read(contentByLocale) 
57                        rootElement = document.getRootElement() 
58                        xPathNome = saxReaderUtil.createXPath("dynamic-element[@name='Nome']") 
59                        nome = xPathNome.selectSingleNode(rootElement).getStringValue() 
60                        xPathBio = saxReaderUtil.createXPath("dynamic-element[@name='Biografia']") 
61                        bio = xPathBio.selectSingleNode(rootElement).getStringValue() 
62                        xPathLink = saxReaderUtil.createXPath("dynamic-element[@name='Link']") 
63                        link = xPathLink.selectSingleNode(rootElement).getStringValue() 
64                        xPathImmagine = saxReaderUtil.createXPath("dynamic-element[@name='Immagine2696']") 
65                         
66
67                    <#if xPathImmagine?? && xPathImmagine?has_content && xPathImmagine?trim != ""> 
68	    		       	<#if xPathImmagine.selectSingleNode(rootElement)?? && xPathImmagine.selectSingleNode(rootElement)?has_content> 
69							<#assign imgPartner = xPathImmagine.selectSingleNode(rootElement).getStringValue()> 
70						</#if> 
71					</#if> 
72    		         
73    		        <#if imgPartner?? && imgPartner?has_content && imgPartner?trim != ""> 
74	    		        <#assign imgJson = jsonFactoryUtil.createJSONObject(imgPartner)> 
75	    		        <#if imgJson?? && imgJson?has_content > 
76		    		        <#assign urlImmagine = "/documents/"+ imgJson.groupId +"/" +imgJson.classPK +"/"+ imgJson.title +"/"+imgJson.uuid > 
77                    	</#if> 
78                	</#if> 
79                    <div class="collapse" id="BIO${cur_webContent_classPK}" style="width:100%"> 
80                        <div class="row"> 
81                            <div class="col-12 col-8"> 
82                            <div class="card card-1 bsh-1"> 
83                                <div class="card-body"> 
84                                  <#if urlImmagine?? && urlImmagine?has_content && urlImmagine?trim != ""> 
85                                            <div class="card-body-left"> 
86                                                <div class="image"><img src="${urlImmagine}" alt=""></div> 
87                                            </div> 
88                                            <div class="card-body-right" style="max-height: none;"> 
89                                                <div class="card-title">${nome}</div> 
90                                                <div class="card-text"  style="max-height: none;" > 
91                                                    <#if bio?? && bio?has_content && bio?trim != ""> 
92                                                        ${bio} 
93                                                    <#else> 
94                                                        Biografia non disponibile. 
95                                                    </#if> 
96                                                </div> 
97                                                <#if link?? && link?has_content && link?trim != ""> 
98                                                    <div class="card-action">Per approfondire segui il<a href="${link}" target="_BLANK"> link &gt;</a></div> 
99                                                </#if> 
100                                            </div> 
101                                  <#else> 
102                                    <div class="card-body-right" style="max-height: none;min-height: 0rem"> 
103                            					<div class="card-title"> 
104                            							${nome} 
105                            					</div> 
106                            				<div class="card-text"> 
107                            					<#if bio?? && bio?has_content && bio?trim != ""> 
108                                                    ${bio} 
109                                                <#else> 
110                                                    Biografia non disponibile. 
111                                                </#if> 
112                            				</div> 
113                            				<#if link?? && link?has_content && link?trim != ""> 
114                                                <div class="card-action">Per approfondire segui il<a href="${link}" target="_BLANK"> link &gt;</a></div> 
115                                            </#if> 
116                                    </div> 
117                                  </#if> 
118                                   
119                                 
120                                    </div> 
121                                </div> 
122                               
123                            </div> 
124                          </div> 
125                    </div> 
126                    </#if> 
127            	</#list> 
128            </#if> 
129            <#if !hasAuthors && (Autore.getData())?? && Autore.getData()?trim != ""> 
130                <div class="title-block-text" style="font-size: 1.5rem">${Autore.getData()}</div> 
131            </#if> 
132            <div class="title-block-text">${Anno.getData()}</div> 
133          </div> 
134        </div> 
135    </div> 
136    <div class="row mb-4"> 
137        <div class="col-12 col-md-7"> 
138          <div class="text-block"> 
139            <!-- div style="padding-bottom:10px;"><i>Di seguito l'inizio del testo. Per approfondire scarica il file in formato pdf.</i></div --> 
140            ${Incipit.getData()} 
141          </div> 
142          <#assign itemCount = 0 > 
143          <#if Documento.getSiblings()?has_content> 
144            	<#list Documento.getSiblings() as cur_Documento> 
145                	<#assign counter = 0 > 
146                	<#assign groupId = 0 > 
147                	<#assign uuId = "" > 
148                    <#list cur_Documento.getData()?split("/") as x> 
149                        <#if counter == 2> 
150                            <#assign groupId = x?number > 
151                        </#if> 
152                        <#if counter == 5> 
153                            <#assign uuId = x > 
154                            <#assign cy = 0 > 
155                            <#list x?split("?") as y> 
156                            <#if cy == 0> 
157                                <#assign uuId = y > 
158                            </#if> 
159                            <#assign cy = cy+1 > 
160                            </#list> 
161                        </#if> 
162                        <#assign counter = counter + 1 > 
163                    </#list> 
164                    <#assign docService = serviceLocator.findService("com.liferay.document.library.kernel.service.DLAppLocalService")> 
165                    <#if groupId?? && uuId?? && uuId != "" && docService?? > 
166                        <#assign fileEntry = docService.getFileEntryByUuidAndGroupId(uuId, groupId)> 
167                    </#if> 
168                    <#if fileEntry?? > 
169                        <#if itemCount == 0 > 
170                            <div class="row mb-3"> 
171                                <div class="col-12 title-block title-block-2 title-block-2-1"> 
172                                  <div class="title-block-title">LEGGI IL DOCUMENTO COMPLETO</div> 
173                                </div> 
174                            </div> 
175                        </#if> 
176                        <div class="row"> 
177                            <div class="col-12"> 
178                              <div class="card card-10"> 
179                                <div class="card-header"> 
180                                  <div class="card-icon"> 
181                                    <div class="card-icon-arrow"></div> 
182                                    <div class="card-type">${fileEntry.extension}</div> 
183                                  </div> 
184                                </div> 
185                                <div class="card-body"> 
186                                  <div class="card-title">${fileEntry.title}</div> 
187                                  <div class="card-info">Dimensione File: ${(fileEntry.size/1024)?int} KB</div><a class="card-action" target="_blank" href="${cur_Documento.getData()}">Scarica il file</a> 
188                                </div> 
189                              </div> 
190                            </div> 
191                          </div> 
192                        <div class="py-1"></div> 
193                    </#if> 
194                    <#assign itemCount = itemCount + 1 > 
195            	</#list> 
196            </#if> 
197        </div> 
198        <div class="col-12 col-md-4 offset-md-1"> 
199            <#if Immagine5t7d.getSiblings()?has_content> 
200            	<#list Immagine5t7d.getSiblings() as cur_Immagine5t7d> 
201            		<#if (cur_Immagine5t7d.getData())?? && cur_Immagine5t7d.getData() != ""> 
202            			<img class="img-fluid"  alt="${cur_Immagine5t7d.getAttribute("alt")}" data-fileentryid="${cur_Immagine5t7d.getAttribute("fileEntryId")}" src="${cur_Immagine5t7d.getData()}" /> 
203            		    <div class="py-4"></div> 
204            		</#if> 
205            	</#list> 
206            </#if> 
207             
208            	<#if URI.getSiblings()?has_content> 
209            	    <#assign fatti = 0> 
210                	<#list URI.getSiblings() as cur_URI> 
211                	    <#if cur_URI.getData()?trim != ""> 
212                	        <#if fatti == 0> 
213                        	    <div class="col-12 mb-3 mt-4"> 
214                                    <div class="title-block title-block-2 title-block-2-1"> 
215                                      <div class="title-block-title">FATTI STORICI</div> 
216                                    </div> 
217                                </div> 
218                                <#assign fatti = 1> 
219                            </#if> 
220                    		<#assign pebObj = pebService.getEvento(cur_URI.getData())> 
221                    		<#if pebObj??> 
222                        		<div class="row"> 
223                                    <div class="col-12 mb-4"><a class="card card-9" href="/c/history/view?id=${pebObj.id?url('ISO-8859-1')}&title=${pebObj.nome?url('ISO-8859-1')}"> 
224                                        <#if pebObj.immagine?? && pebObj.immagine?has_content> 
225                                            <div class="card-header"> 
226                                                      <div class="image"> 
227                                                        <img src="${pebObj.immagine}" alt="Immagine: ${pebObj.nome}"> 
228                                                      </div> 
229                                            </div> 
230                                        </#if> 
231                                        <div class="card-body"> 
232                                          <div class="card-title-block"> 
233                                            <div class="card-title" data-simple-ellipsis="">${pebObj.nome}</div> 
234                                            <div class="card-info">${pebObj.data}</div> 
235                                          </div> 
236                                          <div class="card-text-block"> 
237                                            <div class="card-text" data-simple-ellipsis="">${pebObj.abstractT}</div> 
238                                          </div> 
239                                        </div> 
240                                        <div class="card-footer"> 
241                                          <div class="card-action">Leggi tutto ></div> 
242                                        </div></a> 
243                                    </div> 
244                                </div> 
245                    		</#if> 
246                		</#if> 
247                	</#list> 
248                </#if> 
249            <div class="py-4"></div> 
250        </div> 
251    </div> 
252</div>