Error executing template "Designs/Tefcold/_parsed/Basic_Page.parsed.cshtml"
System.InvalidOperationException: Collection was modified; enumeration operation may not execute.
   at System.ThrowHelper.ThrowInvalidOperationException(ExceptionResource resource)
   at System.Collections.Generic.List`1.Enumerator.MoveNextRare()
   at Dynamicweb.Ecommerce.Frontend.NavigationProviders.GroupNavigationProvider.MakeGroupTree(GroupCollection groups, Page page, NavigationItem parentNode, Int32 thisLevel, Int32 maxLevel, Page productPage)
   at Dynamicweb.Ecommerce.Frontend.NavigationProviders.GroupNavigationProvider.MakeGroupTree(Page page, NavigationItem parentNode)
   at Dynamicweb.Ecommerce.Frontend.NavigationProviders.GroupNavigationProvider.Process(NavigationItem node)
   at Dynamicweb.Ecommerce.Frontend.NavigationProviders.GroupNavigationProvider.ProcessTree(RootNavigationItem rootNode, NavigationType navigationType)
   at Dynamicweb.Frontend.XmlNavigation.MakeXml(Int32 parentId, Int32 levelStart, Int32 levelStop, Expand expand, Int32 selectedAreaId)
   at Dynamicweb.Frontend.XmlNavigation.GetNavigationHtml(Int32 parentId, Int32 levelStart, Int32 levelStop, Expand expand, String name, String xsltPath, Int32 selectedAreaId, Boolean sitemapMode, NameValueCollection settings, NameValueCollection attributes, IncludeMode mode)
   at Dynamicweb.Frontend.XmlNavigation.GetNavigationHtml(NameValueCollection settings, NameValueCollection attributes)
   at Dynamicweb.Rendering.TemplateBase`1.RenderNavigation(Object settings)
   at CompiledRazorTemplates.Dynamic.RazorEngine_ebaa1b94056a4f808cd5be2012cad3c4.Execute() in E:\Solutions\Live\Tefcold.Web\Files\Templates\Designs\Tefcold\_parsed\Basic_Page.parsed.cshtml:line 108
   at RazorEngine.Templating.TemplateBase.RazorEngine.Templating.ITemplate.Run(ExecuteContext context, TextWriter reader)
   at RazorEngine.Templating.RazorEngineService.RunCompile(ITemplateKey key, TextWriter writer, Type modelType, Object model, DynamicViewBag viewBag)
   at RazorEngine.Templating.RazorEngineServiceExtensions.<>c__DisplayClass16_0.b__0(TextWriter writer)
   at RazorEngine.Templating.RazorEngineServiceExtensions.WithWriter(Action`1 withWriter)
   at Dynamicweb.Rendering.Template.RenderRazorTemplate()

1 @using Dynamicweb.Content 2 @using Dynamicweb.Frontend; 3 @using Dynamicweb.Security.UserManagement 4 @using NLWI.Core.Factory 5 @using NORRIQ.SalesPersonLogin.Services 6 @using Dynamicweb.Ecommerce.International 7 @using Tefcold.Web.CustomCode.Extensions 8 @using Tefcold.Web.CustomCode.Items.Properties 9 @using Tefcold.Web.CustomCode.LanguageSwitch 10 @using Tefcold.Web.CustomCode.Razor 11 @inherits Dynamicweb.Rendering.ViewModelTemplate<Dynamicweb.Frontend.PageViewModel> 12 @{ 13 //Heine: Understående kan bruges såfremt der skal tjekkes på om man er i impersonation mode: 14 var isImpersonating = ImpersonationService.IsCurrentlyImpersonating(); 15 var locationName = Pageview.User?.Name; 16 var websiteSettings = Pageview.Area.Item.ToCodeFirstItem<Websites>(); 17 LanguageService languageService = new LanguageService(); 18 var languagesJson = Newtonsoft.Json.JsonConvert.SerializeObject(languageService.GetLanguages()); 19 } 20 21 <!DOCTYPE html> 22 <html lang="@Pageview.Area.Culture"> 23 <head> 24 <meta charset='utf-8' /> 25 <meta name="description" content="@Model.Description" /> 26 <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=5, user-scalable=yes, shrink-to-fit=no" /> 27 <meta http-equiv="x-ua-compatible" content="ie=edge"> 28 @if (Model.Area.Item.GetBoolean("NoIndex")) 29 { 30 <!-- TODO: remove on launch--> 31 <meta name="robots" content="noindex, nofollow" /> 32 } 33 34 @if (!string.IsNullOrWhiteSpace(websiteSettings.HeaderScript)) 35 { 36 @websiteSettings.HeaderScript 37 } 38 39 @if (!string.IsNullOrWhiteSpace(websiteSettings.GoogleTagManagerId)) 40 { 41 <script> 42 (function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start': 43 new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0], 44 j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src= 45 'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f); 46 })(window,document,'script','dataLayer','@websiteSettings.GoogleTagManagerId'); 47 </script> 48 } 49 50 <title>@Model.Title</title> 51 @Model.MetaTags 52 @if (Model.Area.Item.GetFile("Icon") != null) 53 { 54 <link href="@Model.Area.Item.GetFile("Icon").Path" rel="icon" type="image/png"> 55 } 56 <link async href="@NORRIQ.Common8.Razor.TimestampSource.GetSourceWithTimestamp("/Files/dist/css/Tefcold-min.css")" rel="stylesheet" /> 57 </head> 58 <body> 59 @if (!string.IsNullOrWhiteSpace(websiteSettings.GoogleTagManagerId)) 60 { 61 <!-- Google Tag Manager (noscript) --> 62 <noscript> 63 <iframe src="https://www.googletagmanager.com/ns.html?id=@websiteSettings.GoogleTagManagerId" 64 height="0" width="0" style="display: none; visibility: hidden"></iframe> 65 </noscript> 66 <!-- End Google Tag Manager (noscript) --> 67 } 68 <div id="app"> 69 @{ 70 string basicNavbarPrefix = "Header "; 71 var logo = Model.Area.Item.GetFile("Logo"); 72 var currencyCode = Pageview.User?.Currency ?? Pageview.Area.EcomCurrencyId; 73 } 74 <header class="basic_navbar" id="header"> 75 @if (isImpersonating) 76 { 77 <div class="impersonation-bar"> 78 <div class="basic_navbar-container"> 79 <p> 80 @Translate(basicNavbarPrefix + "debitor", "Debitor"): <b>@locationName</b> | <a href="@NORRIQ.Common8.Razor.Navigation.GetUrlByNavigationTag("impersonation-choose-customer")?action=changeuser">@Translate("Change customer")</a> 81 </p> 82 </div> 83 </div> 84 } 85 <div class="basic_navbar-main"> 86 <div class="basic_navbar-container"> 87 88 <button type="button" 89 class="basic_navbar-burger" 90 aria-label="@Translate(basicNavbarPrefix + "Open main navigation", "Open main navigation")" 91 v-b-toggle.basic_navigation> 92 <span></span> 93 <span></span> 94 <span></span> 95 </button> 96 <a href="/" class="basic_navbar-logo" title="@Translate(basicNavbarPrefix + "Go to frontpage", "Go to frontpage")"> 97 @if (logo != null) 98 { 99 <img class="img-fluid" src="@logo.Path" alt="@Translate(basicNavbarPrefix + "Website Logo Alttext", "Website Logo Alttext")" /> 100 } 101 else 102 { 103 <i>@Translate(basicNavbarPrefix + "No logo found", "No logo found, please configure it in the Dynamicweb Administration")</i> 104 } 105 </a> 106 <collapse-hack inline-template> 107 <b-collapse class="basic_navbar-navigation" id="basic_navigation" tag="nav"> 108 @RenderNavigation(new { Template = "basic_navbar.xslt", Expandmode = "all", StartLevel = 1, EndLevel = 4 }) 109 <ul class="basic_navbar-subnav"> 110 <li> 111 <button type="button" 112 v-b-toggle.languages 113 aria-label="@Translate(basicNavbarPrefix + "Choose Language", "Choose Language")"> 114 <img src="@Pageview.Area.Flag32X32" alt="@Pageview.Area.CultureInfo.EnglishName" /> 115 <span class="sr-only">@Pageview.Area.CultureInfo.EnglishName</span> 116 </button> 117 </li> 118 <li> 119 <button v-b-toggle.contacts 120 type="button" 121 aria-label="@Translate(basicNavbarPrefix + "Show contacts", "Show contacts")"> 122 <svg> 123 <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/files/dist/icons/icons.svg#phone-alt"></use> 124 </svg> 125 <span class="sr-only">@Translate(basicNavbarPrefix + "Contacts", "Contacts")</span> 126 </button> 127 </li> 128 <li> 129 <button v-b-toggle.customer-center 130 type="button" 131 aria-label="@Translate(basicNavbarPrefix + "Show Webshop Login", "Show Webshop Login")"> 132 @if (Pageview.User == null) 133 { 134 <svg> 135 <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/files/dist/icons/icons.svg#user"></use> 136 </svg> 137 } 138 else 139 { 140 <svg style="width: 30px; height: 30px;"> 141 <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/files/dist/icons/icons.svg#user-check"></use> 142 </svg> 143 } 144 <span class="sr-only">@Translate(basicNavbarPrefix + "Login", "Login")</span> 145 </button> 146 </li> 147 @if (Pageview.User != null) 148 { 149 <li> 150 <a href="@NORRIQ.Common8.Razor.Navigation.GetUrlByNavigationTag("quickorder")" title="@Translate(basicNavbarPrefix + "Quickorder", "Quickorder")"> 151 <svg width="28px" height="28px"> 152 <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/files/dist/icons/icons.svg#quickorder"></use> 153 </svg> 154 <span class="sr-only">@Translate(basicNavbarPrefix + "Quickorder", "Quickorder")</span> 155 </a> 156 </li> 157 } 158 @if (Pageview.User != null && Pageview.User.AllowMediaBank()) 159 { 160 <media-bank inline-template> 161 <li> 162 163 <form id="mediabankform" action="https://imagebank.tefcold.com/Home/LoginUser" method="post"> 164 <input id="mediabankformname" type="hidden" name="username" /> 165 <input id="mediabankformpassword" type="hidden" name="password" /> 166 <input type="hidden" value="false" name="persistent" /> 167 </form> 168 <a v-on:click="connect($event)" href="#"> 169 <svg width="28px" height="28px" fill="currentColor"> 170 <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/files/dist/icons/icons.svg#photo-video"></use> 171 </svg> 172 <span class="sr-only">@Translate(basicNavbarPrefix + "Mediabank", "Mediabank")</span> 173 </a> 174 </li> 175 </media-bank> 176 } 177 <li> 178 <button type="button" 179 class="btn-close" 180 @@click="collapseAll" 181 aria-label="@Translate(basicNavbarPrefix + "Close Navigation", "Close Navigation")"> 182 <span></span> 183 <span></span> 184 </button> 185 </li> 186 </ul> 187 </b-collapse> 188 </collapse-hack> 189 <form class="basic_navbar-search" action="/Default.aspx"> 190 <search-shortcut inline-template> 191 <div style="display: none"></div> 192 </search-shortcut> 193 <label for="productsearch">Search</label> 194 <input name="ID" type="hidden" value="@NORRIQ.Common8.Razor.Navigation.GetPageIdByNavigationTag("searchresult")"> 195 <input name="PageSize" type="hidden" value="99" /> 196 <input type="search" placeholder="@Translate(basicNavbarPrefix + "Search", "Search")" id="productsearch" name="productsearch"> 197 <button type="submit"> 198 <span class="sr-only">@Translate(basicNavbarPrefix + "Search", "Search")</span> 199 <svg> 200 <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/files/dist/icons/icons.svg#search"></use> 201 </svg> 202 </button> 203 </form> 204 <ul class="basic_navbar-functions"> 205 <li class="basic_navbar-languages relative"> 206 <button type="button" v-b-toggle.languages aria-label="@Translate(basicNavbarPrefix + "Choose Language", "Choose Language")"> 207 <span class="sr-only">@Pageview.Area.CultureInfo.EnglishName</span> 208 <img src="@Pageview.Area.Flag32X32" alt="@Pageview.Area.Culture - Flag" /> 209 </button> 210 <b-collapse id="languages" class="basic_navbar-dropdown" accordion="header" v-auto-close> 211 <div class="basic_navbar-body"> 212 <ul> 213 @foreach (var lang in Model.Area.Languages.Where(a => !a.IsCurrent)) 214 { 215 string langUrl; 216 string countryCode = lang.Culture.Split('-').Last(); 217 218 if (Dynamicweb.Context.Current.Request["GroupID"] != null) 219 { 220 langUrl = this.GetGroupUrl(Dynamicweb.Context.Current.Request["GroupID"], countryCode); 221 } 222 223 else if (Dynamicweb.Context.Current.Request["ProductID"] != null) 224 { 225 try 226 { 227 var uriBuilder = new UriBuilder(Pageview.SearchFriendlyUrl); 228 uriBuilder.Host = !lang.PrimaryDomain.Contains("http") ? lang.PrimaryDomain : "https://" + lang.PrimaryDomain; 229 langUrl = uriBuilder.Uri.AbsoluteUri; 230 } 231 catch (Exception e) 232 { 233 langUrl = Pageview.SearchFriendlyUrl; 234 } 235 236 } 237 238 else //if (!string.IsNullOrEmpty(lang.PrimaryDomain)) 239 { 240 try 241 { 242 243 var lss = ObjectFactory.GetInstance<LanguageSwitchService>(); 244 langUrl = lss.GetLanguagePage(lang.Culture, this.Pageview.ID); 245 } 246 catch (Exception) 247 { 248 langUrl = Pageview.SearchFriendlyUrl; 249 } 250 } 251 252 <li> 253 <a href="@langUrl"> 254 <img src="/Admin/Images/Flags/flag_@(countryCode).png" alt="@lang.Culture - Flag" loading="lazy" /> 255 <span>@Translate("lang_" + lang.Culture.Split('-').First(), lang.Culture.Split('-').First())</span> 256 </a> 257 </li> 258 } 259 <li> 260 <hr class="m-0" /> 261 <a href="/Default.aspx?ID=@GetPageIdByNavigationTag("CzechRedirect")"> 262 <img src="/Admin/Images/Flags/flag_cz.png" alt="cs-CZ - Flag" loading="lazy" /> 263 <span>@Translate("lang_cs", "cs")</span> 264 </a> 265 </li> 266 <li> 267 <a href="/Default.aspx?ID=@GetPageIdByNavigationTag("SlovakRedirect")"> 268 <img src="/Admin/Images/Flags/flag_sk.png" alt="sk-SK - Flag" loading="lazy" /> 269 <span>@Translate("lang_sk", "sk")</span> 270 </a> 271 </li> 272 273 </ul> 274 </div> 275 </b-collapse> 276 </li> 277 <li class="basic_navbar-contacts @(Pageview.User != null ? "static" : "relative")"> 278 <button v-b-toggle.contacts 279 type="button" 280 aria-label="@Translate(basicNavbarPrefix + "Show contacts", "Show contacts")"> 281 <svg> 282 <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/files/dist/icons/icons.svg#phone-alt"></use> 283 </svg> 284 <span class="sr-only">@Translate(basicNavbarPrefix + "Contacts", "Contacts")</span> 285 </button> 286 @{ 287 var impersonationGroupId = websiteSettings.ImpersonationGroup.FirstOrDefault(); 288 IEnumerable<User> users = null; 289 IEnumerable<User> salesPersons = new List<User>(); 290 if (Pageview.User != null) 291 { 292 var salesPersonCode = Pageview.User.CustomFieldValues.FirstOrDefault(field => field.CustomField.Name == "Sales Person Code"); 293 var salesPersonsInitials = salesPersonCode?.Value?.ToString().Split(',') ?? new string[] { }; 294 salesPersonsInitials = salesPersonsInitials.Select(x => x.ToLower()).ToArray(); 295 296 if (!string.IsNullOrEmpty(impersonationGroupId)) 297 { 298 users = Group.GetGroupByID(int.Parse(impersonationGroupId)).Users; 299 } 300 if (users == null || Pageview.User == null) 301 { 302 salesPersons = new List<User>(); 303 } 304 else 305 { 306 salesPersons = users.Where(user => salesPersonsInitials.Contains(user.Email.ToLower().Split('@').FirstOrDefault() ?? "")); 307 } 308 } 309 310 } 311 <b-collapse id="contacts" class="@(Pageview.User != null ? "basic_navbar-megamenu" : "basic_navbar-dropdown")" v-auto-close accordion="header"> 312 <div class="basic_navbar-body"> 313 @if (Pageview.User != null) 314 { 315 if (salesPersons.Any()) 316 { 317 <p class="tefcold_salesperson-byline h1">@Translate(basicNavbarPrefix + "Your Sales Team", "Your Sales Team")</p> 318 } 319 foreach (var salesPerson in salesPersons) 320 { 321 <div class="tefcold_salesperson" itemscope itemtype="http://schema.org/Person"> 322 <figure> 323 <img src="@salesPerson.Image" class="img-fluid" alt="@salesPerson.Name" itemprop="image" loading="lazy" /> 324 </figure> 325 <p itemprop="name">@salesPerson.Name</p> 326 <p itemprop="jobTitle">@salesPerson.JobTitle</p> 327 <p itemprop="telephone"> 328 <svg> 329 <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/files/dist/icons/icons.svg#phone-alt"></use> 330 </svg> 331 <span>@salesPerson.PhonePrivate</span> 332 </p> 333 <p itemprop="telephone"> 334 <svg> 335 <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/files/dist/icons/icons.svg#mobile-alt"></use> 336 </svg> 337 <span>@salesPerson.PhoneMobile</span> 338 </p> 339 <a href="@("mailto:" + @salesPerson.Email)" itemprop="email"> 340 <svg> 341 <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/files/dist/icons/icons.svg#envelope"></use> 342 </svg> 343 <span>@salesPerson.Email</span> 344 </a> 345 </div> 346 } 347 } 348 <ul> 349 @if (!string.IsNullOrEmpty(Model.Area.Item.GetString("PhoneLabel")) 350 && !string.IsNullOrEmpty(Model.Area.Item.GetString("Phonenumber"))) 351 { 352 <li class="head"> 353 <strong> 354 @Model.Area.Item.GetString("PhoneLabel") 355 </strong> 356 <strong> 357 @Model.Area.Item.GetString("Phonenumber") 358 </strong> 359 </li> 360 } 361 @if (!string.IsNullOrEmpty(Model.Area.Item.GetString("ContactPage")) 362 && !string.IsNullOrEmpty(Model.Area.Item.GetString("ContactLabel"))) 363 { 364 <li> 365 <a href="@Model.Area.Item.GetString("ContactPage")"> 366 @Model.Area.Item.GetString("ContactLabel") 367 </a> 368 </li> 369 } 370 @if (!string.IsNullOrEmpty(Model.Area.Item.GetString("SalesPage")) 371 && !string.IsNullOrEmpty(Model.Area.Item.GetString("SalesLabel"))) 372 { 373 <li> 374 <a href="@Model.Area.Item.GetString("SalesPage")"> 375 @Model.Area.Item.GetString("SalesLabel") 376 </a> 377 </li> 378 } 379 </ul> 380 381 </div> 382 </b-collapse> 383 </li> 384 <li class="basic_navbar-user"> 385 <button v-b-toggle.customer-center type="button" aria-label="@Translate(basicNavbarPrefix + "Show Webshop Login", "Show Webshop Login")"> 386 @if (Pageview.User == null) 387 { 388 <svg> 389 <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/files/dist/icons/icons.svg#user"></use> 390 </svg> 391 } 392 else 393 { 394 <svg style="width: 30px; height: 30px;"> 395 <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/files/dist/icons/icons.svg#user-check"></use> 396 </svg> 397 } 398 <span class="sr-only">@Translate(basicNavbarPrefix + "Login", "Login")</span> 399 </button> 400 401 402 <b-collapse id="customer-center" class="basic_navbar-dropdown" accordion="header" v-auto-close> 403 <div class="basic_navbar-body"> 404 @if (Pageview.User == null) 405 { 406 <head-login-form inline-template> 407 <form name="ExtUserForm" id="loginForm" method="post" class="form" role="form" v-on:submit="submitLogin"> 408 <p> 409 <strong> 410 @Translate(basicNavbarPrefix + "Webshop Login", "Webshop Login") 411 </strong> 412 </p> 413 <input type="hidden" name="ID" id="ID" value="" /> 414 <div class="form-group"> 415 <label for="Username">@Translate(basicNavbarPrefix + "Username", "Username")</label> 416 <input id="Username" v-model="username" name="Username" type="text" value="" class="form-control" autocomplete="off"> 417 </div> 418 <div class="form-group"> 419 <label for="Password">@Translate(basicNavbarPrefix + "Password", "Password")</label> 420 <input id="Password" v-model="password" name="Password" type="password" value="" class="form-control" autocomplete="off"> 421 </div> 422 <div v-if="loginFailed"> 423 <p class="alert alert-warning"> 424 @Translate("Login failed", "Invalid credentials") 425 </p> 426 </div> 427 <div class="basic_login-buttons"> 428 <button type="submit" role="button" class="btn btn-primary btn-block" v-bind:class='{"loading": loading}' v-on:click="loading=true" id="loginBtn"> 429 @Translate(basicNavbarPrefix + "Login", "Login") 430 </button> 431 </div> 432 </form> 433 </head-login-form> 434 <ul> 435 <li> 436 <a href="/Default.aspx?ID=@NORRIQ.Common8.Razor.Navigation.GetPageIdByNavigationTag("forgotpassword")&amp;LoginAction=Recovery"> 437 @Translate(basicNavbarPrefix + "Forgot password", "Forgot password") 438 </a> 439 </li> 440 <li> 441 <a href="@NORRIQ.Common8.Razor.Navigation.GetUrlByNavigationTag("contact")"> 442 @Translate(basicNavbarPrefix + "Create Webshop Account", "Create Webshop Account") 443 </a> 444 </li> 445 </ul> 446 } 447 else 448 { 449 <div class="active-user"> 450 <p><strong>@Pageview.User.Name</strong></p> 451 <p> 452 <a v-clear-cache:click.user href='/admin/public/extranetlogoff.aspx?ID=@(NORRIQ.Common8.Razor.Navigation.GetPageIdByNavigationTag("home"))'> 453 @Translate(basicNavbarPrefix + "Sign out", "Sign out") 454 </a> 455 </p> 456 </div> 457 @RenderNavigation(new { Template = "basic_Footer.xslt", Expandmode = "all", StartLevel = 1, EndLevel = 4, NavigationTag = "customer-portal" }) 458 } 459 </div> 460 </b-collapse> 461 </li> 462 @if (Pageview.User != null && Pageview.User.AllowMediaBank()) 463 { 464 <media-bank inline-template> 465 <li class="basic_navbar-media"> 466 <form id="mediabankform" action="https://imagebank.tefcold.com/Home/LoginUser" method="post"> 467 <input id="mediabankformname" type="hidden" name="username" /> 468 <input id="mediabankformpassword" type="hidden" name="password" /> 469 <input type="hidden" value="false" name="persistent" /> 470 </form> 471 <a v-on:click="connect($event)" href="#" class="media"> 472 <svg width="28px" height="28px"> 473 <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/files/dist/icons/icons.svg#photo-video"></use> 474 </svg> 475 <span class="sr-only">@Translate(basicNavbarPrefix + "Mediabank", "Mediabank")</span> 476 </a> 477 </li> 478 </media-bank> 479 480 } 481 @if (Pageview.User != null) 482 { 483 <li class="basic_navbar-quick"> 484 <a href="@NORRIQ.Common8.Razor.Navigation.GetUrlByNavigationTag("quickorder")" title="@Translate(basicNavbarPrefix + "Quickorder", "Quickorder")"> 485 <svg width="28px" height="28px"> 486 <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/files/dist/icons/icons.svg#quickorder"></use> 487 </svg> 488 <span class="sr-only">@Translate(basicNavbarPrefix + "Quickorder", "Quickorder")</span> 489 </a> 490 </li> 491 } 492 @if (Pageview.Area.Culture == "da-DK" || Pageview.User != null) 493 { 494 <cart-icon cartlink="@NORRIQ.Common8.Razor.Navigation.GetUrlByNavigationTag("checkout")"></cart-icon> 495 } 496 </ul> 497 </div> 498 </div> 499 </header> 500 @using Dynamicweb.Frontend; 501 @inherits Dynamicweb.Rendering.ViewModelTemplate<Dynamicweb.Frontend.PageViewModel> 502 503 @{ 504 string basicPagePrefix = "Page "; 505 } 506 @if (Pageview.IsCurrentUserAllowed) 507 { 508 var pageLayout = !string.IsNullOrEmpty(Model.Item.GetValue<ListViewModel>("Layout").SelectedValue) ? Model.Item.GetValue<ListViewModel>("Layout").SelectedValue : "content-page-sidebar"; 509 var pageClass = pageLayout == "page-wide" ? "basic_page-wide" : "basic_page"; 510 if (!Model.Item.GetBoolean("HideBreadcrumb")) 511 { 512 if (Model.Area.Item.GetFile("TopImage") != null) 513 { 514 <figure> 515 <img src="/Admin/Public/GetImage.ashx?Height=200&amp;Compression=85&amp;Crop=6&amp;Image=@Model.Area.Item.GetFile("TopImage").Path" class="img-fluid" alt="webbanner" /> 516 </figure> 517 } 518 @RenderNavigation(new { Template = "basic_Breadcrumb.xslt", Expandmode = "all", StartLevel = 1, EndLevel = 5 }) 519 } 520 <main class="@pageClass"> 521 @if (pageLayout == "content-page-sidebar" || pageLayout == "module-page-sidebar") 522 { 523 <aside class="basic_page-sidebar"> 524 @RenderNavigation(new { Template = "basic_Page.xslt", StartLevel = 1, EndLevel = 3 }) 525 </aside> 526 <div class="basic_page-content"> 527 @if (pageLayout == "content-page-sidebar" && !string.IsNullOrEmpty(Model.Item.GetString("Title").ToString()) || !string.IsNullOrEmpty(Model.Item.GetString("Text").ToString())) 528 { 529 <section class="basic_paragraph"> 530 @if (!string.IsNullOrEmpty(Model.Item.GetString("Title").ToString())) 531 { 532 <header> 533 <h1> 534 @Model.Item.GetString("Title") 535 </h1> 536 </header> 537 } 538 @if (Model.Item.GetFile("Image") != null) 539 { 540 <figure> 541 <img src="@Model.Item.GetFile("Image").Path" alt="@Model.Item.GetString("Title")" class="img-fluid" /> 542 </figure> 543 } 544 @if (!string.IsNullOrEmpty(Model.Item.GetString("Text").ToString())) 545 { 546 @Model.Item.GetString("Text") 547 } 548 </section> 549 } 550 @RenderPlaceholder() 551 </div> 552 } 553 else 554 { 555 @RenderPlaceholder() 556 } 557 </main> 558 } 559 else 560 { 561 <main class="basic_page"> 562 @RenderPlaceholder() 563 </main> 564 } 565 @helper RenderPlaceholder() 566 { 567 @Model.Placeholder("Content", "Content", "unwrap:true;default:true") 568 if (!String.IsNullOrEmpty(Model.Placeholder("Boxed"))) 569 { 570 <div class="grouped"> 571 @Model.Placeholder("Boxed", "Grouped Content", "unwrap:true") 572 </div> 573 } 574 } 575 576 @{ 577 string footerPrefix = "Footer "; 578 } 579 <footer class="basic_footer"> 580 <div class="basic_footer-wrap basic_footer-main"> 581 @if (!string.IsNullOrEmpty(Model.Area.Item.GetString("FooterOneTitle")) && !string.IsNullOrEmpty(Model.Area.Item.GetString("FooterOneText"))) 582 { 583 <div class="basic_footer-box"> 584 <div class="basic_footer-head" role="button" v-b-toggle.footer-one> 585 <h3>@Model.Area.Item.GetString("FooterOneTitle")</h3> 586 </div> 587 <b-collapse id="footer-one" class="basic_footer-collapse"> 588 <div class="basic_footer-body"> 589 @Model.Area.Item.GetString("FooterOneText") 590 </div> 591 </b-collapse> 592 </div> 593 } 594 @if (!string.IsNullOrEmpty(Model.Area.Item.GetString("FooterTwoTitle")) 595 && !string.IsNullOrEmpty(Model.Area.Item.GetString("FooterTwoText")) 596 || !string.IsNullOrEmpty(Model.Area.Item.GetString("FooterTwoTag"))) 597 { 598 <div class="basic_footer-box"> 599 <div class="basic_footer-head" role="button" v-b-toggle.footer-two> 600 <h3>@Model.Area.Item.GetString("FooterTwoTitle")</h3> 601 </div> 602 <b-collapse id="footer-two" class="basic_footer-collapse"> 603 <div class="basic_footer-body"> 604 @Model.Area.Item.GetString("FooterTwoText") 605 @if (!string.IsNullOrEmpty(Model.Area.Item.GetString("FooterTwoTag"))) 606 { 607 @RenderNavigation(new { Template = "basic_Footer.xslt", Expandmode = "all", StartLevel = 1, EndLevel = 4, NavigationTag = @Model.Area.Item.GetString("FooterTwoTag").ToString() }) 608 } 609 </div> 610 </b-collapse> 611 </div> 612 } 613 @if (!string.IsNullOrEmpty(Model.Area.Item.GetString("FooterThreeTitle")) 614 && !string.IsNullOrEmpty(Model.Area.Item.GetString("FooterThreeText")) 615 || !string.IsNullOrEmpty(Model.Area.Item.GetString("FooterThreeTag"))) 616 { 617 <div class="basic_footer-box"> 618 <div class="basic_footer-head" role="button" v-b-toggle.footer-three> 619 <h3>@Model.Area.Item.GetString("FooterThreeTitle")</h3> 620 </div> 621 <b-collapse id="footer-three" class="basic_footer-collapse"> 622 <div class="basic_footer-body"> 623 @Model.Area.Item.GetString("FooterThreeText") 624 @if (!string.IsNullOrEmpty(Model.Area.Item.GetString("FooterThreeTag"))) 625 { 626 @RenderNavigation(new { Template = "basic_Footer.xslt", Expandmode = "all", StartLevel = 1, EndLevel = 4, NavigationTag = @Model.Area.Item.GetString("FooterThreeTag").ToString() }) 627 } 628 </div> 629 </b-collapse> 630 </div> 631 } 632 @if (!string.IsNullOrEmpty(Model.Area.Item.GetString("FooterFourTitle")) && !string.IsNullOrEmpty(Model.Area.Item.GetString("FooterFourText"))) 633 { 634 <div class="basic_footer-box"> 635 <div class="basic_footer-head" role="button" v-b-toggle.footer-four> 636 <h3>@Model.Area.Item.GetString("FooterFourTitle")</h3> 637 </div> 638 <b-collapse id="footer-four" class="basic_footer-collapse"> 639 <div class="basic_footer-body"> 640 @Model.Area.Item.GetString("FooterFourText") 641 </div> 642 </b-collapse> 643 @if (!string.IsNullOrEmpty(Model.Area.Item.GetString("FacebookUrl")) 644 || !string.IsNullOrEmpty(Model.Area.Item.GetString("LinkedInUrl")) 645 || !string.IsNullOrEmpty(Model.Area.Item.GetString("YoutubeUrl"))) 646 { 647 <div class="some"> 648 @if (!string.IsNullOrEmpty(Model.Area.Item.GetString("FacebookUrl"))) 649 { 650 <a href="@Model.Area.Item.GetString("FacebookUrl")" target="_blank" aria-label="Facebook" rel="noreferrer"> 651 <svg> 652 <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/files/dist/icons/icons.svg#facebook-square"></use> 653 </svg> 654 </a> 655 } 656 @if (!string.IsNullOrEmpty(Model.Area.Item.GetString("LinkedInUrl"))) 657 { 658 <a href="@Model.Area.Item.GetString("LinkedInUrl")" target="_blank" aria-label="LinkedIn" rel="noreferrer"> 659 <svg> 660 <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/files/dist/icons/icons.svg#linkedin"></use> 661 </svg> 662 </a> 663 } 664 @if (!string.IsNullOrEmpty(Model.Area.Item.GetString("YoutubeUrl"))) 665 { 666 <a href="@Model.Area.Item.GetString("YoutubeUrl")" target="_blank" aria-label="Youtube" rel="noreferrer"> 667 <svg> 668 <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/files/dist/icons/icons.svg#youtube-square"></use> 669 </svg> 670 </a> 671 } 672 @if (!string.IsNullOrEmpty(Model.Area.Item.GetString("SmileyUrl"))) 673 { 674 <a href="@Model.Area.Item.GetString("SmileyUrl")" target="_blank" aria-label="@Translate(footerPrefix + "smiley", "Elite Smiley")" rel="noreferrer"> 675 <svg> 676 <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/files/dist/icons/icons.svg#elite-smiley-nocolor"></use> 677 </svg> 678 </a> 679 } 680 </div> 681 } 682 </div> 683 } 684 </div> 685 @if (Model.Area.Item.GetFile("GroupLogo") != null) 686 { 687 <div class="basic_footer-group"> 688 @if (!string.IsNullOrEmpty(Model.Area.Item.GetString("GroupLogo"))) 689 { 690 <a href="@Model.Area.Item.GetString("GroupLink")" target="_blank" title="@Translate(footerPrefix + "tefcold group logo alt", "Part of Tefcold Group")"> 691 <img src="@Model.Area.Item.GetFile("GroupLogo").Path" class="img-fluid" alt="@Translate(footerPrefix + "tefcold group logo alt", "Part of Tefcold Group")" /> 692 </a> 693 } 694 else 695 { 696 <img src="@Model.Area.Item.GetFile("GroupLogo").Path" class="img-fluid" alt="@Translate(footerPrefix + "tefcold group logo alt", "Part of Tefcold Group")" /> 697 } 698 </div> 699 } 700 @if (!string.IsNullOrEmpty(Model.Area.Item.GetString("FooterCopyright"))) 701 { 702 703 <div class="basic_footer-sub"> 704 <div class="basic_footer-wrap"> 705 706 <p> 707 &copy; @DateTime.Now.Year @Model.Area.Item.GetString("FooterCopyright") 708 </p> 709 @RenderNavigation(new { Template = "basic_Footer.xslt", Expandmode = "all", StartLevel = 1, EndLevel = 4, NavigationTag = "footer" }) 710 711 @if (Model.Area.Item.GetValue<ListViewModel>("Cards").SelectedValues.Any()) 712 { 713 <div class="text-center cards"> 714 @foreach (var cards in Model.Area.Item.GetValue<ListViewModel>("Cards").SelectedValues) 715 { 716 <img src="/Files/Images/cards/@cards" alt="@cards.Split('.').First()" loading="lazy" /> 717 } 718 </div> 719 } 720 721 </div> 722 </div> 723 } 724 </footer> 725 <basic-alert inline-template alertmessage='@Translate("Internet Explore Alert Message", "Website does not work properly on Internet Explorer, change browser for optimal user experience")' sessionstoragekey='IEHasBeenAlert'> 726 <div></div> 727 </basic-alert> 728 </div> 729 730 <script type="text/x-template" id="cart-icon-template"> 731 @{ 732 string cartIconPrefix = "Minicart "; 733 } 734 <li> 735 <a :href="cartlink"> 736 <svg> 737 <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/files/dist/icons/icons.svg#shopping-cart"></use> 738 </svg> 739 <span class="label">@Translate(cartIconPrefix + "Checkout", "Checkout")</span> 740 <strong v-if="!cartEmpty" class="cart-quantity">{{quantity}}</strong> 741 </a> 742 </li> 743 </script> 744 745 746 747 <script type="text/x-template" id="basic-facet-filter-template"> 748 @{ 749 string basicFacetPrefix = "Filter "; 750 } 751 <aside> 752 <template v-if="HasActiveFilter()"> 753 754 <p id="selected-filter-label" class="sr-only"> 755 @Translate(basicFacetPrefix + "Active", "Active") 756 </p> 757 <div class="basic_filter-active" aria-labelledby="selected-filter-label"> 758 <template v-for="facetFilter in facetFilters"> 759 <span v-for="option in SelectedOptions(facetFilter)" class="custom-control custom-filter"> 760 <input type="checkbox" 761 :id="'Selected-' + facetFilter.name + '-' + option.name" 762 :name="facetFilter.name" 763 :value="option.value" 764 :v-model="option.selected" 765 :checked="option.selected" 766 v-on:click="ToggleFilter(facetFilter.name,option)" 767 class="custom-control-input" /> 768 <label :for="'Selected-' + facetFilter.name + '-' + option.name" class="custom-control-label" :data-name="facetFilter.name"> 769 <span> 770 {{option.label}} 771 </span> 772 <svg> 773 <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/files/dist/icons/icons.svg#times"></use> 774 </svg> 775 </label> 776 </span> 777 </template> 778 </div> 779 </template> 780 <b-collapse class="basic_filter" id="sidebar-filter"> 781 <template v-if="!error && facetFilters"> 782 <button type="button" class="btn-close" v-b-toggle.sidebar-filter.sidebar-overlay aria-label="@Translate(basicFacetPrefix + "Close Filter", "Close Filter")"> 783 <span></span> 784 <span></span> 785 </button> 786 <div class="basic_filter-groups"> 787 <div class="basic_filter-group" v-for="(facetFilter, index) in facetFilters"> 788 <p :id="'filter-group-' + facetFilter.name.toLowerCase().trim()" v-b-toggle="'filter-collapse-' + facetFilter.name.toLowerCase().trim()"> 789 <template v-if="facetFilter.name === 'ModelType'"> 790 @Translate(basicFacetPrefix + "ModelType", "Model / Type") 791 </template> 792 <template v-else-if="facetFilter.name === 'DoorType'"> 793 @Translate(basicFacetPrefix + "DoorType", " Door type") 794 </template> 795 <template v-else-if="facetFilter.name === 'ExternalHeight'"> 796 @Translate(basicFacetPrefix + "ExternalHeight", "External Height") (mm) 797 </template> 798 <template v-else-if="facetFilter.name === 'NetVolume'"> 799 @Translate(basicFacetPrefix + "NetVolume", "Net Volume") (l) 800 </template> 801 <template v-else-if="facetFilter.name === 'DoorNumber'"> 802 @Translate(basicFacetPrefix + "DoorNumber", " Number of doors") 803 </template> 804 <template v-else-if="facetFilter.name === 'ExteriorFinish'"> 805 @Translate(basicFacetPrefix + "ExteriorFinish", "Exterior Finish") 806 </template> 807 <template v-else-if="facetFilter.name === 'ExternalWidth'"> 808 @Translate(basicFacetPrefix + "ExternalWidth", "External Width") (mm) 809 </template> 810 <template v-else-if="facetFilter.name === 'GrossVolume'"> 811 @Translate(basicFacetPrefix + "GrossVolume", "Gross Volume") (l) 812 </template> 813 <template v-else-if="facetFilter.name === 'Bottles330'"> 814 @Translate(basicFacetPrefix + "Bottles330", "Capacity 330ml bottles") 815 </template> 816 <template v-else-if="facetFilter.name === 'Bottles500'"> 817 @Translate(basicFacetPrefix + "Bottles500", "Capacity 500ml bottles") 818 </template> 819 <template v-else-if="facetFilter.name === 'Cans330'"> 820 @Translate(basicFacetPrefix + "Cans330", "Capacity 300ml cans") 821 </template> 822 <template v-else-if="facetFilter.name === 'Cans500'"> 823 @Translate(basicFacetPrefix + "Cans500", "Capacity 500ml cans") 824 </template> 825 <template v-else-if="facetFilter.name === 'TemperatureRange'"> 826 @Translate(basicFacetPrefix + "TemperatureRange", "Temperature Range") 827 </template> 828 <template v-else-if="facetFilter.name === 'TemperatureRangeZone2'"> 829 @Translate(basicFacetPrefix + "TemperatureRangeZone2", "Tempature Range 2") 830 </template> 831 <template v-else-if="facetFilter.name === 'ShelfNumber'"> 832 @Translate(basicFacetPrefix + "ShelfNumber", "Number of shelfs") 833 </template> 834 <template v-else-if="facetFilter.name === 'LidType'"> 835 @Translate(basicFacetPrefix + "LidType", "Lid Type") 836 </template> 837 <template v-else-if="facetFilter.name === 'InteriorFinish'"> 838 @Translate(basicFacetPrefix + "InteriorFinish", "Interior Finish") 839 </template> 840 <template v-else-if="facetFilter.name === 'WineBottles750'"> 841 @Translate(basicFacetPrefix + "WineBottles750", "Capacity 750ml winebottles") 842 </template> 843 <template v-else> 844 {{facetFilter.name}} 845 </template> 846 <svg> 847 <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/Files/dist/icons/icons.svg#chevron-up"></use> 848 </svg> 849 </p> 850 <b-collapse :id="'filter-collapse-' + facetFilter.name.toLowerCase().trim()" :visible="ShowGroupIfSelected(facetFilter.options, index)" class="basic_filter-collapsing" :aria-labelledby="'filter-group-' + facetFilter.name.toLowerCase().trim()"> 851 <template v-if="facetFilter.optionActiveCount > 5"> 852 <span v-for="option in facetFilter.options.slice(0, 5)" class="custom-control custom-checkbox facet-option"> 853 <input type="checkbox" class="custom-control-input" 854 :id="'UnSelected-' + facetFilter.name + '-' + option.name" 855 :name="facetFilter.name" 856 :value="option.value" 857 :v-model="option.selected" 858 :checked="option.selected" 859 v-on:click="ToggleFilter(facetFilter.name,option)" /> 860 <label :for="'UnSelected-' + facetFilter.name + '-' + option.name" class="custom-control-label"> 861 {{option.label}} <span class="count">({{option.count}})</span> 862 </label> 863 </span> 864 <b-collapse class="basic_filter-expand" :id="'filter-expand-' + facetFilter.name.toLowerCase().trim()" :visible="ShowMoreIfSelected(facetFilter.options, index)"> 865 <span v-for="option in facetFilter.options.slice(5)" class="custom-control custom-checkbox facet-option"> 866 <input type="checkbox" class="custom-control-input" 867 :id="'UnSelected-' + facetFilter.name + '-' + option.name" 868 :name="facetFilter.name" 869 :value="option.value" 870 :v-model="option.selected" 871 :checked="option.selected" 872 v-on:click="ToggleFilter(facetFilter.name,option)" /> 873 <label :for="'UnSelected-' + facetFilter.name + '-' + option.name" class="custom-control-label"> 874 {{option.label}} <span class="count">({{option.count}})</span> 875 </label> 876 </span> 877 </b-collapse> 878 <a v-b-toggle="'filter-expand-' + facetFilter.name.toLowerCase().trim()" class="basic_filter-expanding" v-if="facetFilter.optionActiveCount > 6"> 879 <span class="show-more">+ @Translate(basicFacetPrefix + "show more", "show more")</span> 880 <span class="show-less">- @Translate(basicFacetPrefix + "show less", "show less")</span> 881 </a> 882 </template> 883 <template v-else> 884 <span v-for="option in facetFilter.options" class="custom-control custom-checkbox facet-option"> 885 <input type="checkbox" class="custom-control-input" 886 :id="'UnSelected-' + facetFilter.name + '-' + option.name" 887 :name="facetFilter.name" 888 :value="option.value" 889 :v-model="option.selected" 890 :checked="option.selected" 891 v-on:click="ToggleFilter(facetFilter.name,option)" /> 892 <label :for="'UnSelected-' + facetFilter.name + '-' + option.name" class="custom-control-label"> 893 {{option.label}} <span class="count">({{option.count}})</span> 894 </label> 895 </span> 896 </template> 897 </b-collapse> 898 </div> 899 </div> 900 </template> 901 </b-collapse> 902 </aside> 903 </script> 904 <script type="text/x-template" id="add-to-basket-simple-template"> 905 @{ 906 string addToBasketSimplePrifix = "BuyButton "; 907 } 908 <div class="form-flex" v-if="priceWithoutVat > 0" v-bind:class="[{added: IsAdded}, {adding: IsAdding}, {disabled: !canAdd}]"> 909 910 <label for="quantity">@Translate(addToBasketSimplePrifix + "Quantity", "Quantity")</label> 911 <input class="form-control" type="number" name="quantity" v-model="quantity" autocomplete="off" onclick="this.setSelectionRange(0, this.value.length)"> 912 <button :disabled="!canAdd" :class="buttonClass" v-on:click="addToBasketAndResetQuantity()" aria-label="@Translate(addToBasketSimplePrifix + "Add", "Add")"> 913 <slot> 914 <svg> 915 <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/files/dist/icons/icons.svg#shopping-cart"> 916 </use> 917 </svg> 918 <span> 919 @Translate(addToBasketSimplePrifix + "Add to basket", "Add to basket") 920 </span> 921 </slot> 922 923 </button> 924 925 <span v-if="itemStockLocationState == 5" v-b-tooltip.hover.focus="'@Translate(addToBasketSimplePrifix + "The item is out of stock","The item is out of stock").Replace(System.Environment.NewLine,"").Replace("'","\\'")'" class="addtobasket-help">?</span> 926 <span v-if="itemStockLocationState == 4" v-b-tooltip.hover.focus="'@Translate(addToBasketSimplePrifix + "cant buy this product info","This product is not available from the currently chosen stock location!").Replace(System.Environment.NewLine,"").Replace("'","\\'")'" class="addtobasket-help">?</span> 927 <span v-if="itemStockLocationState == 50" v-b-tooltip.hover.focus="'@Translate(addToBasketSimplePrifix + "no stock information available","Could not find any stock information on this product!").Replace(System.Environment.NewLine,"").Replace("'","\\'")'" class="addtobasket-help">?</span> 928 </div> 929 </script> 930 931 <script type="text/x-template" id="quick-add-template"> 932 @{ 933 string quickAddPrifix = "BuyButton "; 934 } 935 <div v-bind:class="[{added: IsAdded}, {adding: IsAdding}]"> 936 <label for="quantity">@Translate(quickAddPrifix + "Quantity", "Quantity")</label> 937 <input class="form-control" type="number" id="quantity" name="quantity" v-model="quantity" autocomplete="off"> 938 </div> 939 </script> 940 941 <script type="text/x-template" id="add-to-basket-button-only-template"> 942 @{ 943 string addToBasketPrefix = "BuyButton "; 944 } 945 <div v-bind:class="[{added: IsAdded}, {adding: IsAdding}]"> 946 <button :class="buttonClass" v-on:click="addToBasket()"> 947 <slot> 948 @Translate(addToBasketPrefix + "Add to basket", "Add to basket") 949 </slot> 950 </button> 951 </div> 952 </script> 953 <script type="text/x-template" id="async-price-template"> 954 @{ 955 string asyncPrefix = "Async "; 956 957 } 958 959 <div :class="classType + (loading ? ' loading' : '')"> 960 <template> 961 <p :class="classType + '--error'" v-if="error">{{error}}</p> 962 </template> 963 <template v-if="!loading"> 964 <template v-if="!forceAskForPrice && price.netUnitPrice.priceWithoutVat"> 965 966 <p class="price"> 967 <span itemprop="price" :content="price.netUnitPrice.priceWithoutVat">{{ price.netUnitPrice.priceWithoutVat | currency(price.currencyCode) }}</span> 968 <span class="sr-only" itemprop="priceCurrency" content="@(Pageview.User?.Currency ?? Pageview.Area.EcomCurrencyId)">@(Pageview.User?.Currency ?? Pageview.Area.EcomCurrencyId)</span> 969 </p> 970 <small>@Translate(asyncPrefix + "price without vat", "Price without VAT")</small> 971 </template> 972 <template v-if="!price?.netUnitPrice?.priceWithoutVat || forceAskForPrice"> 973 <a :href="'mailto:@Translate("Ask for a price EMAIL.","info@tefcold.dk")?subject=' + '@Translate("Ask for a price.")' + ' - ' + product.product.name + ' - ' + product.product.shortDescription + '&body=@Translate("ProductName EMAIL (BODY)", "Produktnavn: ") ' + product.product.name + ' - @Translate("ProductShortName EMAIL (BODY)", "Kort produktnavn: ") ' + product.product.shortDescription" class="btn btn-outline-secondary btn-sm">@Translate("Ask for a price.", "Spørg om pris.")</a> 974 </template> 975 </template> 976 </div> 977 </script> 978 <script type="text/x-template" id="pagination-template"> 979 @{ 980 string paginationPrefix = "Pagination "; 981 } 982 <nav aria-label="@Translate(paginationPrefix + "Productlist pagination", "Productlist pagination")"> 983 <ul class="pagination"> 984 <li :class="['page-item', currentPage == 1 ? 'disabled' : '' ]"> 985 <a class="page-link" v-on:click="togglePrevPage()" aria-label="@Translate(paginationPrefix + "Previous Page", "Previous Page")" v-bind:aria-disabled="currentPage > 1 ? 'true' : null"> 986 <svg> 987 <use xmlns:xlink="http://www.w3.org/1999/xlink" 988 xlink:href="/files/dist/icons/icons.svg#chevron-left"> 989 </use> 990 </svg> 991 </a> 992 </li> 993 <template v-if="hasGroupId"> 994 <li v-if="showPage(n)" v-for="n in totalPages" :key="n" :class="(n == currentPage ? 'page-item active' : 'page-item')"> 995 <a v-on:click="togglePage(n)" v-bind:aria-current="(n == currentPage ? 'true' : '')" class="page-link"> 996 {{n}} 997 </a> 998 </li> 999 </template> 1000 <template v-else> 1001 <li class="page-item"> 1002 <span class="page-label"> 1003 {{currentPage}} 1004 </span> 1005 </li> 1006 <li class="page-item"> 1007 <span class="page-label"> 1008 @Translate(paginationPrefix + "of", "of") 1009 </span> 1010 </li> 1011 <li class="page-item"> 1012 <span class="page-label"> 1013 {{totalPages}} 1014 </span> 1015 </li> 1016 </template> 1017 <li :class="'page-item' + (currentPage >= totalPages ? ' disabled' : '')"> 1018 <a v-on:click="toggleNextPage()" aria-label="@Translate(paginationPrefix + "Next Page", "Next Page")" class="page-link" v-bind:aria-disabled="totalPages > currentPage ? 'true' : null"> 1019 <svg class="icon-pagination"> 1020 <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/files/dist/icons/icons.svg#chevron-right"></use> 1021 </svg> 1022 </a> 1023 </li> 1024 </ul> 1025 </nav> 1026 </script> 1027 <script type="text/x-template" id="product-specification-list-view-template"> 1028 <div class="basic_listview-data"> 1029 <template v-if="!isSparePart"> 1030 <p itemprop="description"> 1031 {{ SpecificationHelpers.GetFirstSpecificationValueOrDefault('GrossNetVolume',productSpecifications)}} {{ SpecificationHelpers.GetSpecificationUnit(SpecificationHelpers.GetSpecificationByKey('GrossNetVolume',productSpecifications))}} 1032 <br /> 1033 {{ SpecificationHelpers.GetFirstSpecificationValueOrDefault('ExternalDimensionWeb',productSpecifications)}} 1034 1035 </p> 1036 </template> 1037 <p itemprop="sku">@Translate("PLP No.", "No.") {{productNumber}}</p> 1038 </div> 1039 </script> 1040 <script type="text/x-template" id="product-spare-parts-view-template"> 1041 @{ 1042 string basicPimPrefix = "PDP "; 1043 } 1044 <div> 1045 <button class="btn-collapse" id="spareparts" v-b-toggle.spareparts-list> 1046 @Translate(basicPimPrefix + "spare parts", "Spare Parts") 1047 </button> 1048 <template> 1049 <b-collapse id="spareparts-list" visible accordion="specs2"> 1050 <template> 1051 <div class="body-collapse full pb-0"> 1052 <ul class="basic_pim-spares"> 1053 <template v-if="sparePartReportExist"> 1054 <li> 1055 <a href="#" v-on:click="getSparePartReport($event)" target="_blank"> 1056 <svg> 1057 <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/files/dist/icons/icons.svg#download"></use> 1058 </svg> 1059 @Translate(basicPimPrefix + "spare part list", "Spare part list") 1060 </a> 1061 </li> 1062 </template> 1063 <li> 1064 <a :href="explodedDrawing" target="_blank"> 1065 <svg> 1066 <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/files/dist/icons/icons.svg#download"></use> 1067 </svg> 1068 @Translate(basicPimPrefix + "view exploded drawing of spare parts", "View exploded drawing of spare parts") 1069 </a> 1070 </li> 1071 <li :data-point="spare.product.position" class="basic_pim-spare" v-for="spare in spareParts"> 1072 <div class="head"> 1073 <a href="#" v-on:click="navigateToSpare($event,spare.product.id)" class="name">{{spare.product.productName}}</a> 1074 <p class="sku">{{spare.product.number}}</p> 1075 </div> 1076 1077 @if (Pageview.IsAllowedToShop()) 1078 { 1079 <div class="foot"> 1080 <async-price class-type="asyncprice-spare" 1081 :product="spare" 1082 :default-price="spare.product.price" 1083 list-price="true" 1084 :only-standard-price="@(Pageview.IsCurrentlyB2C().ToString().ToLower())" 1085 standard-customer="@(string.IsNullOrEmpty(Pageview.AreaSettings.GetString("StandardCustomer")) ? "" : Pageview.AreaSettings.GetString("StandardCustomer"))"> 1086 > 1087 </async-price> 1088 <add-to-basket-simple 1089 :product="spare" 1090 :unit-of-measure="'PCS'" 1091 button-class="btn btn-primary" 1092 class="addtobasketsimple-plp" 1093 :price-without-vat="spare.product.price" 1094 language-id="@Pageview.Area.EcomLanguageId" 1095 :only-spare-parts="@(Pageview.User.OnlySpareParts().ToString().ToLower())" 1096 :is-marketing-user="@(Pageview.User.OnlyView().ToString().ToLower())" 1097 standard-customer="@(string.IsNullOrEmpty(Pageview.AreaSettings.GetString("StandardCustomer")) ? "" : Pageview.AreaSettings.GetString("StandardCustomer"))"> 1098 </add-to-basket-simple> 1099 </div> 1100 } 1101 @*<p>DEBUG: {{spare}}</p>*@ 1102 </li> 1103 1104 </ul> 1105 </div> 1106 </template> 1107 </b-collapse> 1108 </template> 1109 </div> 1110 1111 </script> 1112 <script type="text/x-template" id="variant-list-template"> 1113 <ul class="variants" v-if="initialVariant.product.hasVariants" > 1114 <li> 1115 <input v-model="variantId" @@click="changeVariantClickHandler($event)" :value="initialVariant.product.variantId" type="radio" :name="'main-' + initialVariant.product.id" :id="'main-' + initialVariant.product.id" :disabled="readOnly"/> 1116 <label :for="'main-' + initialVariant.product.id" :style="getImageOrColor(initialVariant.product.variantImage,initialVariant.product.variantValue)"></label> 1117 </li> 1118 <li v-for="variant in initialVariant.product.simpleVariants"> 1119 <input v-model="variantId" @@click="changeVariantClickHandler($event)" :value="variant.product.variantId" type="radio" :name="'color-'+variant.product.id + '-' + variant.product.variantId" :id="'color-'+variant.product.id + '-' + variant.product.variantId" /> 1120 <label :for="'color-'+variant.product.id+ '-' + variant.product.variantId" :style="getImageOrColor(variant.product.variantImage,variant.product.variantValue)"> 1121 </label> 1122 </li> 1123 </ul> 1124 </script> 1125 @using Dynamicweb.Ecommerce.International 1126 <script type="text/x-template" id="product-template"> 1127 1128 <article itemscope itemtype="https://schema.org/Product" v-if="product.product" v-bind:key="product.product.number"> 1129 <span class="badge"> 1130 <img v-if="SpecificationHelpers.GetFirstSpecificationValueOrDefault('Stickers',product.specifications)" :src="'/Admin/Public/GetImage.ashx?Height=50&amp;Compression=85&amp;Image=' + SpecificationHelpers.GetFirstSpecificationValueOrDefault('Stickers',product.specifications)" alt="@Translate(basicPimPrefix + "Sticker", "Sticker")" v-bind:alt="product.product.name" itemprop="image" class="img-fluid" /> 1131 </span> 1132 <a :href="product.product.url" itemprop="url"> 1133 <figure style="min-height: 1px;"> 1134 1135 <img v-if="SpecificationHelpers.GetFirstSpecificationValueOrDefault('WebPrimaryImage',product.specifications)" :src="'/Admin/Public/GetImage.ashx?Width=427&amp;Height=427&amp;Compression=85&amp;Crop=5&amp;fillcanvas=true&amp;Image=' + SpecificationHelpers.GetFirstSpecificationValueOrDefault('WebPrimaryImage',product.specifications)" 1136 v-bind:alt="product.product.name" itemprop="image" class="img-fluid" /> 1137 <img v-if="!SpecificationHelpers.GetFirstSpecificationValueOrDefault('WebPrimaryImage',product.specifications)" :src="'/Admin/Public/GetImage.ashx?Width=427&amp;Height=427&amp;Compression=85&amp;Crop=5&amp;fillcanvas=true&amp;Image=/Files/Images/default.jpg'" 1138 v-bind:alt="product.product.name" itemprop="image" class="img-fluid" /> 1139 </figure> 1140 <header> 1141 <h1 itemprop="name">{{product.product.name}}</h1> 1142 <p itemprop="category">{{product.product.shortDescription}}</p> 1143 <div class="flex-list"> 1144 <product-specification-list-view :product-specifications="product.specifications" 1145 :product-number="product.product.number" 1146 :is-spare-part="product.product.isSparePart"> 1147 </product-specification-list-view> 1148 @if (Pageview.IsAllowedToShop()) 1149 { 1150 <template v-if="plpClass=='basic_listview-grid'"> 1151 <buying-component inline-template :selected-product="product" :initial-product="initialProduct"> 1152 <template v-if="SpecificationHelpers.GetFirstSpecificationValueOrDefault('EnergyArrow',selectedProduct.specifications)"> 1153 <div class="energy-data"> 1154 <a :href="SpecificationHelpers.GetFirstSpecificationValueOrDefault('EnergyLabel',selectedProduct.specifications)" target="_blank" class="energy-label"> 1155 <img :src="SpecificationHelpers.GetFirstSpecificationValueOrDefault('EnergyArrow',selectedProduct.specifications)" alt="Energy Label" class="img-fluid img-energy" height="25" /> 1156 </a> 1157 <a href="#" v-on:click="getProductReport($event,selectedProduct.product.number,selectedProduct.product.name,selectedProduct.product.languageId)" target="_blank" class="energy-link"> 1158 <small>@Translate("PDP product sheet", "Product Sheet")</small> 1159 </a> 1160 </div> 1161 </template> 1162 </buying-component> 1163 </template> 1164 } 1165 </div> 1166 </header> 1167 </a> 1168 <template v-if="plpClass=='basic_listview-list'"> 1169 <ul class="basic_listview-specs"> 1170 <li v-for="item in SpecificationHelpers.GetPrettyBulletPoints(product.specifications)"> 1171 {{item}} 1172 </li> 1173 </ul> 1174 @*{{ product.Product.LongDescription }}*@ 1175 </template> 1176 1177 @if (!Pageview.IsAllowedToShop()) 1178 { 1179 <footer> 1180 <a href="@NORRIQ.Common8.Razor.Navigation.GetUrlByNavigationTag("contact")" class="btn btn-outline-secondary btn-sm"> 1181 @Translate("create account", "Create account") 1182 </a> 1183 <buying-component inline-template :selected-product="product" :initial-product="initialProduct"> 1184 <variant-list :initial-variant="initialProduct" :currently-selected="selectedProduct"></variant-list> 1185 </buying-component> 1186 </footer> 1187 } 1188 else 1189 { 1190 <buying-component inline-template :selected-product="product" :plp-class="plpClass" :initial-product="initialProduct"> 1191 <footer itemprop="offers" itemscope="" itemtype="https://schema.org/Offer"> 1192 <variant-list :initial-variant="initialProduct" :currently-selected="selectedProduct"></variant-list> 1193 <template v-if="SpecificationHelpers.GetFirstSpecificationValueOrDefault('EnergyArrow',selectedProduct.specifications) && plpClass == 'basic_listview-list'"> 1194 <div class="energy-price"> 1195 <async-price class-type="asyncprice-plp" 1196 :product="selectedProduct" 1197 :default-price="selectedProduct.product.defaultPrice.priceWithoutVat" 1198 :only-standard-price="@(Pageview.IsCurrentlyB2C().ToString().ToLower())" 1199 list-price="true" 1200 :should-emit-warranties="@((Pageview.IsAllowedToShop()).ToString().ToLower())" 1201 :force-ask-for-price="(!selectedProduct.product.isSparePart && @((Pageview.User.OnlySpareParts()).ToString().ToLower())) || @(Pageview.User.OnlyView().ToString().ToLower())" 1202 standard-customer="@(string.IsNullOrEmpty(Pageview.AreaSettings.GetString("StandardCustomer")) ? "" : Pageview.AreaSettings.GetString("StandardCustomer"))"> 1203 </async-price> 1204 <div class="energy-data"> 1205 <a :href="SpecificationHelpers.GetFirstSpecificationValueOrDefault('EnergyLabel',selectedProduct.specifications)" class="energy-label" target="_blank"> 1206 <img :src="SpecificationHelpers.GetFirstSpecificationValueOrDefault('EnergyArrow',selectedProduct.specifications)" alt="Energy Label" class="img-fluid img-energy" height="25" /> 1207 </a> 1208 <a href="#" v-on:click="getProductReport($event,selectedProduct.product.number,selectedProduct.product.name,selectedProduct.product.languageId)" target="_blank" class="energy-link"> 1209 <small>@Translate("PDP product sheet", "Product Sheet")</small> 1210 </a> 1211 </div> 1212 </div> 1213 </template> 1214 <template v-else> 1215 <async-price class-type="asyncprice-plp" 1216 :product="selectedProduct" 1217 :default-price="selectedProduct.product.defaultPrice.priceWithoutVat" 1218 :only-standard-price="@(Pageview.IsCurrentlyB2C().ToString().ToLower())" 1219 list-price="true" 1220 :should-emit-warranties="@((Pageview.IsAllowedToShop()).ToString().ToLower())" 1221 :force-ask-for-price="(!selectedProduct.product.isSparePart && @((Pageview.User.OnlySpareParts()).ToString().ToLower())) || @(Pageview.User.OnlyView().ToString().ToLower())" 1222 standard-customer="@(string.IsNullOrEmpty(Pageview.AreaSettings.GetString("StandardCustomer")) ? "" : Pageview.AreaSettings.GetString("StandardCustomer"))"> 1223 </async-price> 1224 </template> 1225 1226 <add-to-basket-simple :product="selectedProduct" 1227 :unit-of-measure="'PCS'" 1228 button-class="btn btn-primary" 1229 class="addtobasketsimple-plp" 1230 :price-without-vat="currentItemPriceWithoutVat" 1231 language-id="@Pageview.Area.EcomLanguageId" 1232 :only-spare-parts="@(Pageview.User.OnlySpareParts().ToString().ToLower())" 1233 :is-marketing-user="@(Pageview.User.OnlyView().ToString().ToLower())" 1234 standard-customer="@(string.IsNullOrEmpty(Pageview.AreaSettings.GetString("StandardCustomer")) ? "" : Pageview.AreaSettings.GetString("StandardCustomer"))"> 1235 </add-to-basket-simple> 1236 </footer> 1237 </buying-component> 1238 } 1239 1240 </article> 1241 1242 </script> 1243 <script type="text/x-template" id="quick-search-template"> 1244 <div class="quicksearch-component"> 1245 <div class="quickorder-form"> 1246 <slot name="right-box"></slot> 1247 <div class="quickorder-box"> 1248 <h2>@Translate("Find products")</h2> 1249 <div class="quickorder-input"> 1250 <label for="quickOrderSearch">@Translate("Product name or number")</label> 1251 <input type="text" 1252 :id="id" 1253 v-model="search" 1254 @@keydown.enter="enter" 1255 @@keydown.down="down" 1256 @@keydown.up="up" 1257 @@input="onSearchInput" 1258 class="form-control form-control-lg" 1259 autocomplete="chrome-off" 1260 placeholder="@Translate("Quick order search term")" 1261 :disabled="disabled"/> 1262 <label for="quickOrderQty">@Translate("Quantity")</label> 1263 <input type="number" 1264 v-model.number="quantity" 1265 @@change="chosenProduct()" 1266 @@keydown.enter="chosenProduct()" 1267 class="form-control form-control-lg" 1268 id="quickOrderQty" 1269 placeholder="0" 1270 autocomplete="chrome-off" 1271 :disabled="disabled"/> 1272 1273 </div> 1274 <ul v-if="filterList.length > 0 && open" class="quickorder-list"> 1275 <li v-for="(product,index) in filterList" 1276 :class="{'active': isSelected(index)}"> 1277 <button @@click="suggestClick(index)"> 1278 {{concatNameAndNumber(product)}} 1279 </button> 1280 1281 </li> 1282 </ul> 1283 1284 <div class="quickorder-product" v-if="currentChosenProduct"> 1285 <p><strong>{{currentChosenProduct.name}}</strong><small>{{currentChosenProduct.shortDescription}}</small></p> 1286 <product-specification-list-view v-if="searchProductSpecs !== null" 1287 :product-specifications="searchProductSpecs" 1288 :product-number="currentChosenProduct.number"> 1289 </product-specification-list-view> 1290 <async-price class-type="quickorder-product-price" 1291 :product="currentChosenProduct" 1292 unit-of-measure="" 1293 :only-price="true" 1294 default-price-without-vat="0" 1295 :force-ask-for-price="(!currentChosenProduct.isSparePart && @(Pageview.User.OnlySpareParts().ToString().ToLower())) || @(Pageview.User.OnlyView().ToString().ToLower())" 1296 @@price="handlePriceUpdate" 1297 standard-customer="@(string.IsNullOrEmpty(Pageview.AreaSettings.GetString("StandardCustomer")) ? "" : Pageview.AreaSettings.GetString("StandardCustomer"))"> 1298 </async-price> 1299 </div> 1300 </div> 1301 </div> 1302 <p v-if="showPriceError">@Translate("QuickOrderZeroPriceError","Can not add product with zero price")</p> 1303 <div class="quickorder-cart" v-if="productsToOrder.length > 0"> 1304 <table class="table table-striped table-flex"> 1305 <thead> 1306 <tr> 1307 <th>@Translate("Product")</th> 1308 <th>@Translate("Specifications")</th> 1309 <th>@Translate("Quantity")</th> 1310 <th class="cell-right">@Translate("Price")</th> 1311 <th>&nbsp;</th> 1312 </tr> 1313 </thead> 1314 <tbody> 1315 <tr v-for="(product,index) in productsToOrder"> 1316 <td class="cell-prod"> 1317 <strong>{{product.name}}</strong> 1318 <small>{{product.shortDescription}}</small> 1319 </td> 1320 <td class="cell-specs"> 1321 <product-specification-list-view :product-specifications="product.productSpecifications" 1322 :product-number="product.number"> 1323 </product-specification-list-view> 1324 </td> 1325 <td class="cell-specs"> 1326 <input class="form-control" type="number" v-model="product.quantity" @@input="updateQuantity()" /> 1327 </td> 1328 <td class="cell-price cell-right"> 1329 <async-price class-type="quickorder-product-price" 1330 :product="quickOrderProductToSimpleProduct(product)" 1331 unit-of-measure="" 1332 :only-price="true" 1333 default-price-without-vat="0" 1334 :should-emit-warranties="true" 1335 @@qo-warranty-update="setWarranty($event,product)" 1336 :force-ask-for-price="(!product.isSparePart && @(Pageview.User.OnlySpareParts().ToString().ToLower())) || @(Pageview.User.OnlyView().ToString().ToLower())" 1337 standard-customer="@(string.IsNullOrEmpty(Pageview.AreaSettings.GetString("StandardCustomer")) ? "" : Pageview.AreaSettings.GetString("StandardCustomer"))"> 1338 1339 </async-price> 1340 </td> 1341 <td class="cell-trash"> 1342 <button @@click="removeOrderline(index)" aria-label="@Translate("Delete product")" class="text-danger"> 1343 <svg> 1344 <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/files/dist/icons/icons.svg#trash-alt"></use> 1345 </svg> 1346 </button> 1347 </td> 1348 </tr> 1349 </tbody> 1350 </table> 1351 <slot name="button"></slot> 1352 1353 </div> 1354 </div> 1355 </script> 1356 <script src="@NORRIQ.Common8.Razor.TimestampSource.GetSourceWithTimestamp("/Files/dist/scripts/vendors~bundle.min.js")"></script> 1357 <script src="@NORRIQ.Common8.Razor.TimestampSource.GetSourceWithTimestamp("/Files/dist/scripts/bundle.min.js")"></script> 1358 <script async> 1359 AppStart.VueProvider.init({ 1360 webApiUrl: '@System.Web.Configuration.WebConfigurationManager.AppSettings["WebApiProxyUrl"]', 1361 currencyCode: '@currencyCode', 1362 locale: '@Pageview.Area.Culture', 1363 currencyLeft: false, 1364 currencySpacing: true, 1365 currencySymbol: '@currencyCode', 1366 currencyDecimalSeparator: ',', 1367 currencyGroupSeparator: '.', 1368 currencyDecimalDigits: 2, 1369 dateFormatShort: '@Pageview.Area.Dateformat', 1370 languages: `@languagesJson` 1371 }); 1372 </script> 1373 1374 <script append="replace"></script> 1375 </body> 1376 </html>