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