All Products - Kirloskar Oil Engines Ltd
An error occurred while processing the template.
The following has evaluated to null or missing: ==> curEntry.getAssetRenderer() [in template "20097#20123#623918" at line 13, column 81] ---- 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: assetRenderer = curEntry.getAssetRend... [in template "20097#20123#623918" at line 13, column 65] ----
1<#assign serviceContext = staticUtil["com.liferay.portal.kernel.service.ServiceContextThreadLocal"].getServiceContext()>
2<#assign themeDisplay = serviceContext.getThemeDisplay() />
3<#assign currentUrl = themeDisplay.getPortalURL() + themeDisplay.getURLCurrent()/>
4<#assign completePageName = currentUrl?keep_after("koel/")/>
5<#assign currentPageName = completePageName?keep_before("/")/>
6 <#if entries?has_content>
7 <div class="row">
8 <div id="common-product-content-listing" class="col-sm-12 col-xs-12" >
9 <h3>All Products</h3>
10 <div class="row">
11 <#list entries as curEntry>
12 <#assign
13 assetRenderer = curEntry.getAssetRenderer()
14 journalArticle = assetRenderer.getAssetObject()
15 viewURL = assetPublisherHelper.getAssetViewURL(renderRequest, renderResponse, assetRenderer, entry, !stringUtil.equals(assetLinkBehavior, "attrFullContent"))
16 document = saxReaderUtil.read(journalArticle.getContent())
17 rootElement = document.getRootElement()
18 articleId = journalArticle.getId()/>
19
20 <#list rootElement.elements() as dynamicElement>
21 <#if "productName" == dynamicElement.attributeValue("name")>
22 <#assign productName = dynamicElement.element("dynamic-content").getData() />
23 </#if>
24 <#if "image" == dynamicElement.attributeValue("name")>
25 <#assign card_images = dynamicElement.element("dynamic-content").getData()/>
26 <#assign card_image = jsonFactoryUtil.createJSONObject(card_images)/>
27 </#if>
28 <#if (card_image)??>
29 <#assign cardImageUrl = themeDisplay.getPortalURL() + "/documents/" + card_image.getString("groupId") + "/o/" + card_image.getString("title") + "/" + card_image.getString("uuid") />
30 </#if>
31 <#if "productCategory" == dynamicElement.attributeValue("name")>
32 <#assign productCategory = dynamicElement.element("dynamic-content").getData() />
33 </#if>
34 <#if "page_link" == dynamicElement.attributeValue("name")>
35 <#assign pageLink = dynamicElement.element("dynamic-content").getData() />
36 </#if>
37 </#list>
38 <#assign productTagList = [] />
39 <#assign produCount = 1/>
40 <#assign tag1 = ""/>
41 <#assign tag2 = ""/>
42 <#assign tag3 = ""/>
43 <#assign tag4 = ""/>
44 <#assign tag5 = ""/>
45 <#assign tag6 = ""/>
46 <#assign tag7 = ""/>
47 <#assign tag8 = ""/>
48 <#assign tag9 = ""/>
49
50 <#list curEntry.tagNames as tag>
51 <#assign productTagList = productTagList + [tag] />
52 <#if produCount == 1>
53 <#assign tag1 = tag?trim?lower_case?replace(" ","-")/>
54 <#elseif produCount == 2>
55 <#assign tag2 = tag?trim?lower_case?replace(" ","-")/>
56 <#elseif produCount == 3>
57 <#assign tag3 = tag?trim?lower_case?replace(" ","-")/>
58 <#elseif produCount == 4>
59 <#assign tag4 = tag?trim?lower_case?replace(" ","-")/>
60 <#elseif produCount == 5>
61 <#assign tag5 = tag?trim?lower_case?replace(" ","-")/>
62 <#elseif produCount == 6>
63 <#assign tag6 = tag?trim?lower_case?replace(" ","-")/>
64 <#elseif produCount == 7>
65 <#assign tag7 = tag?trim?lower_case?replace(" ","-")/>
66 <#elseif produCount == 8>
67 <#assign tag8 = tag?trim?lower_case?replace(" ","-")/>
68 <#elseif produCount == 9>
69 <#assign tag9 = tag?trim?lower_case?replace(" ","-")/>
70 </#if>
71 <#assign produCount = produCount + 1/>
72 </#list>
73 <div class="col-sm-6 col-xs-12 product-wrap all-products-content ${productCategory?trim?lower_case?replace(" ","-")} ${tag1} ${tag2} ${tag3} ${tag4} ${tag5} ${tag6} ${tag7} ${tag8} ${tag9}">
74 <div class="common-product-wrap">
75 <#if pageLink?has_content>
76 <a href="../${pageLink}">
77 <#else>
78 <a href="../products/${productCategory?trim?lower_case?replace("/","-")?replace(" ","-")}/${productName?trim?lower_case?replace("/","-")?replace(" ","-")?replace(")","-")?replace("(","-")}">
79 </#if>
80 <img loading="lazy" src="${cardImageUrl}"/></a>
81 <div class="d-flex align-items-center" style="justify-content:space-between;">
82 <#if pageLink?has_content>
83 <a href="../${pageLink}" class="float-left" style="width:calc(100% - 150px);">
84 <#else>
85 <a href="../products/${productCategory?trim?lower_case?replace("/","-")?replace(" ","-")}/${productName?trim?lower_case?replace("/","-")?replace(" ","-")?replace("(","-")?replace(")","-")}" class="float-left" style="width:calc(100% - 150px);">
86 </#if>
87 <p>${productName}</p></a>
88
89 <div class="see_more float-right mt-0">
90 <#if pageLink?has_content>
91 <a href="../${pageLink}" class="see_more_link black mb-0">
92 <#else>
93 <a href="../products/${productCategory?trim?lower_case?replace("/","-")?replace(" ","-")}/${productName?trim?lower_case?replace("/","-")?lower_case?replace(" ","-")?replace("(","-")?replace(")","-")}" class="see_more_link black mb-0" style="">
94 </#if>
95 <span>Detail</span>
96 <div class="link_content">
97 <div class="caret_bg"></div>
98 <div class="svg_pre">
99 <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 69.7 74">
100 <path d="M1.9,20.7A34.94,34.94,0,1,1,2,53.4" fill="none" stroke="#000" stroke-linecap="round" stroke-width="2"></path>
101 </svg>
102 </div>
103 <div class="svg_post">
104 <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 69.7 74">
105 <path d="M1.9,20.7A34.94,34.94,0,1,1,2,53.4" fill="none" stroke="var(--light-green)" stroke-linecap="round" stroke-width="4"></path>
106 </svg>
107 </div>
108 </div>
109 </a>
110 </div>
111 </div>
112
113
114 </div>
115 </div>
116 </#list>
117 </div>
118 </div>
119 </div>
120 </#if>
121
122<script>
123 $('.category-list li').click(function(e) {
124 e.preventDefault();
125 var isActive = $(this).hasClass('active');
126 var filterName = $(this).attr('val');
127 if(isActive){
128 $(this).removeClass('active');
129 }else{
130 $(this).addClass('active').siblings().removeClass('active');
131 $(".category-filters").hide();
132 $("."+filterName).show();
133 }
134 $('.category-filters .subin li').removeClass('active');
135
136 });
137
138 function toggle(id){
139 var element = document.getElementById(id);
140 if (element.style.display === "block") {
141 element.style.display = "none";
142 } else {
143 element.style.display = "block";
144 }
145 }
146
147 $(".check").click(function () {
148 $('.check:checked').map(function() {return this.value;}).get().join(',');
149
150 });
151
152</script>