Exception in template (Designs/Outwell/_parsed/ModulePageItem.parsed.cshtml): System.NullReferenceException: La référence d'objet n'est pas définie à une instance d'un objet.
   à OaseOutdoors.Core.Extensions.GroupExtenstion.GetAncestors(Group group, List`1 ancestors) dans C:\projects\oase\src\Core\Extensions\GroupExtenstion.cs:ligne 26
   à OaseOutdoors.Core.Extensions.GroupExtenstion.GetAncestors(Group group) dans C:\projects\oase\src\Core\Extensions\GroupExtenstion.cs:ligne 12
   à OaseOutdoors.Services.NavigationService.NavigationService.GetGroupStatus(String groupId) dans C:\projects\oase\src\Services\NavigationService\NavigationService.cs:ligne 171
   à OaseOutdoors.Services.NavigationService.NavigationService.GetNavigationForGroups(IEnumerable`1 groups, Int32 level) dans C:\projects\oase\src\Services\NavigationService\NavigationService.cs:ligne 109
   à OaseOutdoors.Services.NavigationService.NavigationService.GetNavigationLevel(IEnumerable`1 pages) dans C:\projects\oase\src\Services\NavigationService\NavigationService.cs:ligne 80
   à OaseOutdoors.Components.Shared.Layout.Master.ModelBuilders.MasterViewModelBuilder.GetViewModel(Int32 areaId) dans C:\projects\oase\src\Components\Shared\Layout\Master\ModelBuilders\MasterModelBuilder.cs:ligne 79
   à CompiledRazorTemplates.Dynamic.bfbcdfbfaeedceaa.Execute()
   à RazorEngine.Templating.TemplateBase.RazorEngine.Templating.ITemplate.Run(ExecuteContext context) dans c:\Users\abbottm\Documents\GitHub\RazorEngine\src\Core\RazorEngine.Core\Templating\TemplateBase.cs:ligne 126
   à RazorEngine.Templating.TemplateService.Run(ITemplate template, DynamicViewBag viewBag) dans c:\Users\abbottm\Documents\GitHub\RazorEngine\src\Core\RazorEngine.Core\Templating\TemplateService.cs:ligne 608
   à RazorEngine.Templating.TemplateService.Parse(String razorTemplate, Object model, DynamicViewBag viewBag, String cacheName) dans c:\Users\abbottm\Documents\GitHub\RazorEngine\src\Core\RazorEngine.Core\Templating\TemplateService.cs:ligne 439
   à RazorEngine.Razor.Parse[T](String razorTemplate, T model, DynamicViewBag viewBag, String cacheName) dans c:\Users\abbottm\Documents\GitHub\RazorEngine\src\Core\RazorEngine.Core\Razor.cs:ligne 290
   à Dynamicweb.Rendering.Template.RenderRazorTemplate()
@using System.Linq @using System.Web @using System.Web.Hosting @using Dynamicweb.Extensibility @using Dynamicweb.Frontend @using Dynamicweb.Security.UserManagement @using OaseOutdoors.Components.Shared.Layout.Master.ModelBuilders @using OaseOutdoors.Services.StaticResourceService.Initialization @using OaseOutdoors.Components.Shared.Layout.Master.Models @using OaseOutdoors.Components.Shared.Modules.Ecom.ModelBuilders @using OaseOutdoors.Core.Extensions @using OaseOutdoors.Services.MiniCartService.Initialization @using OaseOutdoors.Services.NavigationService.Models @using OaseOutdoors.Services.StaticResourceService.Interfaces @using OaseOutdoors.Services.ImageService.Enums @using OaseOutdoors.Services.EcomUrlService.Initialization @using OaseOutdoors.Services.UrlParserService.Initialization; @inherits Dynamicweb.Rendering.ViewModelTemplate<PageViewModel> @{ var area = PageView.Current().Area; var areas = Dynamicweb.Services.Areas.GetAreas().Where(x => x.Active && x.Item["ShopPublished"] != null && (bool)x.Item["ShopPublished"] && x.Name.ToLower().Contains(area.Name.Split(':')[0].Trim().ToLower())).ToList(); var masterStaticResourceService = ServiceLocator.Current.GetStaticResourceService(); var masterViewModelService = new MasterViewModelBuilder(); var masterViewModel = masterViewModelService.GetViewModel(area.ID); var productViewModelService = new ProductViewModelBuilder(); var urlService = ServiceLocator.Current.GetEcomUrlService(); var urlParserService = ServiceLocator.Current.GetUrlParserService(); var miniCartService = ServiceLocator.Current.GetMiniCartService(); var miniCartProductsCount = miniCartService.GetProductsCount(area); var valutaSelector = HttpContext.Current.Request.Cookies["currencySelector"]; var userId = HttpContext.Current.Request["userid"] != null ? HttpContext.Current.Request["userid"] : ""; var currentDatetime = DateTime.Now; var googleId = area.Item["GoogleManagerId"]; var trustlanguage = "da-DK"; var trusturl = " "; var currentUser = User.GetCurrentUser(PagePermissionLevels.Frontend); masterStaticResourceService.ActivityId = masterViewModel.NewsletterPopup.ActivityId; } @helper RenderChildren(NavigationViewModel entity, string gotoTranslation, IStaticResourceService masterStaticResourceService) { var currentDatetime = DateTime.Now; if (entity.Children == null || !entity.Children.Any()) { return; } var callToAction = (entity.CallToAction == null) ? "navigation__submenu-links--big" : ""; <ul class="navigation__submenu-links @callToAction"> @foreach (var child in entity.Children.Where(x => x.PublishedDateFrom <= currentDatetime && x.PublishedDateTo >= currentDatetime)) { if (child.Children != null && child.Children.Any()) { var childIsCurrent = (child.LinkStatus.ToString() == "IsCurrent") ? "active" : ""; <li class="@child.LinkStatus.GetDescription() parent"> <div class="navigation__submenu-links-main"> <a href="@child.Link" class="navigation__submenu-links-main-link @childIsCurrent"> <span>@child.LinkTitle @(child.IsEcommerce && child.ProductCount > 0 ? "(" + child.ProductCount + ")" : string.Empty)</span> </a> @if (child.Children != null && child.Children.Any()) { <ul class="navigation__submenu-sublinks"> @foreach (var subChild in child.Children.Where(x => x.PublishedDateFrom <= currentDatetime && x.PublishedDateTo >= currentDatetime)) { var subChildIsCurrent = (subChild.LinkStatus.ToString() == "IsCurrent") ? "active" : ""; <li> <a href="@subChild.Link" class="@subChildIsCurrent"> <span>@subChild.LinkTitle @(subChild.IsEcommerce && subChild.ProductCount > 0 ? "(" + subChild.ProductCount + ")" : string.Empty)</span> </a> </li> } </ul> } <div></div> @if (child.IsEcommerce) { <a href="@child.Link" class="btn--cta"> <svg aria-hidden="true"> <use xlink:href="@masterStaticResourceService.AddTimeStamp("/static/dist/svg/_bundle.svg")#arrow-right"></use> </svg> @if (Pageview.AreaID == 6) { <span class="btn__textnav">@Translate("See all", "See all") @child.LinkTitle</span> } else { <span class="btn__textnav">@Translate("See all", "See all") @child.LinkTitle.ToLower()</span> } </a> } </div> <div class="navigation__submenu"> <div class="container"> <div class="navigation__submenu-nav"> <div class="navigation__submenu-title"> <span><span class="navigation__submenu-name">@child.LinkTitle</span> @(child.IsEcommerce && child.ProductCount > 0 ? "(" + child.ProductCount + ")" : string.Empty)</span> </div> <ul class="navigation__submenu-links navigation__submenu-links--highlighted"> <li> <a href="@child.Link">@gotoTranslation @child.LinkTitle.ToLower()</a> </li> </ul> <div class="navigation__submenu-level"> @RenderChildren(child, gotoTranslation, masterStaticResourceService) </div> </div> </div> </div> </li> } else { var childIsCurrent = (child.LinkStatus.ToString() == "IsCurrent") ? "active" : ""; <li class="@child.LinkStatus.GetDescription()"> <div class="navigation__submenu-links-main"> <a href="@child.Link" class="navigation__submenu-links-main-link @childIsCurrent"> <span>@child.LinkTitle @(child.IsEcommerce && child.ProductCount > 0 ? "(" + child.ProductCount + ")" : string.Empty)</span> </a> </div> </li> } } </ul> } <!DOCTYPE html> <html lang="@masterViewModel.TwoLetterIsoLanguageName" class="no-js"> <head data-settings="disableparsing:true;"> @using Dynamicweb.Extensibility @using Dynamicweb.Frontend @using OaseOutdoors.Services.StaticResourceService.Initialization @inherits Dynamicweb.Rendering.ViewModelTemplate<PageViewModel> @{ var headStaticResourceService = ServiceLocator.Current.GetStaticResourceService(); var modernizerPath = "~/static/dist/js/modernizr.js"; var modernizerContent = headStaticResourceService.GetFileContent(modernizerPath); } @* todo: !!! REMOVE THIS LINE WHEN GOING LIVE !!! *@ @*<meta name="robots" content="noindex, nofollow">*@ <meta charset="utf-8"> @* Add to web.config *@ <meta http-equiv="X-UA-Compatible" content="IE=edge"> <title> @if (!string.IsNullOrEmpty(PageView.Current().Page.MetaTitle)) { @PageView.Current().Page.MetaTitle } else { @(PageView.Current().Page.MenuText + " - Outwell") } </title> @* Use this format for CSS instead if you want to use preloading: <link rel="preload" href="/static/dist/css/main.min.css" as="style" onload="this.rel='stylesheet'"> Remember to *inline* polyfills for preload-format in page footer: https://github.com/filamentgroup/loadCSS *@ <link rel="stylesheet" href="https://use.typekit.net/ykp5ilf.css"> <link rel="stylesheet" href="@headStaticResourceService.AddTimeStamp("/static/dist/css/outwell.min.css")" type="text/css"> <meta name="description" content="@Pageview.Page.Description"> <meta name="keywords" content="@Pageview.Page.Keywords"> <meta name="viewport" content="width=device-width, initial-scale=1"> <meta name="format-detection" content="telephone=no"> <link rel="icon" href="@headStaticResourceService.AddTimeStamp("/static/dist/media/favicon_ow.ico")" type="image/x-icon" /> <link rel="stylesheet" href="https://use.typekit.net/dnh4wpj.css"> @if (!headStaticResourceService.IsProduction) { <meta name="robots" content="noindex, nofollow"> } @RenderSnippet("canonical") @if (headStaticResourceService.IsProduction) { <script type="text/javascript" charset="UTF-8" src="//cdn.cookie-script.com/s/67eb1e7e76199dfcfddcd855be5a81f5.js"></script> var googleManagerId = PageView.Current().Area.Item["GoogleManagerId"]; <!-- Google Tag Manager --> <script> (function (w, d, s, l, i) { w[l] = w[l] || []; w[l].push({ 'gtm.start': new Date().getTime(), event: 'gtm.js' }); var f = d.getElementsByTagName(s)[0], j = d.createElement(s), dl = l != 'dataLayer' ? '&l=' + l : ''; j.async = true; j.src = 'https://www.googletagmanager.com/gtm.js?id=' + i + dl; f.parentNode.insertBefore(j, f); })(window, document, 'script', 'dataLayer', '@googleManagerId');</script> <!-- End Google Tag Manager --> if (Pageview.AreaID == 5) { <!-- Bing --> <script> (function (w, d, t, r, u) { var f, n, i; w[u] = w[u] || [], f = function () { var o = { ti: "25049519" }; o.q = w[u], w[u] = new UET(o), w[u].push("pageLoad") }, n = d.createElement(t), n.src = r, n.async = 1, n.onload = n.onreadystatechange = function () { var s = this.readyState; s && s !== "loaded" && s !== "complete" || (f(), n.onload = n.onreadystatechange = null) }, i = d.getElementsByTagName(t)[0], i.parentNode.insertBefore(n, i) })(window, document, "script", "//bat.bing.com/bat.js", "uetq"); </script> <!-- End Bing --> } <!-- Meta Pixel Code --> <script> !function (f, b, e, v, n, t, s) { if (f.fbq) return; n = f.fbq = function () { n.callMethod ? n.callMethod.apply(n, arguments) : n.queue.push(arguments) }; if (!f._fbq) f._fbq = n; n.push = n; n.loaded = !0; n.version = '2.0'; n.queue = []; t = b.createElement(e); t.async = !0; t.src = v; s = b.getElementsByTagName(e)[0]; s.parentNode.insertBefore(t, s) }(window, document, 'script', 'https://connect.facebook.net/en_US/fbevents.js'); fbq('init', '347679100934725'); fbq('track', 'PageView'); </script> <noscript> <img height="1" width="1" style="display:none" src="https://www.facebook.com/tr?id=347679100934725&ev=PageView&noscript=1" /> </noscript> <!-- End Meta Pixel Code --> } <!-- Start of Sleeknote signup and lead generation tool - www.sleeknote.com --> <script id="sleeknoteScript" type="text/javascript"> (function () { var sleeknoteScriptTag = document.createElement("script"); sleeknoteScriptTag.type = "text/javascript"; sleeknoteScriptTag.charset = "utf-8"; sleeknoteScriptTag.src = ("//sleeknotecustomerscripts.sleeknote.com/165047.js"); var s = document.getElementById("sleeknoteScript"); s.parentNode.insertBefore(sleeknoteScriptTag, s); })(); </script> <!-- End of Sleeknote signup and lead generation tool - www.sleeknote.com --> <!-- TrustBox script --> <script type="text/javascript" src="//widget.trustpilot.com/bootstrap/v5/tp.widget.bootstrap.min.js" async></script> <!-- End TrustBox script --> @* You can use "prefetch" to preload all important assets if you're not using HTTP/2 push *@ <link rel="prefetch" href="@headStaticResourceService.AddTimeStamp("/static/dist/js/main.min.js")"> <script> @if (!string.IsNullOrWhiteSpace(modernizerContent)) { @modernizerContent } </script> @*<script type="text/javascript" src="//fast.fonts.net/jsapi/435e879a-fed1-4494-b286-69490b465a2f.js"></script>*@ @SnippetStart("canonical") @if (PageView.Current().Page.NavigationTag != "ecommerce") { <link rel="canonical" href="@masterViewModel.Canonical" /> foreach (var hrefLang in masterViewModel.HrefLangs) { <link rel="alternate" hreflang="@hrefLang.HrefLang" href="@hrefLang.Href" /> } } @SnippetEnd("canonical") </head> <body data-area-id="@Pageview.AreaID" data-area-currencyCode="@Pageview.Area.EcomCurrencyId" data-search-see-all="@Translate("SearchSeeAll", "See all")" data-search-results="@Translate("SearchResults", "search results")"> @if (masterStaticResourceService.IsProduction) { <!-- Google Tag Manager (noscript) --> <noscript> <iframe src="https://www.googletagmanager.com/ns.html?id=@googleId" height="0" width="0" style="display:none;visibility:hidden"></iframe> </noscript> <!-- End Google Tag Manager (noscript) --> } @if (HttpContext.Current.IsDebuggingEnabled) { <script id="__bs_script__"> document.write("<script async src='https://localhost:3000/browser-sync/browser-sync-client.js?v=2.18.13'><\/script>"); </script> } <input type="checkbox" name="header__expand-search" id="header__expand-search" class="hidden" /> <div class="header" data-module="header"> <div class="header__info"> @if (masterViewModel.TopMessage != null && (!string.IsNullOrEmpty(masterViewModel.TopMessage.ShortText) || !string.IsNullOrEmpty(masterViewModel.TopMessage.LongText))) { if (valutaSelector == null || PageView.Current().AreaID != 1) { if (!string.IsNullOrEmpty(masterViewModel.TopMessage.ShortText)) { <div class="header__info-content header__info-content--short"> <p>@masterViewModel.TopMessage.ShortText</p> </div> } if (!string.IsNullOrEmpty(masterViewModel.TopMessage.LongText)) { <div class="header__info-content header__info-content--long"> <p>@masterViewModel.TopMessage.LongText</p> </div> } } } </div> <div class="header__main"> <div class="container-fluid"> <div class="header__main-content"> <div class="header__expand-menu"> <button style="font-size:8px;"><span><span></span></span></button> <div class="header__expand-menu-title">MENU</div> </div> <div onclick="activatesearch();" id="search-overlay" class="search-overlay" data-search-url="@masterViewModel.SearchResultsPageLink" data-no-results="@Translate("SearchNoResults", "Sorry no results were found")" data-products-title="@Translate("SearchProducts", "Products")" data-categories-title="@Translate("SearchCategories", "Categories")" data-pages-title="@Translate("SearchPages", "Information pages")"> <div class="container-fluid"> <div class="search-overlay__input"> <input type="search" name="search" id="search" placeholder="@Translate("SearchFindLabel", "Find what you are looking for")" /> <svg class="searchinputicon"> <use xlink:href="@masterStaticResourceService.AddTimeStamp("/static/dist/svg/_bundle.svg")#search-simple"></use> </svg> </div> <div id="search-overlay__container" class="search-overlay__container"> <div class="container" style="background: #efeeed;"> <div id="search-overlay__results" class="search-overlay__results"></div> </div> </div> </div> </div> @if (masterViewModel.FriendsIsActive) { if (currentUser != null) { <a href="/@masterViewModel.FriendsLoginPage" class="header__friends"><img src="@masterStaticResourceService.AddTimeStamp("/static/dist/img/outwell/login-icon-mobile.jpg")" alt="@Translate("Outwell Friends", "Outwell Friends")" /></a> } else { <a href="/@masterViewModel.FriendsLoginPage" class="header__friends"><img src="@masterStaticResourceService.AddTimeStamp("/static/dist/img/outwell/login-icon-mobile.jpg")" alt="@Translate("Outwell Friends", "Outwell Friends")" /></a> } } <div class="header__dealer"> @{ var dealerlink = (area.ID == 1) ? "/en-gb/find-outwell-dealer" : (area.ID == 5) ? "/da-dk/find-outwell-forhandler" : (area.ID == 6) ? "/de-de/outwell-handler-finden" : (area.ID == 2) ? "/fr-fr/trouver-un-outwell-revendeur" : (area.ID == 3) ? "/nl-nl/zoek-een-outwell-dealer" : (area.ID == 4) ? "/sv-se/hitta-outwell-aaterforsaljare" : "/en-gb/find-outwell-dealer-1"; } <a href="@dealerlink" class="service-menu__finddealer"> <img src="/static/dist/svg/Robens_finddealer.svg"> </a> </div> <a href="/@area.Culture.ToLower()/favorites" class="header__favorites" data-module="cookiefavoriteheader"> <svg xmlns="https://www.w3.org/2000/svg" width="34" height="34" fill="#000000" class="" viewBox="0 0 20 20"> <path d="m8 2.748-.717-.737C5.6.281 2.514.878 1.4 3.053c-.523 1.023-.641 2.5.314 4.385.92 1.815 2.834 3.989 6.286 6.357 3.452-2.368 5.365-4.542 6.286-6.357.955-1.886.838-3.362.314-4.385C13.486.878 10.4.28 8.717 2.01L8 2.748zM8 15C-7.333 4.868 3.279-3.04 7.824 1.143c.06.055.119.112.176.171a3.12 3.12 0 0 1 .176-.17C12.72-3.042 23.333 4.867 8 15z" /> </svg> <span class="header__favorites__badge">0</span> </a> @if (!string.IsNullOrWhiteSpace(masterViewModel.CheckoutPageLink) && !string.IsNullOrWhiteSpace(masterViewModel.CartContext)) { if (valutaSelector == null || PageView.Current().AreaID != 1) { <a href="@masterViewModel.CheckoutPageLink" class="header__cart"> <svg role="img" aria-label="Kurv"><use xlink:href="@masterStaticResourceService.AddTimeStamp("/static/dist/svg/_bundle.svg")#cart"></use></svg> <div class="header__cart-amount"> <div>@miniCartProductsCount</div> </div> </a> } } <div class="header__logo"> <a href="@masterViewModel.Logo.LogoLink"> <div class="header__logo-icon header__logo-icon--detailed"> <svg aria-hidden="true"><use xlink:href="@masterStaticResourceService.AddTimeStamp("/static/dist/svg/_bundle.svg")#outwell-logo"></use></svg> </div> <div class="header__logo-icon header__logo-icon--simple"> <svg aria-hidden="true"><use xlink:href="@masterStaticResourceService.AddTimeStamp("/static/dist/svg/_bundle.svg")#outwell-logo"></use></svg> </div> </a> </div> </div> </div> </div> <div class="header__menus"> <div class="header__menus-inside"> <div class="navigation"> <div class="container"> <button class="navigation__back"> <svg aria-hidden="true"><use xlink:href="@masterStaticResourceService.AddTimeStamp("/static/dist/svg/_bundle.svg")#arrow-left"></use></svg> <span>@Translate("MainMenu", "Main menu")</span> </button> @if (masterViewModel.Navigation.Any()) { <ul class="navigation__mainmenu"> @foreach (var item in masterViewModel.Navigation.Where(x => x.PublishedDateFrom <= currentDatetime && x.PublishedDateTo >= currentDatetime)) { if (item.Children.Any()) { <li class="navigation__mainmenu-item @item.LinkStatus.GetDescription() parent"> <div class="navigation__mainmenu-link"> <a href="@item.Link">@item.LinkTitle</a> <div></div> </div> <div class="navigation__submenu @(item.IsEcommerce && item.CallToAction != null ? string.Empty : "navigation__submenu--no-detail")"> <div class="container"> <div class="navigation__submenu-nav"> <div class="navigation__submenu-title"> <span><span class="navigation__submenu-name">@item.LinkTitle</span> @(item.IsEcommerce && item.ProductCount > 0 ? "(" + item.ProductCount + ")" : string.Empty)</span> </div> <div class="navigation__submenu-nav--flex"> @RenderChildren(item, Translate("NavigationGoToTranslation", "Go to"), masterStaticResourceService) @if (item.CallToAction != null) { @RenderParagraphContent(item.CallToAction.Id); } </div> @if (item.IsEcommerce) { <a href="@item.Link" class="btn--cta-bg"> <svg aria-hidden="true"> <use xlink:href="@masterStaticResourceService.AddTimeStamp("/static/dist/svg/_bundle.svg")#arrow-right"></use> </svg> @if (Pageview.AreaID == 6) { <span class="btn__textnav">@Translate("See all", "See all") @item.LinkTitle</span> } else { <span class="btn__textnav">@Translate("See all", "See all") @item.LinkTitle.ToLower()</span> } </a> } </div> </div> </div> </li> } else { <li class="navigation__mainmenu-item @item.LinkStatus.GetDescription()"> <div class="navigation__mainmenu-link @item.LinkStatus.GetDescription()"> <a href="@item.Link">@item.LinkTitle</a> </div> </li> } } </ul> } </div> @if (masterViewModel.Languages.Any()) { <div class="country-picker"> <header> <div class="container"> <span>@Translate("ChooseAnotherCountry", "Choose another country")</span> <button class="country-picker__close"> <svg aria-hidden="true"> <use xlink:href="@masterStaticResourceService.AddTimeStamp("/static/dist/svg/_bundle.svg")#close"></use> </svg> </button> </div> </header> <div class="container"> <div class="country-picker__list"> <h3><span>@Translate("ChooseCountry", "Choose country")</span></h3> @RenderSnippet("languageSelector") @SnippetStart("languageSelector") @if (PageView.Current().Page.NavigationTag != "ecommerce") { <ul> @foreach (var languageArea in areas) { var hrefLang = masterViewModel.HrefLangs.FirstOrDefault(x => x.HrefAreaId == languageArea.ID); if (hrefLang == null || hrefLang.Href.ToLower().Contains("page-not-found")) { hrefLang = new HrefLangViewModel(); hrefLang.HrefName = languageArea.Item["ShopLanguageName"].ToString() ?? string.Empty; hrefLang.HrefLang = languageArea.CultureInfo.Name; hrefLang.Href = "/Default.aspx?areaid=" + languageArea.ID; hrefLang.HrefAreaId = languageArea.ID; } if (hrefLang != null && hrefLang.HrefLang != "x-default") { <li class="country-picker__item @(hrefLang.HrefAreaId == Pageview.AreaID ? "country-picker__item--current" : string.Empty)"> <a href="@hrefLang.Href"> <svg aria-hidden="true"> <use xlink:href="@masterStaticResourceService.AddTimeStamp("/static/dist/svg/_bundle.svg")#arrow-right"></use> </svg> <span>@hrefLang.HrefName</span> </a> </li> } } </ul> } @SnippetEnd("languageSelector") </div> </div> </div> } </div> @{ var noBasket = "service-menu--no-basket"; if (!string.IsNullOrWhiteSpace(masterViewModel.CheckoutPageLink) && !string.IsNullOrWhiteSpace(masterViewModel.CartContext)) { if (valutaSelector == null || Pageview.AreaID != 1) { noBasket = ""; } } } <div class="service-menu @noBasket"> <div class="container"> <ul class="service-menu__navigation"> @foreach (PageLinkItem linkItem in masterViewModel.ServiceMenu.MenuItems) { <li> <a href="@linkItem.PageLink">@linkItem.PageLinkTitle</a> </li> } @if (masterViewModel.FriendsIsActive) { <li> @if (currentUser != null) { <button onclick="javascript:window.location='/@masterViewModel.FriendsLoginPage'" class="service-menu__friends"><img src="@masterStaticResourceService.AddTimeStamp("/static/dist/img/outwell/login-icon-known.jpg")" alt="@Translate("Outwell Friends", "Outwell Friends")" /><span>@Translate("Go to", "Go to")</span></button> } else { <button class="service-menu__friends"><img src="@masterStaticResourceService.AddTimeStamp("/static/dist/img/outwell/login-icon-unknown.jpg")" alt="@Translate("Outwell Friends", "Outwell Friends")" /><span>@Translate("Login", "Login")</span></button> } </li> } @if (masterViewModel.Languages.Any()) { var languageName = masterViewModel.Languages.First(x => x.IsCurrent).Name; var languageCode = (area.ID == 31) ? "eu" : masterViewModel.Languages.First(x => x.IsCurrent).ISOCode; <li> <div class="service-menu__language"> <span class="service-menu__language-flag"><svg aria-hidden="true"><use xlink:href="@masterStaticResourceService.AddTimeStamp("/static/dist/svg/_bundle.svg")#flag-@languageCode"></use></svg></span> <span class="service-menu__language-title">@Translate("Language", "Language")</span> <span class="service-menu__language-value">@masterViewModel.Languages.First(x => x.IsCurrent).Name</span> </div> </li> } </ul> <div class="service-menu__info"> <div class="service-menu__logo"> <svg aria-hidden="true"><use xlink:href="@masterStaticResourceService.AddTimeStamp("/static/dist/svg/_bundle.svg")#outwell-logo-simple"></use></svg> </div> @if (!string.IsNullOrEmpty(masterViewModel.Footer.ContactUsPhone)) { <a href="tel:@masterViewModel.Footer.ContactUsPhone">@masterViewModel.Footer.ContactUsPhone</a> } <dl class="service-menu__opening-hours"> @foreach (var hoursItem in masterViewModel.Footer.OpeningHours) { <dt>@hoursItem.DaysLocalized</dt> <dd class="opening__hours">@hoursItem.StartTime-@hoursItem.EndTime</dd> } </dl> </div> </div> </div> </div> </div> </div> <main> @using Dynamicweb.Frontend; @using Dynamicweb.Rendering; @using OaseOutdoors.Components.Shared.Layout.Master.ModelBuilders; @inherits ViewModelTemplate<PageViewModel> @Title("Content page template") @{ var masterService = new MasterViewModelBuilder(); var masterModel = masterService.GetViewModel(PageView.Current().Area.ID); } @Model.Placeholder("Body", "Body", "items-allowed:EcomRibbonItem;unwrap:true") @RenderParagraphContent(masterModel.NewsletterAndConsentSubscriptionPargraphId) @if (masterViewModel.FriendsIsActive && currentUser == null) { if (masterViewModel.FriendsLoginParagraphId > 0 && masterViewModel.FriendsSignupParagraphId > 0) { <div id="LoginPopupModal" class="login-popup" data-module="loginPopup"> <div class="modal-content-html"> <span class="login-popup-modal__close">&times;</span> <section class="login-popup-modal__content"> <ul class="login-popup-modal__headers"> <li class="login-popup-modal__login-button active">@Translate("Login", "Login")</li> <li class="login-popup-modal__signup-button">@Translate("I want to join the club", "I want to join the club")</li> </ul> <div class="login-popup-modal__login-area active">@RenderParagraphContent(masterViewModel.FriendsLoginParagraphId)</div> <div class="login-popup-modal__signup-area">@RenderParagraphContent(masterViewModel.FriendsSignupParagraphId)</div> </section> </div> </div> } } </main> <footer class="footer container-fluid"> <div class="footer__logo--container"> <svg aria-hidden="true" class="footer__logo--icon"> <use xlink:href="@masterStaticResourceService.AddTimeStamp("/static/dist/svg/_bundle.svg")#outwell-logo-simple"></use> </svg> </div> <div class="container"> <div class="footer__content"> <input type="checkbox" id="footer-toggle" checked> <div class="footer__navigation"> @if (!string.IsNullOrEmpty(masterViewModel.Footer.CallToActionLink) && !string.IsNullOrEmpty(masterViewModel.Footer.CallToActionLinkTitle)) { <a href="@masterViewModel.Footer.CallToActionLink" class="btn btn--filled" style="color:#2A3075;"> <span class="btn__text">@masterViewModel.Footer.CallToActionLinkTitle</span> </a> } <br /> @if (!string.IsNullOrEmpty(masterViewModel.Footer.FindDealerLinkTitle) && !string.IsNullOrEmpty(masterViewModel.Footer.FindDealerLink)) { <a href="@masterViewModel.Footer.FindDealerLink" class="btn btn--filled" style="color:#b3c500;"> <span class="btn__text">@masterViewModel.Footer.FindDealerLinkTitle</span> </a> } @if (!string.IsNullOrEmpty(masterViewModel.Footer.ContactUsMobileButtonText)) { <label for="footer-toggle" class="btn btn--filled footer-toggle-btn"> <span class="btn__icon"> <svg role="img"> <use xlink:href="@masterStaticResourceService.AddTimeStamp("/static/dist/svg/_bundle.svg")#arrow-right"></use> </svg> </span> <span class="btn__text">@masterViewModel.Footer.ContactUsMobileButtonText</span> </label> } </div> <div class="footer__information"> <div class="footer__information-inner"> <div class="footer__information-column footer__information-column--desktop"> @if (!string.IsNullOrEmpty(masterViewModel.Footer.CustomerServiceLink) && !string.IsNullOrEmpty(masterViewModel.Footer.CustomerServiceLinkTitle)) { <div class="footerH3"> <a href="@masterViewModel.Footer.CustomerServiceLink"> <span class="footer__heading-icon"> <svg role="img"> <use xlink:href="@masterStaticResourceService.AddTimeStamp("/static/dist/svg/_bundle.svg")#arrow-right"></use> </svg> </span> <span class="footer__heading-text">@masterViewModel.Footer.CustomerServiceLinkTitle</span> </a> </div> } @if (!string.IsNullOrEmpty(masterViewModel.Footer.CallToActionLink) && !string.IsNullOrEmpty(masterViewModel.Footer.CallToActionLinkTitle)) { <a style="color: #2A3075; min-width: 250px;" href="@masterViewModel.Footer.CallToActionLink" class="btn btn--filled footer-toggle-btn footer__information-btn"> <span class="btn__icon"> <svg role="img"> <use xlink:href="@masterStaticResourceService.AddTimeStamp("/static/dist/svg/_bundle.svg")#arrow-right"></use> </svg> </span> <span class="btn__text">@masterViewModel.Footer.CallToActionLinkTitle</span> </a> } @if (!string.IsNullOrEmpty(masterViewModel.Footer.CallToActionLink) && !string.IsNullOrEmpty(masterViewModel.Footer.CallToActionLinkTitle)) { <br /><br /> <a style="min-width:250px;color:#b3c500;" href="@masterViewModel.Footer.FindDealerLink" class="btn btn--filled footer-toggle-btn footer__information-btn"> <span class="btn__icon"> <svg role="img"> <use xlink:href="@masterStaticResourceService.AddTimeStamp("/static/dist/svg/_bundle.svg")#arrow-right"></use> </svg> </span> <span class="btn__text">@masterViewModel.Footer.FindDealerLinkTitle</span> </a> } </div> <div class="footer__information-column" itemscope itemtype="https://schema.org/LocalBusiness"> <div> @if (!string.IsNullOrEmpty(masterViewModel.Footer.AddressTitle)) { <div class="footerH3"> @masterViewModel.Footer.AddressTitle </div> } <link itemprop="image" content="@masterStaticResourceService.GetAbsoluteUrl("~/static/dist/svg/outwell-logo.svg")"> <div itemprop="name">@masterViewModel.Footer.AddressCompany</div> <ul itemprop="address" itemscope itemtype="https://schema.org/PostalAddress"> <li itemprop="streetAddress">@masterViewModel.Footer.AddressStreet</li> <li> <span itemprop="postalCode">@masterViewModel.Footer.AddressPostcode</span> <span itemprop="addressLocality">@masterViewModel.Footer.AddressCity</span></li> <li itemprop="addressCountry">Denmark@* TODO: add country to viewmodel @masterViewModel.Footer.AddressCountry*@</li> </ul> <ul> <li><a href="mailto:@masterViewModel.Footer.ContactUsEmail" itemprop="email">@masterViewModel.Footer.ContactUsEmail</a></li> @if (!string.IsNullOrEmpty(masterViewModel.Footer.ContactUsFax)) { <li itemprop="faxNumber">Fax: @masterViewModel.Footer.ContactUsFax</li> } </ul> <meta itemprop="telephone" name="phone" content="@masterViewModel.Footer.ContactUsPhone"> </div> <div> @if (!string.IsNullOrEmpty(masterViewModel.Footer.OpeningHoursTitle)) { <div class="footerH3"> @masterViewModel.Footer.OpeningHoursTitle </div> } <ul> @foreach (var hoursItem in masterViewModel.Footer.OpeningHours) { <li><span class="opening-days">@hoursItem.DaysLocalized</span> <span class="opening-hours">@hoursItem.StartTime-@hoursItem.EndTime</span></li> } @if (!string.IsNullOrEmpty(masterViewModel.Footer.ContactUsPhone)) { <li class="opening-hours">@masterViewModel.Footer.ContactUsPhone</li> } </ul> @foreach (var hoursViewModel in masterViewModel.Footer.OpeningHours) { <meta itemprop="openingHours" content="@hoursViewModel.StartDay-@hoursViewModel.EndDay @hoursViewModel.StartTime-@hoursViewModel.EndTime" /> } </div> </div> <div class="footer__information-column"> @if (!string.IsNullOrEmpty(masterViewModel.Footer.AboutLinkTitle) && !string.IsNullOrEmpty(masterViewModel.Footer.AboutLink)) { <div class="footerH3"> <a href="@masterViewModel.Footer.AboutLink"> <span class="footer__heading-icon"> <svg role="img"> <use xlink:href="@masterStaticResourceService.AddTimeStamp("/static/dist/svg/_bundle.svg")#arrow-right"></use> </svg> </span> <span class="footer__heading-text">@masterViewModel.Footer.AboutLinkTitle</span> </a> </div> } @if (masterViewModel.Footer.AboutLinks.Any()) { <ul> @foreach (var link in masterViewModel.Footer.AboutLinks) { <li><a href="@link.PageLink">@link.PageLinkTitle</a></li> } </ul> } </div> <div class="footer__information-column"> @if (!string.IsNullOrEmpty(masterViewModel.Footer.ShippingTitle)) { <div class="footerH3"> @masterViewModel.Footer.ShippingTitle </div> } @if (!string.IsNullOrEmpty(masterViewModel.Footer.ShippingBodyText)) { @masterViewModel.Footer.ShippingBodyText } @if (masterViewModel.Footer.ShippingLinks.Any()) { <ul> @foreach (var link in masterViewModel.Footer.ShippingLinks) { <li><a href="@link.PageLink">@link.PageLinkTitle</a></li> } </ul> } </div> </div> </div> <div class="footer__social"> @if (!string.IsNullOrEmpty(masterViewModel.Footer.SocialMediaTitle)) { <div class="footerH3"> @masterViewModel.Footer.SocialMediaTitle </div> } @if (!string.IsNullOrEmpty(masterViewModel.Footer.SocialMediaFacebookLink)) { <a href="@Translate("SoMeFacebookLink", "https://www.facebook.com/outwell/")" target="_blank" class="footer__social-icon" title="@masterViewModel.Footer.SocialMediaFacebookLinkTitle"> <span> <svg aria-hidden="true"> <use xlink:href="@masterStaticResourceService.AddTimeStamp("/static/dist/svg/_bundle.svg")#some-facebook"></use> </svg> </span> </a> } @if (!string.IsNullOrEmpty(masterViewModel.Footer.SocialMediaInstagramLink)) { <a href="@Translate("SoMeInstagramLink", "https://www.instagram.com/outwelltents/")" target="_blank" class="footer__social-icon" title="@masterViewModel.Footer.SocialMediaInstagramLinkTitle"> <span> <svg aria-hidden="true"> <use xlink:href="@masterStaticResourceService.AddTimeStamp("/static/dist/svg/_bundle.svg")#some-instagram"></use> </svg> </span> </a> } @if (!string.IsNullOrEmpty(masterViewModel.Footer.SocialMediaTwitterLink)) { <a href="@Translate("SoMeTwitterLink", "https://twitter.com/Outwelltents")" target="_blank" class="footer__social-icon" title="@masterViewModel.Footer.SocialMediaTwitterLinkTitle"> <span> <svg aria-hidden="true"> <use xlink:href="@masterStaticResourceService.AddTimeStamp("/static/dist/svg/_bundle.svg")#some-twitter"></use> </svg> </span> </a> } @if (!string.IsNullOrEmpty(masterViewModel.Footer.SocialMediaYoutubeLink)) { <a href="@Translate("SoMeYoutubeLink", "https://www.youtube.com/user/Outwelltents")" target="_blank" class="footer__social-icon" title="@masterViewModel.Footer.SocialMediaYoutubeLinkTitle"> <span> <svg aria-hidden="true"> <use xlink:href="@masterStaticResourceService.AddTimeStamp("/static/dist/svg/_bundle.svg")#some-youtube"></use> </svg> </span> </a> } <!-- TrustBox widget - Mini --> @if (Pageview.AreaID == 5) { trustlanguage = "da-DK"; trusturl = "https://dk.trustpilot.com/review/www.outwell.com"; } @if (Pageview.AreaID == 1 || Pageview.AreaID == 31) { trustlanguage = "en-GB"; trusturl = "https://uk.trustpilot.com/review/www.outwell.com"; } @if (Pageview.AreaID == 2) { trustlanguage = "fr-FR"; trusturl = "https://fr.trustpilot.com/review/www.outwell.com"; } @if (Pageview.AreaID == 6) { trustlanguage = "de-DE"; trusturl = "https://de.trustpilot.com/review/www.outwell.com"; } @if (Pageview.AreaID == 3) { trustlanguage = "nl-NL"; trusturl = "https://nl.trustpilot.com/review/www.outwell.com"; } @if (Pageview.AreaID == 4) { trustlanguage = "sv-SE"; trusturl = "https://se.trustpilot.com/review/www.outwell.com"; } <div style="margin-top:20px;"> <div class="trustpilot-widget" data-locale="@trustlanguage" data-template-id="53aa8807dec7e10d38f59f32" data-businessunit-id="4853f9a2000064000502b56f" data-style-height="150px" data-style-width="100%" data-theme="dark"> <a href="@trusturl" target="_blank" rel="noopener">Trustpilot</a> </div> </div> <!-- End TrustBox widget --> </div> </div> </div> <div class="footer__bottom"> @if (!string.IsNullOrEmpty(masterViewModel.Footer.BottomDesignText)) { <div class="footer__bottom-column"> <span class="outwell-flag"> <svg aria-hidden="true"> <use xlink:href="@masterStaticResourceService.AddTimeStamp("/static/dist/svg/_bundle.svg")#flag-da"></use> </svg> </span> <span>@masterViewModel.Footer.BottomDesignText</span> </div> } @if (masterViewModel.Footer.BottomPaymentLogos != null && masterViewModel.Footer.BottomPaymentLogos.Any()) { <div class="footer__bottom-column"> @foreach (var paymentName in masterViewModel.Footer.BottomPaymentLogos) { <span class="footer__payment-icon"> @if (paymentName.ToLower() == "visa") { <img src="@masterStaticResourceService.AddTimeStamp("/static/dist/img/visa_blue.png")" alt="Visa" style="height:25px;" /> } else { <svg aria-hidden="true" style="@(paymentName.ToLower() == "mobilepay" ? "width: 80px;" : "")"> <use xlink:href="@masterStaticResourceService.AddTimeStamp("/static/dist/svg/_bundle.svg")#pay-@paymentName.ToLower()"></use> </svg> } </span> } </div> } <div class="footer__bottom-column"> <p> @if (!string.IsNullOrEmpty(masterViewModel.Footer.BottomPolicyLink) && !string.IsNullOrEmpty(masterViewModel.Footer.BottomPolicyLinkTitle)) { <a href="@masterViewModel.Footer.BottomPolicyLink">@masterViewModel.Footer.BottomPolicyLinkTitle</a> } @if (!string.IsNullOrEmpty(masterViewModel.Footer.BottomCopyrightText)) { @masterViewModel.Footer.BottomCopyrightText } </p> </div> </div> </footer> @SnippetStart("jarvis") @{ var raptorArea = PageView.Current().Area; var settingsRaptorApiKey = raptorArea.Item["SettingsRaptorApiKey"]; } @if (settingsRaptorApiKey != null) { if (PageView.Current().Page.NavigationTag != "ecommerce" && PageView.Current().Device == Dynamicweb.Frontend.Devices.DeviceType.Desktop && !string.IsNullOrEmpty(settingsRaptorApiKey.ToString())) { var jarvis = (HttpContext.Current.Request.Cookies["jarvis"] != null) ? HttpContext.Current.Request.Cookies["jarvis"].Value : "1"; var jarvisBoxStatus = (jarvis == "1") ? "jarvis--open" : string.Empty; var jarvisBtnStatus = (jarvis == "1") ? "" : "jarvis-btn--open"; var raptorAreaId = raptorArea.ID; var raptorBrandId = (raptorArea.Item["SettingsRaptorUserId"] != null) ? raptorArea.Item["SettingsRaptorUserId"].ToString() : string.Empty; var raptorCookieId = (HttpContext.Current.Request.Cookies[raptorBrandId + "rsa"] != null) ? HttpContext.Current.Request.Cookies[raptorBrandId + "rsa"].Value : ""; var raptorContent1 = masterViewModel.JarvisHistory; var raptorContent2 = masterViewModel.JarvisRecommendations; var settingsShopId = raptorArea.Item["SettingsShopId"].ToString(); var ecomPageId = urlParserService.GetPageId(settingsShopId); if (!string.IsNullOrEmpty(raptorCookieId)) { <div data-module="jarvis"> <div class="jarvis @jarvisBoxStatus"> <div class="jarvis__header"> <span class="your">@Translate("Your", "Your")</span> <span class="guide">@Translate("Guide", "Guide")</span> <span class="logo"></span> </div> <div class="jarvis__guide"> <button class="jarvis__close"><span class="round"><svg viewBox="0 0 100 100"><path d="M 10,50 L 60,100 L 70,90 L 30,50 L 70,10 L 60,0 Z" class="arrow"></path></svg></span> @Translate("Hide the wizard", "Hide the wizard")</button> <div class="jarvis__text"> <p> @Translate("The guide follows you around and finds new recommendations based on what you're looking at.", "The guide follows you around and finds new recommendations based on what you're looking at.") </p> </div> </div> <div id="GetCookieRecommendations" class="jarvis__alternatives"> <section class="featured-products container-ribbon ribbon"> <h3>@Translate("Good alternatives", "Good alternatives")</h3> <div class="featured-products__container" data-url="/webservices/jarvis.ashx?areaId=@raptorAreaId&raptorFunction=GetCookieRecommendations"> @foreach (var raptorProduct in raptorContent2) { var raptorProductView = productViewModelService.GetViewModel(raptorProduct); if (raptorProductView.MainImage != null) { raptorProductView.RaptorImage = raptorProductView.MainImage.SetWidth(500).SetHeight(300).SetCrop(CropType.KeepAspectRatio).SetCompression(50).GetCrop(); } raptorProductView.RaptorUrl = urlService.GetUrl(raptorProductView.GroupId, raptorProductView.Id, ecomPageId.GetValueOrDefault()); <article itemscope itemtype="https://schema.org/Product\" class="product-item"> <a itemprop="url" href="@raptorProductView.RaptorUrl" data-raptorrecommendation="productId:@raptorProductView.ProductNumber"> <div class="product-item__header"> <figure> <img src="@raptorProductView.RaptorImage" itemprop="image" content="OaseOutdoors.Services.ImageService.ImageService" alt="@raptorProductView.Name"> </figure> </div> <div class="product-item__body"> <div class="product-item__headline"> <h3 itemprop="name" class="h-1">@raptorProductView.Name</h3> </div> <div itemprop="offers" itemscope itemtype="https://schema.org/Offer" class="product-item__price"> <div class="price"><span itemprop=\"priceCurrency\" content="@raptorProductView.Currency">@raptorProductView.CurrencySymbol</span> <span itemprop="price" content="@raptorProductView.UnformatedPrice">@raptorProductView.Price</span></div> </div> </div> </a> </article> } </div> </section> </div> <div id="GetCookieHistory" class="jarvis__suggest"> <section class="featured-products container-ribbon ribbon"> <h3>@Translate("You have previously looked at", "You have previously looked at")</h3> <div class="featured-products__container" data-url="/webservices/jarvis.ashx?areaId=@raptorAreaId&raptorFunction=GetCookieHistory"> @foreach (var raptorProduct in raptorContent1) { var raptorProductView = productViewModelService.GetViewModel(raptorProduct); if (raptorProductView.MainImage != null) { raptorProductView.RaptorImage = raptorProductView.MainImage.SetWidth(500).SetHeight(300).SetCrop(CropType.KeepAspectRatio).SetCompression(50).GetCrop(); } raptorProductView.RaptorUrl = urlService.GetUrl(raptorProductView.GroupId, raptorProductView.Id, ecomPageId.GetValueOrDefault()); <article itemscope itemtype="https://schema.org/Product\" class="product-item"> <a itemprop="url" href="@raptorProductView.RaptorUrl" data-raptorrecommendation="productId:@raptorProductView.ProductNumber"> <div class="product-item__header"> <figure> <img src="@raptorProductView.RaptorImage" itemprop="image" content="OaseOutdoors.Services.ImageService.ImageService" alt="@raptorProductView.Name"> </figure> </div> <div class="product-item__body"> <div class="product-item__headline"> <h3 itemprop="name" class="h-1">@raptorProductView.Name</h3> </div> <div itemprop="offers" itemscope itemtype="https://schema.org/Offer" class="product-item__price"> <div class="price"><span itemprop=\"priceCurrency\" content="@raptorProductView.Currency">@raptorProductView.CurrencySymbol</span> <span itemprop="price" content="@raptorProductView.UnformatedPrice">@raptorProductView.Price</span></div> </div> </div> </a> </article> } </div> </section> </div> </div> <div class="jarvis-btn @jarvisBtnStatus"> <img src="/static/dist/img/jarvis/jarvis-small.png"> </div> </div> } } } @SnippetEnd("jarvis") @RenderSnippet("jarvis") <script> function activatesearch() { var element = document.getElementById("search-overlay"); element.className += " active"; } const parent = document.getElementById('search-overlay__results'); window.addEventListener('click', e => { let elem = e.target; for (; elem && elem !== document; elem = elem.parentNode) { if (elem === parent) { return false; } } document.getElementById('search-overlay__results').innerHTML = ""; document.getElementById('search').value = ""; }); </script> <script> var s = document.createElement("script"); s.type = "text/javascript"; s.src = "/static/dist/js/main.min.js?v=14"; document.body.appendChild(s); </script> <script> var s = document.createElement("script"); s.type = "text/javascript"; s.src = "/static/dist/relewise/relewise-custom.js?v=14"; document.body.appendChild(s); </script> </body> </html>