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