Group levet 4
Populære produkter
We did not find anything matching your search result
We did not find anything matching your search result
We did not find anything matching your search result
Error executing template "Designs/Swift/Navigation/Navigation.cshtml" System.ArgumentException: Customized cultures cannot be passed by LCID, only by name. (Parameter 'culture') at System.Globalization.RegionInfo..ctor(Int32 culture) at CompiledRazorTemplates.Dynamic.RazorEngine_f62da34d10734ccd9c9a72d579ff081e.ExecuteAsync() at RazorEngine.Templating.TemplateBase.Run(ExecuteContext context, TextWriter reader) at RazorEngine.Templating.RazorEngineCore.RunTemplate(ICompiledTemplate template, TextWriter writer, Object model, DynamicViewBag viewBag) at RazorEngine.Templating.RazorEngineService.Run(ITemplateKey key, TextWriter writer, Type modelType, Object model, DynamicViewBag viewBag) at RazorEngine.Templating.DynamicWrapperService.Run(ITemplateKey key, TextWriter writer, Type modelType, Object model, DynamicViewBag viewBag) at RazorEngine.Templating.RazorEngineServiceExtensions.Run(IRazorEngineService service, String name, TextWriter writer, Type modelType, Object model, DynamicViewBag viewBag) at RazorEngine.Templating.RazorEngineServiceExtensions.<>c__DisplayClass23_0.<Run>b__0(TextWriter writer) at RazorEngine.Templating.RazorEngineServiceExtensions.WithWriter(Action`1 withWriter) at RazorEngine.Templating.RazorEngineServiceExtensions.Run(IRazorEngineService service, String name, Type modelType, Object model, DynamicViewBag viewBag) at Dynamicweb.Rendering.RazorTemplateRenderingProvider.Render(Template template) in /_/src/Application/Providers/Dynamicweb.Rendering.Providers.NetCore/Razor/RazorTemplateRenderingProvider.cs:line 99 at Dynamicweb.Rendering.TemplateRenderingService.Render(Template template) in E:\A10\_w\2\s\src\Core\Dynamicweb.Core\Rendering\TemplateRenderingService.cs:line 21 at Dynamicweb.Rendering.Template.RenderRazorTemplate() in E:\A10\_w\2\s\src\Core\Dynamicweb.Core\Rendering\Template.cs:line 749
1 @inherits Dynamicweb.Rendering.ViewModelTemplate<Dynamicweb.Frontend.Navigation.NavigationTreeViewModel> 2 @using Dynamicweb 3 @using Dynamicweb.Ecommerce.Orders 4 @using System.Text.RegularExpressions 5 6 @{ 7 string theme = !string.IsNullOrEmpty(Model.Parameters["Theme"].ToString()) ? Model.Parameters["Theme"].ToString() : string.Empty; 8 string navOrientation = !string.IsNullOrEmpty(Model.Parameters["NavOrientation"].ToString()) ? Model.Parameters["NavOrientation"].ToString() : string.Empty; 9 string navAlignment = !string.IsNullOrEmpty(Model.Parameters["NavAlignment"].ToString()) ? Model.Parameters["NavAlignment"].ToString() : string.Empty; 10 string linkFontWeight = !string.IsNullOrEmpty(Model.Parameters["LinkFontWeight"].ToString()) ? Model.Parameters["LinkFontWeight"].ToString() : string.Empty; 11 string linkCasing = !string.IsNullOrEmpty(Model.Parameters["LinkCasing"].ToString()) ? Model.Parameters["LinkCasing"].ToString() : string.Empty; 12 string linkFontSize = !string.IsNullOrEmpty(Model.Parameters["LinkFontSize"].ToString()) ? Model.Parameters["LinkFontSize"].ToString() : string.Empty; 13 string layout = !string.IsNullOrEmpty(Model.Parameters["Layout"].ToString()) ? Model.Parameters["Layout"].ToString() : string.Empty; 14 string iconSize = linkFontSize == "fs-7" ? "icon-2" : "icon-3"; 15 iconSize = linkFontSize == "fs-5" ? "icon-4" : iconSize; 16 17 int currentParagraphId = Pageview.CurrentParagraph.ID; 18 19 bool showOnlyFirstNavLevel = Model.Parameters.ContainsKey("ShowOnlyFirstNavLevel") ? Convert.ToBoolean(Model.Parameters["ShowOnlyFirstNavLevel"].ToString()) : false; 20 string menuId = Model.Parameters.ContainsKey("menu-id") ? $"menu_{Model.Parameters["menu-id"].ToString().ToLower()}" : string.Empty; 21 22 string groupId = Dynamicweb.Context.Current.Request["GroupID"] != null ? Dynamicweb.Context.Current.Request["GroupID"].ToString() : string.Empty; 23 string productId = Dynamicweb.Context.Current.Request["ProductID"] != null ? Dynamicweb.Context.Current.Request["ProductID"].ToString() : string.Empty; 24 string variantId = Dynamicweb.Context.Current.Request["VariantID"] != null ? Dynamicweb.Context.Current.Request["VariantID"].ToString() : string.Empty; 25 26 string navItemVisuallyHidden = layout == "iconsOnly" ? "visually-hidden" : null; 27 } 28 29 <nav class="d-flex py-0 @navOrientation @navAlignment"> 30 <ul class="nav flex-nowrap @(navOrientation == "vertical" ? "flex-column" : navOrientation)"> 31 @foreach (var node in Model.Nodes) 32 { 33 var page = Dynamicweb.Content.Services.Pages.GetPage(node.PageId); 34 var pageType = !string.IsNullOrEmpty(page.ItemType) ? page.ItemType : "Swift_Page"; 35 string pageIcon = string.Empty; 36 if (page.PropertyItem is object && page.PropertyItem.TryGetValue("Icon", out object pageIconValue)) 37 { 38 pageIcon = Dynamicweb.Core.Converter.ToString(pageIconValue); 39 } 40 string iconPath = Dynamicweb.Context.Current.Server.MapPath(pageIcon); 41 42 string preferencesLayout = page.Item?["PreferencesLayout"] != null ? page.Item["PreferencesLayout"].ToString() : string.Empty; 43 string preferencesType = "language"; 44 45 bool countrySelector = page.Item?["CountrySelector"] != null ? Convert.ToBoolean(page.Item["CountrySelector"].ToString()) : false; 46 bool languageSelector = page.Item?["LanguageSelector"] != null ? Convert.ToBoolean(page.Item["LanguageSelector"].ToString()) : false; 47 bool currencySelector = page.Item?["CurrencySelector"] != null ? Convert.ToBoolean(page.Item["CurrencySelector"].ToString()) : false; 48 49 var hasChildren = node.Nodes.Count() > 0 || pageType == "Swift_SignIn"; 50 string nodeId = !string.IsNullOrEmpty(node.GroupId) ? "Navigation_" + node.GroupId + "_" + currentParagraphId : "Navigation_Page_Desktop_" + node.PageId.ToString() + "_" + currentParagraphId; 51 52 string dropdownAttributes = hasChildren && !showOnlyFirstNavLevel ? " role=\"button\" aria-haspopup=\"true\" aria-expanded=\"false\" data-bs-toggle=\"dropdown\" data-bs-offset=\"0,0\"" : string.Empty; 53 string dropdownClasses = string.Empty; 54 55 if (pageType != "Swift_Preferences") 56 { 57 <li class="nav-item@(hasChildren ? " dropdown" : string.Empty)"> 58 @if (node.IsClickable) 59 { 60 @:<a href="@node.Link" class="p-2 nav-link text-nowrap text-decoration-underline-hover @linkFontSize @linkFontWeight @linkCasing@(node.IsActive ? " active" : "")@(hasChildren ? " dropdown-toggle" : string.Empty)" @dropdownAttributes @(node.IsActive ? " aria-current='page'" : "") id="@nodeId"> 61 } 62 else 63 { 64 @:<span class="p-2 nav-link text-nowrap @linkFontSize @linkFontWeight @linkCasing@(hasChildren ? " dropdown-toggle " : string.Empty)" @dropdownAttributes id="@nodeId"> 65 } 66 67 @if (pageType == "Swift_Cart") //Mini cart 68 { 69 string cartId = page.Item["ContextCart"] != null && page.Item["ContextCart"] != string.Empty ? $"ID=\"Cart_{page.Item["ContextCart"].ToString()}\"" : string.Empty; 70 string jsCartClass = string.IsNullOrEmpty(cartId) ? "js-cart-qty" : string.Empty; 71 double totalProducts = 0; 72 73 Dynamicweb.Ecommerce.Common.Context.CartContext = null; 74 if (page.Item["ContextCart"] != null) 75 { 76 var orderContext = Dynamicweb.Ecommerce.Services.OrderContexts.GetOrderContextById(page.Item["ContextCart"].ToString()); 77 Dynamicweb.Ecommerce.Common.Context.CartContext = orderContext; 78 } 79 80 if (Dynamicweb.Ecommerce.Common.Context.Cart != null) 81 { 82 bool renderOrderlineCountInsteadOfProductCount = page.Item["RenderOrderlineCountInsteadOfProductCount"] != null ? Convert.ToBoolean(page.Item["RenderOrderlineCountInsteadOfProductCount"]) : false; 83 if (!renderOrderlineCountInsteadOfProductCount) 84 { 85 totalProducts = Dynamicweb.Ecommerce.Common.Context.Cart.GetParentProductLineQuantityCount(Dynamicweb.Ecommerce.Common.Context.Cart.OrderLines); 86 } 87 else 88 { 89 foreach (var orderline in Dynamicweb.Ecommerce.Common.Context.Cart.OrderLines) 90 { 91 if (orderline.HasType(new[] { OrderLineType.Product, OrderLineType.Fixed, OrderLineType.PointProduct, OrderLineType.GiftCard })) 92 { 93 totalProducts++; 94 } 95 } 96 97 totalProducts = Math.Round(totalProducts, 2); 98 } 99 } 100 101 if (layout == "iconsAndLinks" && pageIcon.EndsWith(".svg", StringComparison.OrdinalIgnoreCase) && !pageIcon.EndsWith("none.svg", StringComparison.OrdinalIgnoreCase)) 102 { 103 <span class="@iconSize pe-none">@ReadFile(iconPath)</span> 104 } 105 106 <span class="@(navItemVisuallyHidden)">@node.Name</span> 107 <span class="@jsCartClass mini-cart-quantity pe-none" @cartId data-order-context="@page.Item["ContextCart"]">@totalProducts</span> 108 109 if (layout != "linksOnly" && layout != "iconsAndLinks" && pageIcon.EndsWith(".svg", StringComparison.OrdinalIgnoreCase) && !pageIcon.EndsWith("none.svg", StringComparison.OrdinalIgnoreCase)) 110 { 111 <span class="@iconSize pe-none">@ReadFile(iconPath)</span> 112 } 113 } 114 else 115 { 116 if (layout == "iconsAndLinks" && pageIcon.EndsWith(".svg", StringComparison.OrdinalIgnoreCase) && !pageIcon.EndsWith("none.svg", StringComparison.OrdinalIgnoreCase)) 117 { 118 <span class="@iconSize pe-none">@ReadFile(iconPath)</span> 119 } 120 121 <span class="@(navItemVisuallyHidden)">@node.Name</span> 122 123 if (layout != "linksOnly" && layout != "iconsAndLinks" && pageIcon.EndsWith(".svg", StringComparison.OrdinalIgnoreCase) && !pageIcon.EndsWith("none.svg", StringComparison.OrdinalIgnoreCase)) 124 { 125 <span class="@iconSize pe-none">@ReadFile(iconPath)</span> 126 } 127 } 128 129 @if (node.IsClickable) 130 { 131 @:</a> 132 } 133 else 134 { 135 @:</span> 136 } 137 138 @if (hasChildren && !showOnlyFirstNavLevel) 139 { 140 <ul class="dropdown-menu @(theme)" aria-labelledby="@nodeId"> 141 @foreach (var subnode in node.Nodes)//Standard pages 142 { 143 nodeId = !string.IsNullOrEmpty(subnode.GroupId) ? "Navigation_" + subnode.GroupId + "_" + currentParagraphId : "Navigation_Page_" + subnode.PageId.ToString() + "_" + currentParagraphId; 144 145 <li> 146 @if (subnode.IsClickable) 147 { 148 <a href="@subnode.Link" class="dropdown-item py-2 text-decoration-underline-hover @linkFontSize @linkFontWeight @linkCasing" @(subnode.IsActive ? " aria-current='page'" : string.Empty) id="@nodeId">@subnode.Name</a> 149 } 150 else 151 { 152 <span class="dropdown-item py-2 @linkFontSize @linkFontWeight @linkCasing" @(subnode.IsActive ? " aria-current='page'" : string.Empty) id="@nodeId">@subnode.Name</span> 153 } 154 </li> 155 } 156 @if (pageType == "Swift_SignIn") //Sign out link 157 { 158 if (Pageview.User != null) 159 { 160 string signOutLink = "/Admin/Public/ExtranetLogoff.aspx?redirect=no"; 161 162 <li><hr class="dropdown-divider"></li> 163 if (Dynamicweb.Security.UserManagement.User.GetCurrentSecondaryUser() != null) 164 { 165 string customerSignOutLink = $"Default.aspx?ID={Pageview.ID}&DwExtranetRemoveSecondaryUser=1"; 166 167 <li> 168 <a href="@customerSignOutLink" class="dropdown-item py-2 text-decoration-underline-hover swift_sign-out-as-customer-link @linkFontSize @linkFontWeight @linkCasing" id="SignInButton_@currentParagraphId">@Translate("Sign out as a customer")</a> 169 </li> 170 } 171 <li> 172 <a href="@signOutLink" class="dropdown-item py-2 text-decoration-underline-hover swift_sign-out-link @linkFontSize @linkFontWeight @linkCasing">@Translate("Sign out")</a> 173 </li> 174 } 175 } 176 </ul> 177 } 178 </li> 179 } 180 else 181 { 182 string name = node.Name; 183 184 if (preferencesLayout == "modal") 185 { 186 if (languageSelector) { 187 string iconFolder = "/Files/FlagIcons/"; 188 var region = new System.Globalization.RegionInfo(Pageview.Area.CultureInfo.LCID); 189 bool hideIcon = page.Item?["HideIcon"] != null ? Convert.ToBoolean(page.Item["HideIcon"].ToString()) : false; 190 iconPath = !hideIcon ? $"{iconFolder}{region.Name}.svg" : string.Empty; 191 192 bool hideName = page.Item?["HideName"] != null ? Convert.ToBoolean(page.Item["HideName"].ToString()) : false; 193 name = !hideName ? region.DisplayName : string.Empty; 194 } 195 196 <li class="nav-item@(hasChildren ? " dropdown" : string.Empty)"> 197 <form action="/Default.aspx?ID=@node.PageId" data-response-target-element="PreferencesModalContent" data-layout-template="Swift_Preferences.cshtml" data-preloader="inline"> 198 <input type="hidden" name="CurrentPageID" value="@Pageview.ID"> 199 <input type="hidden" name="GroupID" value="@groupId"> 200 <input type="hidden" name="ProductID" value="@productId"> 201 <input type="hidden" name="VariantID" value="@variantId"> 202 <button type="button" onmouseover="swift.PageUpdater.Update(event)" onclick="swift.PageUpdater.Update(event)" class="btn border-0 nav-link p-2 text-nowrap border-0 swift_open-preferences-modal @linkFontSize @linkFontWeight @linkCasing" data-bs-toggle="modal" data-bs-target="#PreferencesModal" id="OpenPreferences_@currentParagraphId"> 203 @if (layout == "iconsAndLinks" && iconPath.EndsWith(".svg", StringComparison.OrdinalIgnoreCase) && !iconPath.EndsWith("none.svg", StringComparison.OrdinalIgnoreCase)) 204 { 205 <span class="@iconSize">@ReadFile(iconPath)</span> 206 } 207 208 <span class="@(navItemVisuallyHidden)">@name</span> 209 210 @if (layout != "linksOnly" && layout != "iconsAndLinks" && iconPath.EndsWith(".svg", StringComparison.OrdinalIgnoreCase) && !iconPath.EndsWith("none.svg", StringComparison.OrdinalIgnoreCase)) 211 { 212 <span class="@iconSize">@ReadFile(iconPath)</span> 213 } 214 </button> 215 </form> 216 </li> 217 } 218 else 219 { 220 var ecomCountries = Dynamicweb.Ecommerce.Services.Countries.GetCountries(); 221 var currencies = Dynamicweb.Ecommerce.Services.Currencies.GetAllCurrencies(); 222 List<Dynamicweb.Content.Page> languages = new List<Dynamicweb.Content.Page>(); 223 224 if (languageSelector) 225 { 226 if (Pageview.Page.Area.IsMaster) 227 { 228 languages.Add(Pageview.Page); 229 if (Pageview.Page.Languages != null) 230 { 231 foreach (var language in Pageview.Page.Languages) 232 { 233 if (language.Area.Active == true) 234 { 235 languages.Add(language); 236 } 237 } 238 } 239 } 240 else 241 { 242 languages.Add(Pageview.Page.MasterPage); 243 if (Pageview.Page.MasterPage != null) 244 { 245 if (Pageview.Page.MasterPage.Languages != null) 246 { 247 foreach (var language in Pageview.Page.MasterPage.Languages) 248 { 249 if (language.Area.Active == true) 250 { 251 languages.Add(language); 252 } 253 } 254 } 255 } 256 } 257 } 258 259 if (languageSelector && languages.Count > 1) 260 { 261 string iconFolder = "/Files/FlagIcons/"; 262 bool hideIcon = page.Item?["HideIcon"] != null ? Convert.ToBoolean(page.Item["HideIcon"].ToString()) : false; 263 pageIcon = !hideIcon ? iconFolder + Pageview.Area.CultureInfo.Name.ToLower() + ".svg" : string.Empty; 264 265 Regex reg = new Regex(@"\(([^\)]+)\)"); 266 267 bool hideName = page.Item?["HideName"] != null ? Convert.ToBoolean(page.Item["HideName"].ToString()) : false; 268 name = !hideName ? reg.Replace(Pageview.Area.CultureInfo.DisplayName, "") : string.Empty; 269 270 string linkElementId = $"{preferencesType}Selector_{Pageview.CurrentParagraph.ID}_{node.PageId}"; 271 272 <li class="nav-item dropdown"> 273 <form class="d-none d-lg-block" action="/Default.aspx?ID=@node.PageId" data-response-target-element="@(preferencesType)Dropdown_@currentParagraphId" data-layout-template="Swift_Preferences.cshtml" data-preloader="inline"> 274 <input type="hidden" name="Type" value="@preferencesType"> 275 <input type="hidden" name="CurrentPageID" value="@Pageview.ID"> 276 <input type="hidden" name="GroupID" value="@groupId"> 277 <input type="hidden" name="ProductID" value="@productId"> 278 <input type="hidden" name="VariantID" value="@variantId"> 279 <input type="hidden" name="FontSize" value="@linkFontSize"> 280 <input type="hidden" name="FontWeight" value="@linkFontWeight"> 281 <input type="hidden" name="Casing" value="@linkCasing"> 282 283 <button type="button" id="@linkElementId" onmouseover="if (document.querySelector('#@(preferencesType)Dropdown_@(currentParagraphId)').innerHTML === '') { swift.PageUpdater.Update(event); }" onclick="swift.PageUpdater.Update(event)" class="btn border-0 nav-link p-2 text-nowrap text-decoration-underline-hover @linkFontSize @linkFontWeight @linkCasing@(node.IsActive ? " active" : string.Empty) dropdown-toggle" role="button" data-bs-toggle="dropdown" aria-haspopup="true" aria-expanded="false" @(node.IsActive ? " aria-current='page'" : string.Empty)> 284 @if (layout == "iconsAndLinks" && pageIcon.EndsWith(".svg", StringComparison.OrdinalIgnoreCase) && !pageIcon.EndsWith("none.svg", StringComparison.OrdinalIgnoreCase)) 285 { 286 <span class="@iconSize">@ReadFile(pageIcon)</span> 287 } 288 289 <span class="@(navItemVisuallyHidden)">@name</span> 290 291 @if (layout != "linksOnly" && layout != "iconsAndLinks" && pageIcon.EndsWith(".svg", StringComparison.OrdinalIgnoreCase) && !pageIcon.EndsWith("none.svg", StringComparison.OrdinalIgnoreCase)) 292 { 293 <span class="@iconSize">@ReadFile(pageIcon)</span> 294 } 295 </button> 296 297 <ul class="dropdown-menu @(theme)" id="@(preferencesType)Dropdown_@currentParagraphId"></ul> 298 </form> 299 300 <form class="d-block d-lg-none" action="/Default.aspx?ID=@node.PageId" data-response-target-element="PreferencesModalContent" data-layout-template="Swift_Preferences.cshtml" data-preloader="inline"> 301 <input type="hidden" name="Layout" value="modal"> 302 <input type="hidden" name="CurrentPageID" value="@Pageview.ID"> 303 <input type="hidden" name="GroupID" value="@groupId"> 304 <input type="hidden" name="ProductID" value="@productId"> 305 <input type="hidden" name="VariantID" value="@variantId"> 306 <button type="button" onmouseover="swift.PageUpdater.Update(event)" onclick="swift.PageUpdater.Update(event)" class="btn nav-link p-2 text-nowrap border-0 swift_open-preferences-modal @linkFontSize @linkFontWeight @linkCasing" data-bs-toggle="modal" data-bs-target="#PreferencesModal"> 307 @if (layout == "iconsAndLinks" && pageIcon.EndsWith(".svg", StringComparison.OrdinalIgnoreCase) && !pageIcon.EndsWith("none.svg", StringComparison.OrdinalIgnoreCase)) 308 { 309 <span class="@iconSize">@ReadFile(iconPath)</span> 310 } 311 312 <span class="@(navItemVisuallyHidden)">@name</span> 313 314 @if (layout != "linksOnly" && layout != "iconsAndLinks" && pageIcon.EndsWith(".svg", StringComparison.OrdinalIgnoreCase) && !pageIcon.EndsWith("none.svg", StringComparison.OrdinalIgnoreCase)) 315 { 316 <span class="@iconSize">@ReadFile(iconPath)</span> 317 } 318 </button> 319 </form> 320 </li> 321 } 322 323 if (countrySelector && ecomCountries.Count > 1) 324 { 325 name = Translate("Deliver to") + ": " + Dynamicweb.Ecommerce.Common.Context.Country.GetName(Dynamicweb.Ecommerce.Common.Context.LanguageID); 326 preferencesType = "country"; 327 328 string linkElementId = $"{preferencesType}Selector_{Pageview.CurrentParagraph.ID}_{node.PageId}"; 329 330 <li class="nav-item dropdown"> 331 <form class="d-none d-lg-block" action="/Default.aspx?ID=@node.PageId" data-response-target-element="@(preferencesType)Dropdown_@currentParagraphId" data-layout-template="Swift_Preferences.cshtml" data-preloader="inline"> 332 <input type="hidden" name="Type" value="@preferencesType"> 333 <input type="hidden" name="CurrentPageID" value="@Pageview.ID"> 334 <input type="hidden" name="GroupID" value="@groupId"> 335 <input type="hidden" name="ProductID" value="@productId"> 336 <input type="hidden" name="VariantID" value="@variantId"> 337 <input type="hidden" name="FontSize" value="@linkFontSize"> 338 <input type="hidden" name="FontWeight" value="@linkFontWeight"> 339 <input type="hidden" name="Casing" value="@linkCasing"> 340 341 <a id="@linkElementId" onmouseover="swift.PageUpdater.Update(event)" onclick="swift.PageUpdater.Update(event)" class="nav-link p-2 text-nowrap text-decoration-underline-hover @linkFontSize @linkFontWeight @linkCasing@(node.IsActive ? " active" : string.Empty) dropdown-toggle" href="#" role="button" data-bs-toggle="dropdown" aria-haspopup="true" aria-expanded="false" @(node.IsActive ? " aria-current='page'" : string.Empty)> 342 @if (layout == "iconsAndLinks" && pageIcon.EndsWith(".svg", StringComparison.OrdinalIgnoreCase) && !pageIcon.EndsWith("none.svg", StringComparison.OrdinalIgnoreCase)) 343 { 344 <span class="@iconSize">@ReadFile(iconPath)</span> 345 } 346 347 <span class="@(navItemVisuallyHidden)">@name</span> 348 349 @if (layout != "linksOnly" && layout != "iconsAndLinks" && pageIcon.EndsWith(".svg", StringComparison.OrdinalIgnoreCase) && !pageIcon.EndsWith("none.svg", StringComparison.OrdinalIgnoreCase)) 350 { 351 <span class="@iconSize">@ReadFile(iconPath)</span> 352 } 353 </a> 354 355 <ul class="dropdown-menu @(theme)" id="@(preferencesType)Dropdown_@currentParagraphId"></ul> 356 </form> 357 358 <form class="d-block d-lg-none" action="/Default.aspx?ID=@node.PageId" data-response-target-element="PreferencesModalContent" data-layout-template="Swift_Preferences.cshtml" data-preloader="inline"> 359 <input type="hidden" name="Layout" value="modal"> 360 <input type="hidden" name="CurrentPageID" value="@Pageview.ID"> 361 <input type="hidden" name="GroupID" value="@groupId"> 362 <input type="hidden" name="ProductID" value="@productId"> 363 <input type="hidden" name="VariantID" value="@variantId"> 364 <button type="button" onmouseover="swift.PageUpdater.Update(event)" onclick="swift.PageUpdater.Update(event)" class="btn nav-link p-2 text-nowrap border-0 swift_open-preferences-modal @linkFontSize @linkFontWeight @linkCasing" data-bs-toggle="modal" data-bs-target="#PreferencesModal"> 365 @if (layout == "iconsAndLinks" && pageIcon.EndsWith(".svg", StringComparison.OrdinalIgnoreCase) && !pageIcon.EndsWith("none.svg", StringComparison.OrdinalIgnoreCase)) 366 { 367 <span class="@iconSize">@ReadFile(iconPath)</span> 368 } 369 370 <span>@name</span> 371 372 @if (layout != "linksOnly" && layout != "iconsAndLinks" && pageIcon.EndsWith(".svg", StringComparison.OrdinalIgnoreCase) && !pageIcon.EndsWith("none.svg", StringComparison.OrdinalIgnoreCase)) 373 { 374 <span class="@iconSize">@ReadFile(iconPath)</span> 375 } 376 </button> 377 </form> 378 </li> 379 } 380 381 if (currencySelector && currencies.Count() > 1) 382 { 383 name = Dynamicweb.Ecommerce.Common.Context.Currency.Code; 384 preferencesType = "currency"; 385 386 string linkElementId = $"{preferencesType}Selector_{Pageview.CurrentParagraph.ID}_{node.PageId}"; 387 388 <li class="nav-item dropdown"> 389 <form class="d-none d-lg-block" action="/Default.aspx?ID=@node.PageId" data-response-target-element="@(preferencesType)Dropdown_@currentParagraphId" data-layout-template="Swift_Preferences.cshtml" data-preloader="inline"> 390 <input type="hidden" name="Type" value="@preferencesType"> 391 <input type="hidden" name="CurrentPageID" value="@Pageview.ID"> 392 <input type="hidden" name="GroupID" value="@groupId"> 393 <input type="hidden" name="ProductID" value="@productId"> 394 <input type="hidden" name="VariantID" value="@variantId"> 395 <input type="hidden" name="FontSize" value="@linkFontSize"> 396 <input type="hidden" name="FontWeight" value="@linkFontWeight"> 397 <input type="hidden" name="Casing" value="@linkCasing"> 398 399 <a id="@linkElementId" onmouseover="swift.PageUpdater.Update(event)" onclick="swift.PageUpdater.Update(event)" class="nav-link p-2 text-nowrap text-decoration-underline-hover @linkFontSize @linkFontWeight @linkCasing@(node.IsActive ? " active" : string.Empty) dropdown-toggle" href="#" role="button" data-bs-toggle="dropdown" aria-haspopup="true" aria-expanded="false" @(node.IsActive ? " aria-current='page'" : string.Empty)> 400 @if (layout == "iconsAndLinks" && pageIcon.EndsWith(".svg", StringComparison.OrdinalIgnoreCase) && !pageIcon.EndsWith("none.svg", StringComparison.OrdinalIgnoreCase)) 401 { 402 <span class="@iconSize">@ReadFile(iconPath)</span> 403 } 404 405 <span class="@(navItemVisuallyHidden)">@name</span> 406 407 @if (layout != "linksOnly" && layout != "iconsAndLinks" && pageIcon.EndsWith(".svg", StringComparison.OrdinalIgnoreCase) && !pageIcon.EndsWith("none.svg", StringComparison.OrdinalIgnoreCase)) 408 { 409 <span class="@iconSize">@ReadFile(iconPath)</span> 410 } 411 </a> 412 413 <ul class="dropdown-menu @(theme)" id="@(preferencesType)Dropdown_@currentParagraphId"></ul> 414 </form> 415 416 <form class="d-block d-lg-none" action="/Default.aspx?ID=@node.PageId" data-response-target-element="PreferencesModalContent" data-layout-template="Swift_Preferences.cshtml" data-preloader="inline"> 417 <input type="hidden" name="Layout" value="modal"> 418 <input type="hidden" name="CurrentPageID" value="@Pageview.ID"> 419 <input type="hidden" name="GroupID" value="@groupId"> 420 <input type="hidden" name="ProductID" value="@productId"> 421 <input type="hidden" name="VariantID" value="@variantId"> 422 <button type="button" onmouseover="swift.PageUpdater.Update(event)" onclick="swift.PageUpdater.Update(event)" class="btn nav-link p-2 text-nowrap border-0 swift_open-preferences-modal @linkFontSize @linkFontWeight @linkCasing" data-bs-toggle="modal" data-bs-target="#PreferencesModal"> 423 @if (layout == "iconsAndLinks" && pageIcon.EndsWith(".svg", StringComparison.OrdinalIgnoreCase) && !pageIcon.EndsWith("none.svg", StringComparison.OrdinalIgnoreCase)) 424 { 425 <span class="@iconSize">@ReadFile(iconPath)</span> 426 } 427 428 <span>@name</span> 429 430 @if (layout != "linksOnly" && layout != "iconsAndLinks" && pageIcon.EndsWith(".svg", StringComparison.OrdinalIgnoreCase) && !pageIcon.EndsWith("none.svg", StringComparison.OrdinalIgnoreCase)) 431 { 432 <span class="@iconSize">@ReadFile(iconPath)</span> 433 } 434 </button> 435 </form> 436 </li> 437 } 438 } 439 } 440 } 441 </ul> 442 </nav> 443
We and our partners use technologies, including cookies, to collect information about you for various purposes, including:
By clicking 'Accept All' you consent to all these purposes. You can also choose to indicate what purposes you will consent to using the custom selections and then click 'Accept selected'.