An error occurred while processing the template.
The following has evaluated to null or missing:
==> curVocabulary  [in template "20155#20195#20833" at line 117, column 50]

----
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 curCategories = curVocabulary...  [in template "20155#20195#20833" at line 117, column 25]
----
1<#-- 
2  ~ Copyright (c) 2020 AXA Group Operations Spain S.A. 
3
4  ~ Licensed under the AXA Group Operations Spain S.A. License (the "License"); 
5  ~ you may not use this file except in compliance with the License. 
6  ~ A copy of the License can be found in the LICENSE.TXT file distributed 
7  ~ together with this file. 
8
9  ~ Unless required by applicable law or agreed to in writing, software 
10  ~ distributed under the License is distributed on an "AS IS" BASIS, 
11  ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
12  ~ See the License for the specific language governing permissions and 
13  ~ limitations under the License. 
14  --> 
15 
16<#assign emptyAttrs = true /> 
17<#assign paramName = "" /> 
18<#assign baseUrl = "" /> 
19<#assign languageService = "" /> 
20<#assign translationServiceAvailable = false /> 
21<#assign anchorName = 'filters' /> 
22<#assign AssetCategoryLocalService = staticUtil["com.liferay.asset.kernel.service.AssetCategoryLocalServiceUtil"]> 
23<#assign AssetVocabularyLocalService = staticUtil["com.liferay.asset.kernel.service.AssetVocabularyLocalServiceUtil"]> 
24 
25<#if serviceLocator.findService("com.axa.im.wcm.labeltranslation.service.LabelTranslationLocalService")??> 
26    <#assign languageService = serviceLocator.findService("com.axa.im.wcm.labeltranslation.service.LabelTranslationLocalService") /> 
27    <#assign translationServiceAvailable = true /> 
28</#if> 
29 
30<#if serviceLocator.findService("com.axa.im.wcm.ParameterUtilService")??> 
31    <#assign parameterUtilService = serviceLocator.findService("com.axa.im.wcm.ParameterUtilService") /> 
32</#if> 
33 
34<#-- localizable literals and translations --> 
35<#assign removeAllFiltersLabel = axaimTranslate("global.filters.remove.all") /> 
36<#assign removeFilterLabel = axaimTranslate("global.filters.remove.single") /> 
37<#assign activeFiltersLabel = axaimTranslate("global.filters.active") /> 
38<#assign selectDefaultLabel = axaimTranslate("content.insights.filter.select") /> 
39<#assign searchBoxLabel = axaimTranslate("global.filters.search") /> 
40<#assign searchBoxPlaceHolderLabel = axaimTranslate("global.filters.search.placeholder") /> 
41 
42<#-- Get the current categories vocabularies and objects--> 
43<#assign portalUtil = staticUtil["com.liferay.portal.kernel.util.PortalUtil"] /> 
44<#assign originalRequest = portalUtil.getOriginalServletRequest(portalUtil.getHttpServletRequest(renderRequest)) /> 
45<#assign mobileCategoriesNumber = 3> 
46 
47<#assign categoriesParamsValues = [] /> 
48<#assign activeCategories = [] /> 
49<#if originalRequest.getParameterMap()['p_r_p_categoryId']??> 
50    <#assign categoriesParamsValues = originalRequest.getParameterMap()['p_r_p_categoryId'] /> 
51    <#list categoriesParamsValues as categoryId> 
52        <#if ! activeCategories?seq_contains(categoryId)> 
53            <#assign activeCategories = activeCategories + [categoryId] /> 
54        </#if> 
55    </#list> 
56</#if> 
57 
58<#if originalRequest.getParameter("searchText")?has_content> 
59    <#assign searchText = originalRequest.getParameter("searchText") /> 
60    <#if parameterUtilService?has_content> 
61        <#assign searchText = parameterUtilService.sanitize(searchText, 100)!"" /> 
62    </#if> 
63</#if> 
64 
65<#assign vocabulariesSeq = [] /> 
66<#assign categoryObjectsSeq = [] /> 
67<#list activeCategories as activeCategoryId> 
68    <#if validator.isNumber(activeCategoryId)> 
69        <#assign activeCategory = AssetCategoryLocalService.fetchCategory(activeCategoryId?number) /> 
70        <#if activeCategoryId??> 
71            <#assign categoryObjectsSeq = categoryObjectsSeq + [activeCategory] /> 
72            <#assign activeVocabularyId = activeCategory.getVocabularyId() /> 
73            <#if !vocabulariesSeq?seq_contains(activeVocabularyId) > 
74                <#assign vocabulariesSeq = vocabulariesSeq + [activeVocabularyId] /> 
75            </#if>      
76        </#if> 
77    </#if> 
78 
79</#list> 
80 
81<#if entries?has_content> 
82    <#setting locale=locale /> 
83    <div class="forms category__filters" id="${anchorName}"> 
84        <div class="row searchbox__wrapper"> 
85            <div class="col-xs-12"> 
86                <div class="searchbox form-group"> 
87                    <input class="searchbox__input form-control gh-searchBar" 
88                        type="text" 
89                        maxlength="100" 
90                        placeholder="${searchBoxPlaceHolderLabel}" 
91                        <#if searchText?has_content> 
92                           value="${searchText}" 
93                        </#if> 
94                    /> 
95                    <button class="button custom-icon gh-searchButton"> 
96                        <span class="icon"> 
97                            <svg xmlns="http://www.w3.org/2000/svg" width="16px" height="16px" viewBox="0 0 30.239 30.239"> 
98                                <g> 
99                                    <path d="M20.194,3.46c-4.613-4.613-12.121-4.613-16.734,0c-4.612,4.614-4.612,12.121,0,16.735   c4.108,4.107,10.506,4.547,15.116,1.34c0.097,0.459,0.319,0.897,0.676,1.254l6.718,6.718c0.979,0.977,2.561,0.977,3.535,0   c0.978-0.978,0.978-2.56,0-3.535l-6.718-6.72c-0.355-0.354-0.794-0.577-1.253-0.674C24.743,13.967,24.303,7.57,20.194,3.46z    M18.073,18.074c-3.444,3.444-9.049,3.444-12.492,0c-3.442-3.444-3.442-9.048,0-12.492c3.443-3.443,9.048-3.443,12.492,0   C21.517,9.026,21.517,14.63,18.073,18.074z" fill="#FFFFFF"/> 
100                                </g> 
101                            </svg> 
102                        </span> 
103                    </button> 
104                </div> 
105            </div> 
106        </div> 
107        <div class="row combo__forms__wrapper"> 
108            <div class="col-xs-12"> 
109                <div class="combo__select"> 
110                    <#list entries as curVocabulary> 
111                        <#attempt> 
112                            <#assign curTitle = curVocabulary.getTitle(locale) /> 
113                            <#recover> 
114                                <!-- curTitle failed --> 
115                                <#assign curTitle = "-" /> 
116                        </#attempt> 
117                        <#assign curCategories = curVocabulary.getCategories() /> 
118 
119                        <#if (curVocabulary?index >= mobileCategoriesNumber) > 
120                            <#assign wrapperClass = "select__wrapper-hidden form-group select__wrapper"> 
121                        <#else> 
122                            <#assign wrapperClass = "form-group select__wrapper"> 
123                        </#if> 
124 
125                        <div class="${wrapperClass}"> 
126                            <div class="select__wrapper__gradient"> 
127                                <label class="custom__label">${curTitle}</label> 
128                                <select id="${curVocabulary.name?lower_case?replace(" ", "-")}" name="${curVocabulary 
129                                .name?replace("-", "")}" class="form-control filters__selector__new gh-${curVocabulary.name?lower_case?replace(" ", "-")}"> 
130                                    <option value="">${selectDefaultLabel}</option> 
131                                    <@displayCategories categories=curCategories activeCategories=activeCategories![]/> 
132                                </select> 
133                                <span></span> 
134                            </div> 
135                        </div> 
136                    </#list> 
137                </div> 
138            </div> 
139        </div> 
140        <div class="row arrow__more__wrapper"> 
141            <div class="col-sx-12"> 
142                <div class="arrow__more__filter closed"> 
143                </div> 
144            </div> 
145        </div> 
146 
147        <#if (vocabulariesSeq?? && vocabulariesSeq?has_content) || (searchText??  && searchText?has_content) > 
148            <div class="row active__filters__wrapper"> 
149                <div class="col-xs-12"> 
150                    <h4 class="active__filters__wrapper__title typo28">${activeFiltersLabel}</h4> 
151                    <div class="active__filters__group"> 
152                        <#if searchText?has_content> 
153                            <div class="active__filters filters__active__single"> 
154                                <#assign searchFilterLabel = axaimTranslate("global.filters.search.text") /> 
155                                <#assign iconTitle = removeFilterLabel + " " + searchFilterLabel + " - " + searchText /> 
156                                <h5 class="active__filter__title typo14 filters__label text_filter gh-activefilter-type">${searchFilterLabel} 
157                                    :</h5> 
158                                <p class="selected__filter typo14 filters__active__filter gh-activefilter-selected">${searchText}<span class="axaim-icon-cross gh-filter-icon-delete-new" title="${iconTitle}"></span></p> 
159                            </div> 
160                        </#if> 
161                        <#list vocabulariesSeq as curVocabularyId > 
162                            <#assign vocabulary = AssetVocabularyLocalService.fetchAssetVocabulary(curVocabularyId) /> 
163                            <#assign vocabularyTitle = vocabulary.getTitle(locale) /> 
164                            <div class="active__filters filters__active__single"> 
165                                <h5 class="active__filter__title typo14 filters__label gh-activefilter-type">${vocabularyTitle}:</h5> 
166                                <#list categoryObjectsSeq as curCategory > 
167                                    <#if curCategory.getVocabularyId() == curVocabularyId > 
168                                        <#assign iconTitle = removeFilterLabel + " " + vocabularyTitle + " - " + curCategory.getTitle(locale) /> 
169                                        <p class="selected__filter typo14 filters__active__filter gh-activefilter-selected" data-categoryid="${curCategory.getCategoryId()}" >${curCategory.getTitle(locale)}<span class="axaim-icon-cross gh-filter-icon-delete-new" title="${iconTitle}"></span></p> 
170                                    </#if> 
171                                </#list> 
172                            </div> 
173                        </#list> 
174                    </div> 
175                    <a href="#" class="filter__remove filters__active__reset link red gh-activefilter-clear">${removeAllFiltersLabel}</a> 
176                </div> 
177            </div> 
178        </#if> 
179        <input type="hidden" name="paramName" id="paramName" value="p_r_p_categoryId"> 
180        <input type="hidden" name="baseUrl" id="baseUrl" value="${baseUrl}#${anchorName}"> 
181    </div> 
182 
183</#if> 
184 
185<#macro displayCategories categories activeCategories activeCategories> 
186    <#list categories as curCategory> 
187        <#if !activeCategories?seq_contains(curCategory.getCategoryId()?string) > 
188            <#assign catTitle = curCategory.getTitle(locale) /> 
189            <#assign catId = curCategory.getCategoryId()?string /> 
190        <#-- Get the paramName and the baseUrl, necessary to form the filtering URL for the asset publisher --> 
191            <#if emptyAttrs > 
192                <#assign catUrlObj = renderResponse.createRenderURL() /> 
193                ${catUrlObj.setParameter("resetCur", "true")} 
194                <#assign catUrl = catUrlObj?string /> 
195                <#assign lastIndex = catUrl?last_index_of("&") /> 
196                <#assign first_parameter = catUrl?last_index_of("?") /> 
197                <#assign baseUrl =catUrl[0..first_parameter]/> 
198                <#assign emptyAttrs = false /> 
199            </#if> 
200        <option value="${catId}">${catTitle}</option> 
201        </#if> 
202    </#list> 
203</#macro> 
204<#function axaimTranslate labelText> 
205    <#if translationServiceAvailable> 
206        <#assign translated = languageService.getLabelTranslation(labelText, locale, companyId) /> 
207    <#else> 
208        <#assign translated = labelText /> 
209    </#if> 
210    <#return translated /> 
211</#function> 
212 
213<#macro log msg> 
214    <script>console.log('Msg = ${msg}')</script> 
215</#macro> 
216<script> 
217    //fix scroll on mobile 
218    AUI().on('domready', function () { 
219        if (location.hash === "#${anchorName}" && window.outerWidth <= 1076) { 
220            var dockbarHeight = 0; 
221            var portletDockbar = document.querySelector(".portlet-dockbar"); 
222            if (portletDockbar) { 
223                dockbarHeight = portletDockbar.getBoundingClientRect().height; 
224
225            var headerHeight = document.querySelector('header').getBoundingClientRect().height 
226            window.scrollBy(0, -1 * (dockbarHeight + headerHeight)); 
227
228    }); 
229</script>