Reports Parent Detail Page - RBI - Reserve Bank of India
An error occurred while processing the template.
The following has evaluated to null or missing: ==> WebContentEntry [in template "20099#20125#40906901" at line 144, column 97] ---- 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: #if dateSectionExcelUUID?has_content ... [in template "20099#20125#40906901" at line 143, column 89] ----
1<#assign
2 AssetEntryLocalServiceUtil=serviceLocator.findService("com.liferay.asset.kernel.service.AssetEntryLocalService")
3 DLFileEntryLocalService=serviceLocator.findService("com.liferay.document.library.kernel.service.DLFileEntryLocalService")
4 />
5<#assign webContentData=jsonFactoryUtil.createJSONObject(FieldsGroup98067563.CHILD_WEBCONTENT.getData()) />
6<#assign CONTENT_PUBLISH_DATE_Data=getterUtil.getString(CONTENT_PUBLISH_DATE.getData())>
7
8 <#if validator.isNotNull(CONTENT_PUBLISH_DATE_Data)>
9 <#assign CONTENT_PUBLISH_DATE_DateObj=dateUtil.parseDate("yyyy-MM-dd", CONTENT_PUBLISH_DATE_Data, locale)>
10 </#if>
11
12 <div class="Notification-content-wrap research_and_publications publication-handbook full-width" tabindex="0">
13 <div class="container">
14 <div class="row block-section-spacing">
15 <div class="col-12">
16 <div class="notifications-page-header full-width">
17 <h3 class="section-heading pb-section-heading">
18 <#if validator.isNotNull(CONTENT_PUBLISH_DATE_Data)>
19 <#assign CONTENT_PUBLISH_DATE_DateObj=dateUtil.parseDate("yyyy-MM-dd",
20 CONTENT_PUBLISH_DATE_Data, locale)>
21 ${dateUtil.getDate(CONTENT_PUBLISH_DATE_DateObj, "MMMM dd, yyyy", locale)}
22 </#if>
23 </h3>
24 </div>
25 </div>
26
27 <div class="col-12">
28 <div class="notifications-row-wrapper">
29 <div class="row">
30 <#if (FieldsGroup98067563.getSiblings())?has_content>
31 <#list FieldsGroup98067563.getSiblings() as childReport>
32 <#if (childReport.getData())??>
33 <#assign
34 webContentData=jsonFactoryUtil.createJSONObject(childReport.CHILD_WEBCONTENT.getData()) />
35 <#if webContentData?? && webContentData.title??>
36 <#if
37 AssetEntryLocalServiceUtil.fetchEntry(webContentData.className,webContentData.classPK?number)??>
38 <#assign dateSectionUUID="" dateSectionPdfURL=""
39 dateSectionPdffileSize="" dateSectionDocUUID="" dateSectionDocURL=""
40 dateSectionDocFileSize="" dateSectionExcelUUID=""
41 dateSectionExcelURL="" dateSectionExcelFileSize=""
42 dateSectionWebContentEntry=AssetEntryLocalServiceUtil.fetchEntry(webContentData.className,webContentData.classPK?number)
43 dateSectionWebContentArticle=dateSectionWebContentEntry.getAssetRenderer().getArticle()
44 Childcontent=saxReaderUtil.read(dateSectionWebContentArticle.getContentByLocale(locale))
45 groupId=themeDisplay.getScopeGroupId()
46 title=Childcontent.valueOf("//dynamic-element[@name='Text97087370'
47 ]/dynamic-content")
48 viewURL=childReport.CHILD_WEBCONTENT.getFriendlyUrl()
49 dateSectionURL=dateSectionWebContentArticle.getExpandoBridge().getAttribute("pdf-url")
50 dateSectionDoc=dateSectionWebContentArticle.getExpandoBridge().getAttribute("doc-url")
51 dateSectionExcel=dateSectionWebContentArticle.getExpandoBridge().getAttribute("excel-url") />
52 </#if>
53 <#if dateSectionURL?has_content>
54 <#list dateSectionURL?keys as key>
55 <#if key==locale>
56 <#assign dateSectionPdfURL=dateSectionURL?values[key_index] />
57 </#if>
58 </#list>
59 </#if>
60
61 <#if dateSectionPdfURL?has_content>
62 <#list dateSectionPdfURL?split("/") as sValue>
63 <#if sValue?is_last>
64 <#list sValue?split("?") as uuid>
65 <#if uuid?is_first>
66 <#assign dateSectionUUID=uuid />
67 </#if>
68 </#list>
69 </#if>
70 </#list>
71 </#if>
72
73 <#if dateSectionWebContentEntry??>
74 <#if dateSectionUUID?has_content &&
75 dateSectionWebContentEntry.getClassName()=="com.liferay.journal.model.JournalArticle">
76 <#attempt>
77 <#assign
78 DLFileEntry=DLFileEntryLocalService.fetchFileEntry(dateSectionUUID,groupId?number)
79 dateSectionPdffileSize=DLFileEntry.getSize()
80 fileAssetEntry=AssetEntryLocalServiceUtil.getEntry("com.liferay.document.library.kernel.model.DLFileEntry",DLFileEntry.getFileEntryId())
81 dateSectionPdfURL=fileAssetEntry.getAssetRenderer().getURLDownload(themeDisplay)
82 dateSectionPdfURL=dateSectionPdfURL?replace("/"+dateSectionUUID,"") />
83 <#recover>
84 </#attempt>
85 </#if>
86 </#if>
87
88 <#if dateSectionDoc?has_content>
89 <#list dateSectionDoc?keys as key>
90 <#if key==locale>
91 <#assign dateSectionDocURL=dateSectionDoc?values[key_index] />
92 </#if>
93 </#list>
94 </#if>
95
96 <#if dateSectionDocURL?has_content>
97 <#list dateSectionDocURL?split("/") as sValue>
98 <#if sValue?is_last>
99 <#list sValue?split("?") as uuid>
100 <#if uuid?is_first>
101 <#assign dateSectionDocUUID=uuid />
102 </#if>
103 </#list>
104 </#if>
105 </#list>
106 </#if>
107
108 <#if dateSectionWebContentEntry??>
109 <#if dateSectionDocUUID?has_content &&
110 dateSectionWebContentEntry.getClassName()=="com.liferay.journal.model.JournalArticle">
111 <#attempt>
112 <#assign
113 DLFileEntry=DLFileEntryLocalService.fetchFileEntry(dateSectionDocUUID,groupId?number)
114 dateSectionDocFileSize=DLFileEntry.getSize()
115 fileAssetEntry=AssetEntryLocalServiceUtil.getEntry("com.liferay.document.library.kernel.model.DLFileEntry",DLFileEntry.getFileEntryId())
116 dateSectionDocURL=fileAssetEntry.getAssetRenderer().getURLDownload(themeDisplay) />
117 <#recover>
118 </#attempt>
119 </#if>
120 </#if>
121
122 <#if dateSectionExcel?has_content>
123 <#list dateSectionExcel?keys as key>
124 <#if key==locale>
125 <#assign
126 dateSectionExcelURL=dateSectionExcel?values[key_index] />
127 </#if>
128 </#list>
129 </#if>
130
131 <#if dateSectionExcelURL?has_content>
132 <#list dateSectionExcelURL?split("/") as sValue>
133 <#if sValue?is_last>
134 <#list sValue?split("?") as uuid>
135 <#if uuid?is_first>
136 <#assign dateSectionExcelUUID=uuid />
137 </#if>
138 </#list>
139 </#if>
140 </#list>
141 </#if>
142
143 <#if dateSectionExcelUUID?has_content &&
144 WebContentEntry.getClassName()=="com.liferay.journal.model.JournalArticle">
145 <#attempt>
146 <#assign
147 DLFileEntry=DLFileEntryLocalService.fetchFileEntry(dateSectionExcelUUID,groupId?number)
148 dateSectionExcelFileSize=DLFileEntry.getSize()
149 fileAssetEntry=AssetEntryLocalServiceUtil.getEntry("com.liferay.document.library.kernel.model.DLFileEntry",DLFileEntry.getFileEntryId())
150 dateSectionExcelURL=fileAssetEntry.getAssetRenderer().getURLDownload(themeDisplay) />
151 <#recover>
152 </#attempt>
153 </#if>
154
155
156
157
158 <div class="col-12">
159 <div class="notification-row-each">
160 <div class="notification-row-each-inner">
161 <div
162 class="notifications-heading cursor-no-link c-tooltips position-relative">
163 <a href="${viewURL}"><span class="truncatedContent">
164 ${title}</span></a>
165 </div>
166 <div class="btn-wrap">
167 <#if dateSectionPdfURL?? && dateSectionPdfURL?has_content>
168 <div class="inner-wrap">
169 <#if dateSectionPdffileSize?has_content>
170 <a href="${dateSectionPdfURL?split('?')[0]}"
171 target="_blank" class="matomo_download ">
172 <img src="/documents/70233/0/fileDownload.svg"
173 class="downloadFile" alt="${languageUtil.get(locale,'download')}"
174 title="${languageUtil.get(locale,'download')}">
175 <#if dateSectionPdffileSize?? && dateSectionPdffileSize?has_content>
176 ${languageUtil.get(locale,"pdf")}
177 (<span class="fileSize">${dateSectionPdffileSize}</span>)
178 </#if>
179 </a>
180 </#if>
181 </div>
182 </#if>
183 </div>
184 </div>
185 </div>
186 </div>
187
188
189
190
191 </#if>
192 </#if>
193 </#list>
194 </#if>
195 </div>
196 </div>
197 </div>
198 </div>
199 </div>
200 </div>
201
202
203
204
205
206
207<script>
208$(document).ready(function () {
209 $(".fileSize").each(function () {
210 var fileSize = $(this).html()
211 if (fileSize != "") {
212 $(this).html(formatFileSize(parseInt(fileSize), 2))
213 }
214 });
215
216 function formatFileSize(bytes, decimalPoint) {
217 if (bytes == 0)
218 return '0 Bytes';
219 var k = 1024,
220 dm = decimalPoint || 2,
221 sizes = ['KB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB'],
222 i = Math.floor(Math.log(bytes) / Math.log(k));
223 return (parseFloat((bytes / Math.pow(k, i)).toFixed(dm)) + ' ' + sizes[i]);
224 }
225});
226</script>