HAGS Connect

    A brief block of introductory copy about HAGS Connect.

    HAGS Connect Login
    My Product Collection

    To add a product simply click on Add to my collection on any product page. Once you have added products to a collection you will be able to print a product catalogue, download installation guides, images and DWG files or request a quote.

      Error executing template "Designs/Hags2024/eCom/Productlist/h24-product-list.cshtml"
      System.OutOfMemoryException: Exception of type 'System.OutOfMemoryException' was thrown.
         at System.Data.SqlClient.TdsParser.TryReadPlpUnicodeChars(Char[]& buff, Int32 offst, Int32 len, TdsParserStateObject stateObj, Int32& totalCharsRead)
         at System.Data.SqlClient.TdsParser.TryReadSqlStringValue(SqlBuffer value, Byte type, Int32 length, Encoding encoding, Boolean isPlp, TdsParserStateObject stateObj)
         at System.Data.SqlClient.TdsParser.TryReadSqlValue(SqlBuffer value, SqlMetaDataPriv md, Int32 length, TdsParserStateObject stateObj, SqlCommandColumnEncryptionSetting columnEncryptionOverride, String columnName)
         at System.Data.SqlClient.SqlDataReader.TryReadColumnInternal(Int32 i, Boolean readHeaderOnly)
         at System.Data.SqlClient.SqlDataReader.TryReadColumn(Int32 i, Boolean setTimeout, Boolean allowPartiallyReadColumn)
         at System.Data.SqlClient.SqlDataReader.GetValueInternal(Int32 i)
         at System.Data.SqlClient.SqlDataReader.GetValue(Int32 i)
         at System.Data.SqlClient.SqlDataReader.get_Item(String name)
         at Dynamicweb.Content.Items.Item.DeserializeFrom(IDataReader reader)
         at Dynamicweb.Content.Items.Queries.Repository.SelectInternal(IEnumerable`1 ids, Query query)
         at Dynamicweb.Content.Items.Queries.Repository.SelectAll()
         at Dynamicweb.Frontend.UrlProviders.ItemTypeProvider.GetMappings()
         at Dynamicweb.Frontend.UrlProviders.Handler.GetUrls()
         at Dynamicweb.Frontend.UrlProviders.Handler.Initialize()
         at Dynamicweb.Frontend.UrlProviders.Handler.HandleModuleUrl(String& url, String& querystring, String alternatekey)
         at Dynamicweb.Frontend.SearchEngineFriendlyURLs.ResolveQueryString(String fullQueryString, Int32 pageid, String alternatekey)
         at Dynamicweb.Frontend.PageView.get_SearchFriendlyUrl()
         at CompiledRazorTemplates.Dynamic.RazorEngine_4ef1aa32a2f5435cbc78464c7727d7c0.Execute() in B:\Projects\Hags_Dw915\Files\Templates\Designs\Hags2024\eCom\Productlist\h24-product-list.cshtml:line 20
         at RazorEngine.Templating.TemplateBase.RazorEngine.Templating.ITemplate.Run(ExecuteContext context, TextWriter reader)
         at RazorEngine.Templating.RazorEngineCore.RunTemplate(ICompiledTemplate template, TextWriter writer, Object model, DynamicViewBag viewBag)
         at RazorEngine.Templating.RazorEngineService.RunCompile(ITemplateKey key, TextWriter writer, Type modelType, Object model, DynamicViewBag viewBag)
         at RazorEngine.Templating.DynamicWrapperService.RunCompile(ITemplateKey key, TextWriter writer, Type modelType, Object model, DynamicViewBag viewBag)
         at RazorEngine.Templating.RazorEngineServiceExtensions.<>c__DisplayClass16_0.<RunCompile>b__0(TextWriter writer)
         at RazorEngine.Templating.RazorEngineServiceExtensions.WithWriter(Action`1 withWriter)
         at RazorEngine.Templating.RazorEngineServiceExtensions.RunCompile(IRazorEngineService service, String name, Type modelType, Object model, DynamicViewBag viewBag)
         at Dynamicweb.Rendering.RazorTemplateRenderingProvider.Render(Template template)
         at Dynamicweb.Rendering.TemplateRenderingService.Render(Template template)
         at Dynamicweb.Rendering.Template.RenderRazorTemplate()
      
      1 @inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> 2 @using System 3 @using System.Globalization; 4 @using System.Collections.Generic 5 @using System.Linq 6 @using HagsWeb.Library.Methods.AssetManager; 7 @using HagsWeb.Library.BusinessObjects.UsersLists; 8 @using HagsWeb.Library.State; 9 @using HagsWeb.Library.Utilities; 10 @using System.Text.RegularExpressions; 11 @using System.Text; 12 13 @* for this page we want the header to be positioned over the content *@ 14 @SnippetStart("headerClass")@("out-flow")@SnippetEnd("headerClass") 15 16 @{ 17 Dynamicweb.Frontend.PageView thisPage = Dynamicweb.Frontend.PageView.Current() ?? Dynamicweb.Frontend.PageView.Current(); 18 19 string baseUrl = GetGlobalValue("Global:Request.Scheme") + "://" + GetGlobalValue("Global:Request.Host"); 20 string pageUrl = baseUrl + thisPage.SearchFriendlyUrl; 21 22 23 24 if (pageUrl.Contains("?sortBy")) 25 { 26 string canonicalUrl = baseUrl + Dynamicweb.Frontend.SearchEngineFriendlyURLs.GetFriendlyUrl("Default.aspx?ID=" + GetValue("Ecom:ProductList:Page.ID")); // works 27 string canonicalListUrl = "<link rel=\"canonical\" href=\"" + canonicalUrl + "\" />"; 28 //override the canonical tag 29 Pageview.Meta.AddTag("customCan", canonicalListUrl); 30 } 31 32 string currentCulture = GetGlobalValue("Global:Area.LongLang"); 33 string currentCountry = currentCulture.Substring(currentCulture.Length - 2); // GB, SE 34 string weglotHeader = System.Web.HttpContext.Current.Request.Headers["weglot-language"]; 35 36 //List<ProductCollectionItem> productCollectionItems = SessionManager.UsersMyProductCollection != null ? SessionManager.UsersMyProductCollection : new List<ProductCollectionItem>(); 37 var siteSection = HagsWeb.Library.Methods.Page.HagsPages.GetSiteSection(thisPage.AreaID, thisPage.ID); 38 39 string globalAreaId = GetGlobalValue("Global:Area.ID"); 40 string globalAreaLongLang = GetGlobalValue("Global:Area.LongLang"); 41 42 var pagelink = "/Default.aspx?ID=" + GetValue("Ecom:ProductList:Page.ID"); 43 string ipPriceAllowed = string.Empty; 44 string ipCountryCode = ""; 45 bool showPrice = false; 46 string productLink = string.Empty; 47 48 string weglotLangProduct = System.Web.HttpContext.Current.Request.Headers["weglot-language"]; 49 50 //price visible check 51 52 if ( weglotLangProduct == "se" ) // Sweden only at the moment 53 { 54 //ipPriceAllowed = HagsWeb.Library.Services.IPService.IPCheck.CountryPriceAllowed(currentCountry); // ZZZ,Hags_GB,Hags_SE and Hags_, Anon_GB, Anon_SE network range checker (Web.config) 55 56 //get the IP country code 57 ipCountryCode = HagsWeb.Library.Services.IPService.IPCheck.CountryCode().ToLower(); 58 59 // allow only se at the moment 60 if ( ipCountryCode == "se") 61 { 62 showPrice = true; 63 } 64 } 65 66 List<string> materialOptions = new List<string>(); 67 if (SessionManager.IsSessionValueSet("FilterOptions_" + thisPage.ID)) 68 { 69 materialOptions = SessionManager.GetSessionItem("FilterOptions_" + thisPage.ID) as List<string>; 70 } 71 else 72 { 73 foreach (LoopItem item in GetLoop("Products")) 74 { 75 string[] variantId = item.GetString("Ecom:Product.DefaultVariantComboID").Split('.'); 76 string[] variantName = item.GetString("Ecom:Product.DefaultVariantComboName").Split('-'); 77 78 79 if (variantId.Length > 0 && !variantId[0].Contains("A1DEFAULT") && variantName.Length > 0 && !variantName[0].Contains("Not Applicable")) 80 { 81 var material = string.Join(",", variantId[0], variantName[0]); 82 if (!materialOptions.Contains(material) && material != ",") 83 { 84 materialOptions.Add(material); 85 } 86 } 87 } 88 SessionManager.SetSession("FilterOptions_" + thisPage.ID, materialOptions); 89 } 90 var productCount = GetLoop("Products").Count; 91 92 // ProductListWithParagraph.cshtml Get the Paragraph Item Type content the eCom_Catalog module sits on. The Paragraph Template must be CleanModule.cshtml 93 // with an eCom_Catalog module applied and the module List Template must be this template. 94 Dynamicweb.Content.Paragraph paragraph = new Dynamicweb.Content.ParagraphService().GetParagraphsByPageId(thisPage.ID) 95 .FirstOrDefault(n => n.ItemType == "Dw_Paragraph" 96 && n.Template == "CleanModule.cshtml" 97 && n.ModuleSystemName == "eCom_Catalog" && n.ShowParagraph == true); 98 99 // Lookup the Paragraph Item Type for additional content 100 Dynamicweb.Content.Items.Item paragraphItem = new Dynamicweb.Content.Items.Item(); 101 if (paragraph != null) 102 { 103 paragraphItem = new Dynamicweb.Content.ItemService().GetItem(paragraph.ItemType, paragraph.ItemId); 104 } 105 } 106 107 <!--Templates/Hags2024/eCom/ProductList/h24-product-list.cshtml--> 108 109 @if (paragraph != null && paragraphItem != null) 110 { 111 string imageSrc = (string)paragraphItem["Image"]; 112 string imageAltTag = ""; 113 var imageMetadata = Dynamicweb.Content.Files.Metadata.EditorFactory.GetMetadataForFile(imageSrc); 114 imageAltTag = imageMetadata != null ? imageMetadata.GetValue("Image_Alt_Tag") : ""; 115 if (!string.IsNullOrEmpty(imageSrc)) 116 { 117 <section> 118 <div class="hero hero--vignette"> 119 <img class="hero__img" src="@imageSrc" alt="@imageAltTag" /> 120 121 @if ( paragraphItem["Image_Heading"] != "") 122 { 123 <div class="wrapper z-up-10"> 124 <div class="hero__content flow"> 125 <h2>@paragraphItem["Image_Heading"]</h2> 126 </div> 127 </div> 128 } 129 130 </div> 131 </section> 132 } 133 134 @helper renderPageBreadcrumb(string thisUrl, string currentCulture, string productName, string variantOptions) { 135 136 string[] segments = Array.Empty<string>(); 137 Uri uri = new Uri(thisUrl); 138 if (uri.IsWellFormedOriginalString()) 139 { 140 segments = uri.Segments; 141 } 142 143 @* set up this so we can use it's title case method *@ 144 TextInfo thisTextInfo = new CultureInfo(currentCulture,false).TextInfo; 145 146 string first = segments.FirstOrDefault(); 147 string last = segments.LastOrDefault(); 148 149 if (!string.IsNullOrEmpty(productName)) 150 { 151 string stripSpaces = Regex.Replace(productName, @"\s+", " "); // some product names may have 2 or 3 spaces in them 152 productName = stripSpaces.Replace(" ", "-").ToLower(); 153 } 154 155 string concat = string.Empty; 156 157 StringBuilder sb = new StringBuilder(); 158 sb.Append("<ul class=\"product-nav product-nav--arrows\" role=\"list\">"); 159 160 161 foreach (var item in segments.Select((value,i)=>new{i,value})) 162 { 163 var index = item.i; 164 if (true) 165 { 166 string linkText = item.value.Replace("/",""); 167 concat += item.value; 168 169 if (segments.Length <= 2) // A shorthand URL like www.hags.com/hags-dragonfly or www.hags.de/hags-dragonfly 170 { 171 sb.Append("<li>" + thisTextInfo.ToTitleCase(linkText.Replace("-", " ")) + "</li>"); 172 } 173 // Request from the Product List with no Product Name 174 else if (item.value.Equals(last, StringComparison.CurrentCultureIgnoreCase) && string.IsNullOrEmpty(productName)) 175 { 176 sb.Append("<li><a href='" + concat.TrimEnd('/') + "' class=''> " + thisTextInfo.ToTitleCase(linkText.Replace("-", " ")) + "</a></li>"); 177 break; 178 } 179 // will be either the master product or the variant 180 else if (item.value.Equals(last, StringComparison.CurrentCultureIgnoreCase) && !item.value.Equals(productName, StringComparison.CurrentCultureIgnoreCase)) 181 { 182 linkText = variantOptions.Trim().Replace("Not applicable", "").ToLower(); 183 184 185 sb.Append("<li><a href='" + concat.TrimEnd('/') + "' class=''> " + thisTextInfo.ToTitleCase(linkText.Replace("-", " ")) + "</a></li>"); 186 } 187 else if (index == 2) 188 { 189 sb.Append("<li><a href='" + concat.TrimEnd('/') + "' class=''>Home</a></li>"); 190 } else if ( index > 2 ) { 191 sb.Append("<li><a href='" + concat.TrimEnd('/') + "' class=''>" + thisTextInfo.ToTitleCase(linkText.Replace("-", " ")) + "</a></li>"); 192 } 193 } 194 } 195 196 sb.Append("</ul>"); 197 198 @(sb.ToString()) 199 } 200 201 <nav class="breadcrumb"> 202 <div class="wrapper"> 203 @renderPageBreadcrumb(pageUrl, GetGlobalValue("Global:Area.LongLang"), string.Empty, string.Empty) 204 </div> 205 </nav> 206 207 <section class="page-intro"> 208 <div class="wrapper"> 209 <div class="page-intro__copy flow"> 210 211 @if ( string.IsNullOrEmpty((string)paragraphItem["Display_Heading"]) ) { 212 <h1 class="ts-5">@paragraphItem["Header"]</h1> 213 } else { 214 <h1 class="ts-5">@paragraphItem["Display_Heading"]</h1> 215 } 216 217 @paragraphItem["Content"] 218 219 </div> 220 </div> 221 </section> 222 } 223 224 @RenderSnippet("nextLevelNav") 225 226 <section> 227 <div class="wrapper flow"> 228 229 @{ 230 string sortOrder = System.Web.HttpContext.Current.Request.QueryString["SortOrder"]; 231 string sortBy = System.Web.HttpContext.Current.Request.QueryString["sortBy"]; 232 string thisSortUrl = "&sortBy=" + sortBy + "&SortOrder=" + sortOrder; 233 234 string[,] sortOptions = new string[,] 235 { 236 {"&sortBy=ProductName&SortOrder=Asc","NameA-Z","Name A-Z" }, 237 {"&sortBy=ProductName&SortOrder=Desc","NameZ-A","Name Z-A"}, 238 {"&sortBy=AgeRange&SortOrder=Asc","AgeAscending","Age Ascending"}, 239 {"&sortBy=AgeRange&SortOrder=Desc","AgeDescending","Age Descending"}, 240 {"&sortBy=SafetyArea&SortOrder=Asc","SafetyAreaAscending","Safety Area Ascending"}, 241 {"&sortBy=SafetyArea&SortOrder=Desc","SafetyAreaDescending","Safety Area Descending"}, 242 {"&sortBy=FallHeight&SortOrder=Asc","FallHeightAscending","Fall Height Ascending"}, 243 {"&sortBy=FallHeight&SortOrder=Desc","FallHeightDescending","Fall Height Descending"} 244 }; 245 } 246 <nav aria-label="Product sort order and filters" class="dropdown-links"> 247 <ul> 248 <li class="dropdown-links__items"> 249 <!-- aria-expanded needs managed with Javascript --> 250 <button type="button" class="btn btn--outline dropdown-links__title" aria-expanded="false" aria-controls="sort-dropdown"> 251 @Translate("SortBy", "Sort by") 252 </button> 253 <ul class="dropdown-links__menu" id="sort-dropdown"> 254 <li> 255 <a href="@(pagelink)" 256 data-action-page="Product listing" 257 data-action-type="Sort by" 258 data-action-label="Default" 259 data-action-value=""> 260 @Translate("Default", "Default") 261 </a> 262 </li> 263 264 @for (int i = 0; i < sortOptions.GetLength(0); i++) 265 { 266 string activeClass = thisSortUrl == sortOptions[i, 0] ? "active" : ""; 267 <li> 268 <a href="@(pagelink)@(sortOptions[i, 0])" class="@activeClass" 269 data-action-page="Product listing" 270 data-action-type="Sort by" 271 data-action-label="@sortOptions[i, 2]" 272 data-action-value=""> 273 @Translate(@sortOptions[i, 1], @sortOptions[i, 2]) 274 </a> 275 </li> 276 } 277 278 @if (((thisPage.AreaID == 2)) && (ipPriceAllowed.Contains(currentCountry) || ipPriceAllowed.Contains("Hags_"))) 279 { 280 <li><a href="@(pagelink)&sortBy=Price&SortOrder=Asc">@Translate("Pricelow-high", "Price low-high")</a></li> 281 <li><a href="@(pagelink)&sortBy=Price&SortOrder=Desc">@Translate("Pricehigh-low", "Price high-low")</a></li> 282 } 283 </ul> 284 </li> 285 @if (materialOptions.Count > 1) 286 { 287 <li class="dropdown-links__items"> 288 <button type="button" class="btn btn--outline dropdown-links__title" aria-expanded="false" aria-controls="filter-dropdown"> 289 @Translate("MaterialOptions", "Material Options") 290 </button> 291 <ul class="dropdown-links__menu" id="filter-dropdown"> 292 <li><a href="@(pagelink)&sortBy=Default&filterBy=Default">@Translate("Default", "Default")</a></li> 293 @foreach (var a in materialOptions) 294 { 295 string[] s = a.Split(','); 296 <li> 297 <a href="@(pagelink)&sortBy=Default&filterBy=@(s[0])" 298 data-action-page="Product listing" 299 data-action-type="Filter by" 300 data-action-label="@s[1]" 301 data-action-value=""> 302 @s[1] 303 </a> 304 </li> 305 } 306 </ul> 307 </li> 308 } 309 </ul> 310 </nav> 311 312 @helper renderPagination(){ 313 <div class="wrapper"> 314 <nav class="pagination"> 315 <p class="pagination__count">@GetInteger("Ecom:ProductList.PageProdCnt") products</p> 316 <ul class="pagination__list" role="list"> 317 @{ 318 var prevLink = GetString("Ecom:ProductList.PrevPage.Clean"); 319 var nextLink = @GetString("Ecom:ProductList.NextPage.Clean"); 320 var prevLinkAttr = @GetString("Ecom:ProductList.PrevPage"); 321 var nextLinkAttr = @GetString("Ecom:ProductList.NextPage"); 322 var prevLinkClass = (prevLink == "") ? "inactive" : ""; 323 var nextLinkClass = (nextLink == "") ? "inactive" : ""; 324 string anchorTagPrev = (prevLink != "") ? "<a id=\"prevpage\" href=\"" + prevLink + "\" aria-label=\"Previous\">" : ""; 325 string anchorTagPrevClose = (prevLink != "") ? "</a>" : ""; 326 string anchorTagNext = (nextLink != "") ? "<a id=\"nextpage\" href=\"" + nextLink + "\" aria-label=\"Next\">" : ""; 327 string anchorTagNextClose = (nextLink != "") ? "</a>" : ""; 328 } 329 <li class="@prevLinkClass"> 330 @(anchorTagPrev) 331 <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 212 212" class="h24-icon h24-icon--prev"><path fill="currentColor" fill-rule="evenodd" d="M106 6c55.193 0 100 44.807 100 100s-44.807 100-100 100S6 161.193 6 106 50.807 6 106 6Zm0 5.333c-26.124 0-49.792 10.603-66.928 27.74C21.936 56.207 11.333 79.875 11.333 106c0 26.124 10.603 49.792 27.74 66.928 17.135 17.136 40.803 27.739 66.927 27.739 26.124 0 49.792-10.603 66.928-27.74 17.136-17.135 27.739-40.803 27.739-66.927 0-26.124-10.603-49.792-27.74-66.928C155.793 21.936 132.125 11.333 106 11.333Zm16.66 55.907c2.993-2.14 7.16-1.44 9.3 1.553 2.14 2.994 1.44 7.16-1.554 9.3L113.21 90.376l-1.168.834L91.333 106l39.073 27.907c2.994 2.14 3.694 6.306 1.554 9.3-2.14 2.993-6.307 3.693-9.3 1.553l-20.642-14.745-1.038-.741-1.562-1.116-1.041-.744-14.79-10.567A13.319 13.319 0 0 1 78 106c0-4.307 2.08-8.347 5.586-10.847l14.79-10.567 1.042-.744 1.562-1.116 1.038-.741L122.66 67.24Z"/></svg> 332 <span class="visually-hidden">@Translate("page_Previous", "Previous")</span> 333 @(anchorTagPrevClose) 334 </li> 335 <li>@GetString("Ecom:ProductList.CurrentPage") @Translate("page_Of", "of") @GetString("Ecom:ProductList.TotalPages")</li> 336 <li class="@nextLinkClass"> 337 @(anchorTagNext) 338 <span class="visually-hidden">@Translate("page_Next", "Next")</span> 339 <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 212 212" class="h24-icon h24-icon--next"><path fill="currentColor" fill-rule="evenodd" d="M106 6c55.193 0 100 44.807 100 100s-44.807 100-100 100S6 161.193 6 106 50.807 6 106 6Zm0 5.333c-26.124 0-49.792 10.603-66.928 27.74C21.936 56.207 11.333 79.875 11.333 106c0 26.124 10.603 49.792 27.74 66.928 17.135 17.136 40.803 27.739 66.927 27.739 26.124 0 49.792-10.603 66.928-27.74 17.136-17.135 27.739-40.803 27.739-66.927 0-26.124-10.603-49.792-27.74-66.928C155.793 21.936 132.125 11.333 106 11.333ZM96.54 67.24l20.642 14.745 1.038.741 1.561 1.116 1.042.744 1.559 1.114 1.034.739 12.197 8.714A13.319 13.319 0 0 1 141.2 106c0 4.307-2.08 8.347-5.587 10.847l-12.197 8.714-1.034.739-1.559 1.114-1.042.744-1.561 1.116-1.038.741A512447.69 512447.69 0 0 1 96.54 144.76c-2.993 2.14-7.16 1.44-9.3-1.553-2.14-2.994-1.44-7.16 1.553-9.3L127.867 106 88.793 78.093c-2.993-2.14-3.693-6.306-1.553-9.3 2.14-2.993 6.307-3.693 9.3-1.553Z"/></svg> 340 @(anchorTagNextClose) 341 </li> 342 </ul> 343 </nav> 344 </div> 345 } 346 347 348 @renderPagination() 349 </div> 350 </section> 351 352 353 354 355 <section class="products-listing"> 356 <div class="wrapper"> 357 <div class="products-listing__grid"> 358 359 360 @foreach (LoopItem item in GetLoop("Products")) 361 { 362 // Use imageUrl = HagsWeb.Library.Utilities.DWUtilities.GetSingleProductImageUrl(prod); 363 IEnumerable<ProductAsset> productImages = AssetManager_Repository.GetAssets(item.GetString("Ecom:Product.Number"), AssetType.Images, true) 364 .Where(n => n.FileName.StartsWith("medium_")); 365 366 ProductAsset image = productImages.FirstOrDefault(); 367 368 if (!string.IsNullOrEmpty(item.GetString("Ecom:Product.VariantID"))) 369 { 370 productLink = item.GetString("Ecom:Product.Link.Clean") + "&VariantID=" + item.GetString("Ecom:Product.VariantID"); 371 } 372 else 373 { 374 productLink = item.GetString("Ecom:Product.Link.Clean"); 375 } 376 377 378 // item.GetLoop("AgeRange.Options") is unreliable in the latest release DW 9.7.2 379 List<string> ageRanges = new List<string>(); 380 if (!string.IsNullOrEmpty(item.GetString("Ecom:Product:Field.AgeRange"))) 381 { 382 ageRanges = HagsWeb.Library.Methods.ProductProperties.ProductAgeRanges.GetAgeRanges(item.GetString("Ecom:Product:Field.AgeRange"), item.GetString("Ecom:Product.LanguageID")); 383 } 384 385 string ageRange = item.GetString("Ecom:Product:Field.AgeRange"); 386 string safetyArea = item.GetString("Ecom:Product:Field.SafetyArea"); 387 string fallHeight = item.GetString("Ecom:Product:Field.FallHeight"); 388 389 string variantId = item.GetString("Ecom:Product.VariantID"); 390 string formattedCurrency = item.GetInteger("Ecom:Product.DBPrice").ToString("C", new CultureInfo("sv-SE")); 391 392 //item.GetString("Ecom:Product:Field.AgeRange"); 393 //item.GetString("Ecom:Product:Field.SafetyArea"); 394 //item.GetString("Ecom:Product:Field.FallHeight"); 395 396 //bool isProductCollection = productCollectionItems.Any(n => n.ProductNumber == item.GetString("Ecom:Product.Number")); 397 //var s = HagsWeb.Library.Utilities.DWUtilities.GetProductUrl((item.GetString("Ecom:Product.Number"), thisPage.AreaID); 398 //string productLink = thisPage.SearchFriendlyUrl; 399 //var collectionLink = String.Format(productLink + "?ProductID={0}", item.GetString("Ecom:Product.ID")); 400 string collectionData = string.Format("CCAddToMyLists={0}&CCAddToListVariantID={1}&CCAddToListLanguageID={2}#{3}", item.GetString("Ecom:Product.Number"), item.GetString("Ecom:Product.VariantID"), thisPage.Area.GetByKey("areaecomlanguageid"), siteSection); 401 <div class="product-card"> 402 <input type="hidden" value="@variantId" /> 403 404 <!--div class="product-card__actions"> 405 <button type="button" class="action-btn" data-removeproductlist="" data-addproductlist="@collectionData"> 406 <span class="visually-hidden">@Translate("AddToCollection", "Add to my collection")</span> 407 <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 212 212" class="h24-icon h24-icon--plus"><path fill="currentColor" fill-rule="evenodd" d="M106 6c55.193 0 100 44.807 100 100s-44.807 100-100 100S6 161.193 6 106 50.807 6 106 6Zm0 5.333c-26.124 0-49.792 10.603-66.928 27.74C21.936 56.207 11.333 79.875 11.333 106c0 26.124 10.603 49.792 27.74 66.928 17.135 17.136 40.803 27.739 66.927 27.739 26.124 0 49.792-10.603 66.928-27.74 17.136-17.135 27.739-40.803 27.739-66.927 0-26.124-10.603-49.792-27.74-66.928C155.793 21.936 132.125 11.333 106 11.333Zm.772 59.504a6.5 6.5 0 0 1 6.5 6.5v21.5h21.5a6.5 6.5 0 0 1 6.5 6.5v1a6.5 6.5 0 0 1-6.5 6.5h-21.5v21.5a6.5 6.5 0 0 1-6.5 6.5h-1a6.5 6.5 0 0 1-6.5-6.5v-21.5h-21.5a6.5 6.5 0 0 1-6.5-6.5v-1a6.5 6.5 0 0 1 6.5-6.5h21.5v-21.5a6.5 6.5 0 0 1 6.5-6.5h1Z"></path></svg> 408 </button> 409 </div--> 410 <div class="product-card__img-silo"> 411 412 @if (image != null && !String.IsNullOrEmpty(image.uri)) 413 { 414 <a href="@productLink"><img class="product-card__img" src="@image.uri"/></a> 415 } 416 else 417 { 418 <a href="@productLink"><img class="product-card__img" src="/Files/Templates/Designs/HagsCore/res/img/image-not-found.png" /></a> 419 } 420 421 </div> 422 423 424 <div class="product-card__copy" data-weglot="@(ipCountryCode)"> 425 426 <p class="product-card__heading"><a href="@productLink">@item.GetString("Ecom:Product.Name")</a></p> 427 @if ( showPrice ) 428 { 429 <p><span class="ts-0">@(formattedCurrency)</p> 430 } 431 </div> 432 </div> 433 } 434 </div> 435 </div> 436 </section> 437 438 @renderPagination()

      Warranties

      Find out what you are covered for.

      Maintenance guide

      How to look after your products.

      Color & Anchoring Options

      Explore your options.

      }