08/29/2024

Miguel

Summary title

Content title

Btn mobile

Related news

处理模板时发生错误。
The following has evaluated to null or missing:
==> entry  [in template "20115#20151#3617708" at line 24, column 58]

----
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 title = entry.getTitle(locale...  [in template "20115#20151#3617708" at line 24, column 41]
----
1<#assign currentLayoutHTMLTitle=layout.getHTMLTitle(locale) /> 
2<#assign PortalUtil=staticUtil["com.liferay.portal.kernel.util.PortalUtil"] /> 
3<#assign url=PortalUtil.getCurrentCompleteURL(request) /> 
4<#assign currentLayoutHTMLTitle=layout.getHTMLTitle(locale) /> 
5<#assign currentLayoutHTMLDescription=layout.getDescription(locale) /> 
6<#assign portletDisplay=themeDisplay.getPortletDisplay()> 
7  <#assign assetInstanceId=portletDisplay.getInstanceId()> 
8    <@liferay_portlet["runtime"] 
9      portletName="com_liferay_journal_content_web_portlet_JournalContentPortlet" 
10      instanceId="${groupId}${assetInstanceId}${companyId}" /> 
11    <section class="cards-news"> 
12      <script type="application/ld+json"> 
13
14        "@context": "https://schema.org", 
15        "@type": "BlogEntryList", 
16        "mainEntity": [ < 
17          #list entries as entry > 
18
19          #assign renderer = entry.getAssetRenderer() / > 
20
21          #assign className = renderer.getClassName() / > 
22
23          #if(className == "com.liferay.journal.model.JournalArticle") >       
24					<#assign title = entry.getTitle(locale)!""> 
25
26          #assign summary = entry.getSummary(locale)!"" / > 
27
28          #assign journalArticle = renderer.getArticle() / > 
29
30          #assign miniImageId = journalArticle.getSmallImageId() > 
31
32          #if miniImageId ? has_content > 
33
34          #assign miniImageURL = "/image/image_gallery?img_id=" + miniImageId > 
35
36          #else > 
37
38          #assign miniImageURL = journalArticle.getSmallImageURL() > 
39
40          /#if> < 
41          #assign creationDate = journalArticle.getCreateDate() ? date / > { 
42            "@type": "Article", 
43            "name": "${title}", 
44            "content": { 
45              "headline": "${title}", 
46              "description": "${htmlUtil.stripHtml(summary!"")}", 
47              "image": "${miniImageURL!""}", 
48              "author": { 
49                "@type": "Organization", 
50                "name": "AXA Assistance" 
51              }, 
52              "publisher": { 
53                "@type": "Organization", 
54                "name": "AXA Assistance", 
55                "logo": { 
56                  "@type": "ImageObject", 
57                  "url": "" 
58
59                "datePublished": "${creationDate!""}" 
60
61
62          } < 
63          /#if> < 
64          /#list> 
65
66
67      </script> 
68      <!-- article  --> 
69      <#if entries?has_content> 
70        <div class="cards-news__cards-group"> 
71          <#list entries as entry> 
72            <#assign renderer=entry.getAssetRenderer() /> 
73            <#assign className=renderer.getClassName() /> 
74            <#if (className=="com.liferay.journal.model.JournalArticle" )> 
75              <#assign title=entry.getTitle(locale) /> 
76              <#assign summary=entry.getSummary(locale) /> 
77              <#assign link_more=assetPublisherHelper.getAssetViewURL(renderRequest, renderResponse, entry, true)?split("?")[0] /> 
78              <#assign journalArticle=renderer.getArticle() /> 
79              <#assign miniImageId=journalArticle.getSmallImageId()> 
80                <#assign userLocale=localeUtil.getDefault()> 
81                  <#if userLocale=="en_US"> 
82                    <#assign displayDateFormatted=journalArticle.getCreateDate()?string('MM/dd/yyyy') /> 
83                    <#else> 
84                      <#assign displayDateFormatted=journalArticle.getCreateDate()?string('dd/MM/yyyy') /> 
85                  </#if> 
86                  <#if miniImageId?has_content> 
87                    <#assign miniImageURL="/image/image_gallery?img_id=" +miniImageId> 
88                      <#else> 
89                        <#assign miniImageURL=journalArticle.getSmallImageURL()> 
90                  </#if> 
91                  <a class="cards-news__card" href="${link_more}"> 
92                    <figure class="cards-news__image-container"> 
93                      <#if miniImageURL?has_content> 
94                        <img class="cards-news__image lazyload" alt="${title}" data-src="${miniImageURL}" src="${miniImageURL}" /> 
95                      </#if> 
96                    </figure> 
97                    <div class="cards-news__summary-info"> 
98                      <h2 class="cards-news__title"> 
99                        ${title} 
100                      </h2> 
101                      <p class="cards-news__summary"> 
102                        ${htmlUtil.stripHtml(summary)} 
103                      </p> 
104                      <span class="cards-news__link"> 
105                        <@liferay.language key="read-more" /> <i class="icon-navigate_next" aria-hidden="true"></i> 
106                      </span> 
107                    </div> 
108                    <div class="cards-news__info"> 
109                      <span class="cards-news__time"> 
110                        ${displayDateFormatted} 
111                      </span> 
112                    </div> 
113                  </a> 
114            </#if> 
115          </#list> 
116        </div> 
117      </#if> 
118    </section> 
119    <script type="text/javascript"> 
120    function pushDataLayerBlogArticles(url, contentName) { 
121      var linkType = isInternalUrl(url); 
122      dataLayer.push({ 
123        "event": "select_content", 
124        'content_type': 'blog', 
125        'content_name': contentName, 
126        'link_type': linkType, 
127        'link_href': url, 
128        'ipAddress': themeDisplay.getRemoteAddr() 
129      }); 
130
131    </script> 
Buton label to asset publisher page