Error compiling template "Designs/Basic/_parsed/PageEcomCustomerCenter.parsed.cshtml"
Line 6855: The name 'RenderBreadcrumbs' does not exist in the current context

1 @using System; 2 @using System.Web; 3 @using Dynamicweb; 4 @using Dynamicweb.Core; 5 @inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> 6 @using Dynamicweb; 7 @using Dynamicweb.Core; 8 9 @inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> 10 11 @helper RenderCartMiniIcon(string mode) 12 { 13 var enableCart = Converter.ToBoolean(Pageview.Area.Item["EnableCart"]); 14 if (enableCart) 15 { 16 <div class="cart-mini js-cartmini-icon-container"> 17 @if (mode == "link") 18 { 19 var cartLink = Converter.ToString(Pageview.Area.Item["CartLink"]); 20 21 <a href="@cartLink" class="cart-mini-link"> 22 23 <div class="cart-mini-icon js-cartmini-icon"> 24 <span class="mini-cart-label hidden-xs-down">@Translate("Co3:Header.QuoteList", "Quote List")</span> 25 <span class="cart-quantity js-cartmini-total-icon-count"><span class="qty-inner">(@GetInteger("Ecom:Order.OrderLines.TotalProductQuantity"))</span></span> 26 </div> 27 @*<div class="cart-mini-total"> 28 <span class="js-cartmini-icon-total">@GetValue("Ecom:Order.Price.PriceFormatted")</span> 29 </div>*@ 30 </a> 31 <input type="hidden" class="js-cartmini-total-count" value='@GetInteger("Ecom:Order.OrderLines.TotalProductQuantity")'> 32 <input type="hidden" class="js-cartmini-total-total" value='@GetValue("Ecom:Order.Price.PriceFormatted")'> 33 } 34 else 35 { 36 <div class="cart-mini-icon js-cartmini-icon js-toggle" data-target=".js-cartmini"> 37 <i class="fa fa-shopping-cart" aria-hidden="true"></i> 38 <span class="cart-quantity js-cartmini-total-icon-count">@GetInteger("Ecom:Order.OrderLines.TotalProductQuantity")</span> 39 </div> 40 <div class="cart-mini-total"> 41 <span class="js-cartmini-icon-total">@GetValue("Ecom:Order.Price.PriceFormatted")</span> 42 </div> 43 <input type="hidden" class="js-cartmini-total-count" value='@GetInteger("Ecom:Order.OrderLines.TotalProductQuantity")'> 44 <input type="hidden" class="js-cartmini-total-total" value='@GetValue("Ecom:Order.Price.PriceFormatted")'> 45 } 46 <span class="tooltiptext add-to-list-tooltip js-add-to-list-tooltip"> 47 <strong>@Translate("AddedToListTooltip", "Added")</strong> 48 </span> 49 </div> 50 } 51 } 52 53 @helper RenderCartMini(string StockCheckMode = "ignore") 54 { 55 var enableCart = Converter.ToBoolean(Pageview.Area.Item["EnableCart"]); 56 if (enableCart) 57 { 58 59 //website settings 60 var cartLink = Dynamicweb.Core.Converter.ToString(Pageview.Area.Item["CartLink"]); 61 int maxOrderlinesShown = Dynamicweb.Core.Converter.ToInt32(Pageview.Area.Item["CartMaxOrderlines"]); 62 63 var orderLines = GetLoop("OrderLines"); 64 65 <div class="cartmini js-cartmini"> 66 <div class="cartmini-container js-cartmini-container"> 67 <div class="row"> 68 <div class="col-xs-24"> 69 <a href="@cartLink" class="btn btn-block btn-primary" alt='@Translate("Smartpage:CartMini.Orderline.Button.ToCheckout", "Til kassen")'>@Translate("Smartpage:CartMini.Orderline.Button.ToCheckout", "Til kassen")</a> 70 </div> 71 </div> 72 @if (orderLines.Any()) 73 { 74 int numRows = 0; 75 76 <ul class="cartmini-orderlines list-unstyled"> 77 @foreach (LoopItem i in orderLines.Where(x => x.GetInteger("Ecom:Order:OrderLine.Type") == 0).OrderByDescending(x => x.GetDate("Ecom:Order:OrderLine.Modified"))) 78 { 79 @*todo: Please clean up! *@ 80 81 numRows++; 82 string hiddenClass = (numRows > maxOrderlinesShown) ? "hidden-xs-up" : ""; 83 string productId = ""; 84 double quantity = 0; 85 double stock = 0; 86 //if (!string.IsNullOrWhiteSpace(StockCheckMode) && StockCheckMode != "ignore") 87 string productName = i.GetString("Ecom:Product.Name"); 88 string image1 = i.GetString("Ecom:Product.Image.1.Clean"); 89 string defaultImage = i.GetString("Ecom:Product.ImageLarge.Default.Clean"); 90 91 productId = @i.GetString("Ecom:Order:OrderLine.ProductID"); 92 quantity = @i.GetDouble("Ecom:Order:OrderLine.Quantity"); 93 stock = @i.GetDouble("Ecom:Product.AvailableAmount"); 94 95 <li class="cartmini-orderline js-orderline @hiddenClass" data-productid="@productId" data-quantity="@quantity" data-stock="@stock"> 96 @*<div class="col-xs-6 col-sm-6"> 97 @if (!String.IsNullOrEmpty(i.GetString("Ecom:Product.Image.1.Clean"))) 98 { 99 <img class="img-fluid" alt="@productName" src="@image1" title="@productName"> 100 } 101 else 102 { 103 <img class="img-fluid" alt="@productName" src="@defaultImage" title="@productName"> 104 } 105 </div>*@ 106 <div class=""> 107 <a href='/Default.aspx?ID=@Pageview.Area.Item["CartShopLink"]&ProductId=@i.GetValue("Ecom:Order:OrderLine.ProductID")'> 108 @i.GetValue("Ecom:Order:OrderLine.ProductName") 109 </a> 110 </div> 111 <span class="text-xs-left">@quantity @Translate("Smartpage:CarMini.OrderLine.Pieces", "stk")</span> 112 <span class="text-xs-right cartmini-orderline-price"> 113 @i.GetValue("Ecom:Order:OrderLine.UnitPrice") 114 @if (i.GetBoolean("Ecom:Order:OrderLine.IsProduct")) 115 { 116 string deleteLink = i.GetString("Ecom:Order:OrderLine.DeleteLink"); 117 <span><a href="@deleteLink" title='@Translate("Smartpage:CartMini.Orderline.LinkTitle.Remove", "Fjern")'>@Translate("Smartpage:Cart.CartMini.Orderline.LinkText.Remove", "x")</a></span> 118 } 119 </span> 120 </li> 121 if (numRows == maxOrderlinesShown) 122 { 123 <li> 124 <div class="text-xs-center minicart-showall"> 125 <a href="@cartLink">@Translate("Smartpage:CartMini.Orderline.ShowMore", "Vis alle produkter")</a> 126 </div> 127 </li> 128 } 129 } 130 </ul> 131 <div class="row cartmini-row-total"> 132 <div class="col-xs-12">@Translate("Smartpage:CartMini.Orderline.Total", "Total"):</div> 133 <div class="col-xs-12 text-xs-right">@GetValue("Ecom:Order.Price.PriceFormatted")</div> 134 </div> 135 136 <div class="row"> 137 <div class="col-xs-24"> 138 <a href="@cartLink" class="btn btn-block btn-primary" alt='@Translate("Smartpage:CartMini.Orderline.Button.ToCheckout", "Til kassen")'>@Translate("Smartpage:CartMini.Orderline.Button.ToCheckout", "Til kassen")</a> 139 </div> 140 </div> 141 @* hidden inputs for easy access ajax total prices *@ 142 <input type="hidden" class="js-cartmini-total-count" value='@GetInteger("Ecom:Order.OrderLines.TotalProductQuantity")'> 143 <input type="hidden" class="js-cartmini-total-total" value='@GetValue("Ecom:Order.Price.PriceFormatted")'> 144 } 145 else 146 { 147 <div class="row"> 148 <div class="col-xs-24"> 149 <i class="fa fa-cart-plus"></i> @Translate("Smartpage:CartMini.CartEmpty", "Kurven er tom") 150 </div> 151 </div> 152 } 153 </div> 154 155 156 </div> 157 } 158 } 159 160 @using Dynamicweb; 161 162 @inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> 163 164 @helper RenderNavigationMega() 165 { 166 <div class="yamm navbar"> 167 <ul id="navigationDefault" class="nav navbar-nav"> 168 @GetValue("DwNavigation(dwnav)") 169 <li class="nav-item"> 170 <span class="header-icon-search js-search-form-icon nav-item-link"> 171 <img src="/Files/Templates/Designs/Basic/Assets/Images/search.svg" alt="search"><span class="hidden-md-down">Search</span> 172 </span> 173 174 175 </li> 176 </ul> 177 178 </div> 179 180 <div class="js-search-form"> 181 @RenderProductSearchForm() 182 </div> 183 } 184 185 @using Dynamicweb; 186 @inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> 187 @helper RenderNavigationSlideRight() 188 { 189 string backText = Translate("Smartpage:Navigation.Mobile.Back", "Tilbage"); 190 <nav class="nav js-nav-list"> 191 @RenderNavigation(new { template = "NavigationSlideRight.xslt", expandmode = "all", translateBack = backText , startlevel = 1, endlevel = 3}) 192 @*@GetValue("DwNavigation(navigationslideright)")*@ 193 </nav> 194 } 195 196 @using Dynamicweb; 197 198 @inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> 199 200 @helper RenderNavigationFooter() 201 { 202 @GetValue("DwNavigation(navigationfooter)") 203 } 204 @using Dynamicweb; 205 @inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> 206 @helper RenderSocialMediaList(string position) 207 { 208 if (Dynamicweb.Core.Converter.ToBoolean(Pageview.Area.Item["SocialMediaActive"])) 209 { 210 <div class="social-media-List"> 211 @{ 212 var socialMediaLoop = GetLoop("Item.Area.SocialMediaList"); 213 if (socialMediaLoop.Any()) 214 { 215 <ul class="list-unstyled list-inline"> 216 @foreach (var i in socialMediaLoop) 217 { 218 string footerLoopMobileView = i.GetBoolean("Item.Area.SocialMediaList.ShowOnMobile") ? "" : "hidden-xs-down"; 219 string externalLink = i.GetBoolean("Item.Area.SocialMediaList.OpenLinkHere") ? "_self" : "_blank"; 220 string image = i.GetString("Item.Area.SocialMediaList.IconImg"); 221 var metaData = Dynamicweb.Content.Files.Metadata.EditorFactory.GetMetadataForFile(image); 222 223 //show in different positions 224 bool displayHeader = position == "header" && i.GetBoolean("Item.Area.SocialMediaList.ShowInHeader"); 225 bool displayFooter = position == "footer" && i.GetBoolean("Item.Area.SocialMediaList.ShowInFooter"); 226 227 if (displayHeader || displayFooter) 228 { 229 var someLink = i.GetValue("Item.Area.SocialMediaList.Link"); 230 <li class='list-inline-item @footerLoopMobileView @i.GetValue("Item.Area.SocialMediaList.Class")'> 231 <a href="@someLink" title='@i.GetValue("Item.Area.SocialMediaList.Text")' target="@externalLink" rel="noopener noreferrer"> 232 <span class='@i.GetValue("Item.Area.SocialMediaList.Icon")'></span>@i.GetValue("Item.Area.SocialMediaList.Text") 233 @if (!String.IsNullOrEmpty(image)) 234 { 235 <img src="@image" alt='@i.GetValue("Item.Area.SocialMediaList.Text")'> 236 } 237 </a> 238 </li> 239 } 240 } 241 </ul> 242 } 243 } 244 </div> 245 } 246 } 247 @using Dynamicweb; 248 @using Dynamicweb.Frontend; 249 @using System.Web 250 @using Dynamicweb.Environment; 251 @inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> 252 @helper RenderUserManagementLoginMini(bool showPoints = false) 253 { 254 bool isLoggedIn = Dynamicweb.Security.UserManagement.User.IsExtranetUserLoggedIn(); 255 256 if (isLoggedIn) 257 { 258 <span class="btn btn-info" data-toggle="modal" data-target="#UserManagementModal"> 259 @Translate("Smartpage:UserManagement.Login.Headline", "Log ind") 260 </span> 261 } 262 else 263 { 264 265 if (showPoints) 266 { 267 int loyaltyPoints = Dynamicweb.Core.Converter.ToInt32(Pageview.Area.Item["UserPointId"]); 268 <div class="row"> 269 <div class="col-xs-10 col-sm-10 col-md-10"> 270 @RenderParagraphContent(loyaltyPoints) 271 </div> 272 <div class="col-xs-14 col-sm-14 col-md-14"> 273 @GetString("DWExtranetUsername") - <a class="" href='/Admin/Public/ExtranetLogoff.aspx?RedirectUrl=@PageView.Current().SearchFriendlyUrl'>@Translate("Smartpage:UserManagement.LoginModal.LoggedIn.SignOut", "Log ud")</a> 274 </div> 275 </div> 276 } 277 else 278 { 279 @* rewrite this - use custom area to show!*@ 280 <button class="dropdown-button" type="button" id="userDropdown" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"> 281 @GetString("DW_extranet_AccessUserName") 282 </button> 283 <div class="dropdown-menu" aria-labelledby="userDropdown"> 284 <a href="#"> 285 @GetString("DWExtranetUsername") 286 </a> 287 <a class="" href='/Admin/Public/ExtranetLogoff.aspx?RedirectUrl=@PageView.Current().SearchFriendlyUrl'> 288 @Translate("Smartpage:UserManagement.LoginModal.LoggedIn.SignOut", "Log ud") 289 </a> 290 </div> 291 } 292 } 293 } 294 @helper RenderUserManagementDropdownButton() 295 { 296 bool isLoggedIn = Dynamicweb.Security.UserManagement.User.IsExtranetUserLoggedIn(); 297 298 if (isLoggedIn) 299 { 300 <span class="btn js-userdropdown-toggle js-toggle" data-target=".js-userdropdown"> 301 <i class="fa fa-user" aria-hidden="true"></i> 302 <span class="label">@GetString("DW_extranet_AccessUserName")</span> 303 <i class="fa fa-angle-down" aria-hidden="true"></i> 304 </span> 305 } 306 else 307 { 308 <span class="btn js-userdropdown-toggle js-toggle" data-target=".js-userdropdown"> 309 <i class="fa fa-user" aria-hidden="true"></i> 310 <span class="label"> 311 @Translate("Smartpage:UserManagement.Dropdown.Login", "Log ind") 312 </span> 313 <i class="fa fa-angle-down" aria-hidden="true"></i> 314 </span> 315 } 316 } 317 @helper RenderUserManagementDropdown() 318 { 319 bool isLoggedIn = Dynamicweb.Security.UserManagement.User.IsExtranetUserLoggedIn(); 320 321 if (!string.IsNullOrEmpty(GetString("DW_extranet_error_dk")) || Dynamicweb.Context.Current.Request.HasRequest("ForgotPassword")) 322 { 323 @SnippetStart("JavaScript") 324 <script> 325 $(".js-userdropdown").show(); 326 </script> 327 @SnippetEnd("JavaScript") 328 } 329 330 if (isLoggedIn) 331 { 332 333 <div class="user-dropdown js-userdropdown js-userdropdown-container" aria-labelledby="userDropdown"> 334 <div class=""> 335 <strong>@Translate("Smartpage:UserManagement.Dropdown.Hello", "Hej") @GetString("DW_extranet_AccessUserName")</strong> 336 </div> 337 <hr> 338 <ul class="list-unstyled user-list"> 339 @*<li class=""> 340 <a href="#" class=""> 341 @GetString("DWExtranetUsername") 342 </a> 343 </li>*@ 344 @*Extend with customer center*@ 345 @RenderCustomerCenter() 346 @*End customer center*@ 347 <li> 348 <a class="" href='/Admin/Public/ExtranetLogoff.aspx?RedirectUrl=@PageView.Current().SearchFriendlyUrl'> 349 @Translate("Smartpage:UserManagement.LoginModal.LoggedIn.SignOut", "Log ud") 350 </a> 351 </li> 352 </ul> 353 </div> 354 } 355 else 356 { 357 358 <div class="user-dropdown js-userdropdown js-userdropdown-container"> 359 @RenderUserManagementLogin(true) 360 </div> 361 } 362 363 } 364 365 @helper RenderUserManagementLogin(bool noLabel = false, bool forgotPassLink = false) 366 { 367 bool isLoggedIn = Dynamicweb.Security.UserManagement.User.IsExtranetUserLoggedIn(); 368 369 <div class="row usermangement-login text-xs-center"> 370 @if (isLoggedIn) 371 { 372 <div class="col-xs-24 col-sm-24 col-md-24 col-lg-24"> 373 @GetString("DWExtranetUsername") - <a href='/Admin/Public/ExtranetLogoff.aspx?RedirectUrl=@PageView.Current().SearchFriendlyUrl'>@Translate("Smartpage:UserManagement.LoginModal.LoggedIn.SignOut", "Log ud")</a> 374 </div> 375 } 376 else 377 { 378 <div class="col-xs-24 col-sm-24 col-md-24 col-lg-24"> 379 @if (Dynamicweb.Context.Current.Request.HasRequest("ForgotPassword")) 380 { 381 <div class="alert alert-success"> 382 @Translate("SmartPage:UserManagement.ForgotPassword.PasswordSentTo", "Adgangskoden er sendt til e-mailadressen:") 383 @Dynamicweb.Context.Current.Request.GetString("username") 384 </div> 385 } 386 <form method="post" action='@GetValue("DWExtranetAction")' class="js-usermanagement-login row"> 387 <input type="hidden" name="DWExtranetUsernameRemember" value="True"> 388 <input type="hidden" name="Redirect" value='@GetValue("DWExtranetAction")'> 389 390 @if (!string.IsNullOrEmpty(GetString("DW_extranet_error_dk"))) 391 { 392 <div class="row"> 393 <div class="col-xs-24 col-sm-24 col-md-24 col-lg-24"> 394 <div class="alert alert-info"> 395 @*@GetString("DW_extranet_error_dk")*@ 396 @Translate("Smartpage:Customercenter.Login.Error","Wrong username or password") 397 </div> 398 </div> 399 </div> 400 } 401 <div class="col-xs-24 col-sm-24 col-md-24 col-lg-24"> 402 <div class="form-group"> 403 @*<h2>@Translate("Smartpage:UserManagement.Login.Headline", "Log ind")</h2>*@ 404 </div> 405 <div class="form-group"> 406 @*@if (!noLabel) 407 { 408 <label for="login-username"> 409 @Translate("Smartpage:UserManagement.Login.Username", "Brugernavn") 410 </label> 411 }*@ 412 <input type="text" id="login-username" name="username" class="form-control js-req js-usermanagement-username" placeholder='@Translate("Smartpage:User.Login.EnterUsername", "Indtast brugernavn")' autofocus="" required=""> 413 <div class="form-control-feedback alert alert-danger js-invalid-nofill offset-xs-8 offset-sm-12 offset-md-14 display-none"> 414 @Translate("Smartpage:Validation.Error.NeedFill", "Skal udfyldes.") 415 </div> 416 </div> 417 </div> 418 <div class="col-xs-24 col-sm-24 col-md-24 col-lg-24 mb-1"> 419 <div class="form-group"> 420 @*@if (!noLabel) 421 { 422 <label for="login-username"> 423 @Translate("Smartpage:UserManagement.Login.Password", "Adgangskode") 424 </label> 425 }*@ 426 <input type="password" id="login-password" name="password" class="form-control js-req" placeholder='@Translate("Smartpage:UserManagement.Login.EnterPassword", "Indtast adgangskode")' required=""> 427 <div class="form-control-feedback alert alert-danger js-invalid-nofill offset-xs-8 offset-sm-12 offset-md-14 display-none"> 428 @Translate("Smartpage:Validation.Error.NeedFill", "Skal udfyldes.") 429 </div> 430 </div> 431 432 <div class="form-check text-xs-left"> 433 <label class="form-check-label" for="DWExtranetPasswordRemember"> 434 <input type="hidden" name="DWExtranetPasswordRemember"> 435 <input type="checkbox" name="DWExtranetPasswordRemember" id="DWExtranetPasswordRemember"> 436 <span class="control-indicator"></span> 437 <span class="facet-label">@Translate("SmartPage:UserManagement.Login.Password.RememberPasswordCheck", "Husk adgangskode")</span> 438 </label> 439 </div> 440 <div class="form-group"> 441 <button type="submit" class="btn btn-border btn-tag-size js-validate-form">@Translate("Smartpage:UserManagement.Login.Button.Login", "Log ind")</button> 442 </div> 443 </div> 444 <div class="col-xs-24 col-sm-24 col-md-24 col-lg-24"> 445 <div class="row"> 446 <div class="col-xs-24 col-sm-12"> 447 <div class="form-check"> 448 <label class="pl-0 js-usermanagement-lostpw-toggle form-check-label">@Translate("Smartpage:UserManagement.Login.ForgotPassword", "Glemt adgangskode?")</label> 449 </div> 450 </div> 451 <div class="col-xs-24 col-sm-12"> 452 <div class="form-check"> 453 @if (Dynamicweb.Core.Converter.ToString(Pageview.Area.Item["UserManagementCreateProfile"]) != "") 454 { 455 <label class="pl-0"><a href='@Dynamicweb.Core.Converter.ToString(Pageview.Area.Item["UserManagementCreateProfile"])'>@Translate("Smartpage:UserManagement.Login.CreateUser", "Opret kunde")</a></label> 456 } 457 </div> 458 </div> 459 </div> 460 461 462 463 </div> 464 </form> 465 466 467 468 <form class="form-horizontal js-usermanagement-lostpw-container display-none row" method="post"> 469 <input type="hidden" value='@GetValue("DWExtranetAction")'> 470 <input type="hidden" name="ForgotPassword" value="True"> 471 <input type="hidden" name="ForgotPasswordConfirm" value='@Translate("PasswordSent", "The password has been sent to your email.")'> 472 <input type="hidden" name="ForgotPasswordMailTemplate" value="mail/ForgotPasswordMail.cshtml"> @* template *@ 473 <input type="hidden" name="ForgotPasswordMailSubject" value='@Translate("SmartPage:UserManagement.ForgotPassword.MailSubject", "Glemt adgangskode")'> 474 <div class="col-xs-24 col-sm-24 col-md-24 col-lg-24 display-none"> 475 <div class="alert alert-block alert-warning fade in"> 476 <b> 477 @Translate("SmartPage:UserManagement.ForgotPassword.UserNotExists", "E-mailadresse findes ikke. Opret venligst en profil eller kontakt os") 478 </b> 479 </div> 480 </div> 481 482 <div class="col-xs-24 col-sm-24 col-md-24 col-lg-24 text-xs-center"> 483 <div class="form-group"> 484 <strong>@Translate("Smartpage:UserManagement.ForgotPasword.Headline", "Glemt password")</strong> 485 </div> 486 <div class="form-group"> 487 @*@if (!noLabel) 488 { 489 <label class="control-label" for="username">@Translate("SmartPage:UserManagement.ForgotPassword.Email", "Email")</label> 490 }*@ 491 <input type="text" id="login-email" class="form-control js-usermanagementlostpw-email" name="username" placeholder='@Translate("SmartPage:UserManagement.ForgotPassword.Placeholder", "Indtast email")' required=""> 492 493 494 </div> 495 <div class="form-group"> 496 <button class="btn btn-border btn-tag-size mb-1" type="submit">@Translate("SmartPage:UserManagement.ForgotPassword.Sendpassword", "Send adgangskode")</button> 497 </div> 498 <div class="form-group"> 499 <span class="js-usermanagement-toggle fat-link">&laquo; @Translate("Smartpage:UserManagement.Login.Back", "Tilbage")</span> 500 </div> 501 </div> 502 503 </form> 504 505 </div> 506 } 507 </div> 508 } 509 @helper RenderUserManagementLoginModal() 510 { 511 <div class="modal fade" id="UserManagementModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true"> 512 <div class="modal-dialog" role="document"> 513 <div class="modal-content"> 514 <div class="modal-header"> 515 <button type="button" class="close" data-dismiss="modal" aria-label="Close"> 516 <span aria-hidden="true">&times;</span> 517 </button> 518 <h4 class="modal-title" id="LoginModalLabel">@Translate("Smartpage:UserManagement.LoginModal.Title.User", "Bruger")</h4> 519 </div> 520 <div class="modal-body"> 521 @RenderUserManagementLogin() 522 </div> 523 <div class="modal-footer"> 524 <button type="button" class="btn btn-secondary btn-block" data-dismiss="modal">@Translate("Smartpage:UserManagement.LoginModal.Button.Close", "Luk")</button> 525 </div> 526 </div> 527 </div> 528 </div> 529 530 if (!string.IsNullOrEmpty(GetString("DW_extranet_error_dk")) || Dynamicweb.Context.Current.Request.HasRequest("ForgotPassword")) 531 { 532 @SnippetStart("JavaScript") 533 <script> 534 $("#UserManagementModal").modal("show"); 535 </script> 536 @SnippetEnd("JavaScript") 537 } 538 539 } 540 @helper RenderCustomerCenter() 541 { 542 @GetValue("DwNavigation(customercenter)") 543 } 544 545 @using System; 546 @using System.Linq 547 @using System.Web; 548 @using Dynamicweb; 549 @inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> 550 @helper RenderNewsletterPopbox() 551 { 552 string popPosition = Dynamicweb.Core.Converter.ToString(Pageview.Area.Item["NewsletterPopboxPosition"]); 553 554 string popboxImage = Dynamicweb.Core.Converter.ToString(Pageview.Area.Item["PopboxImage"]); 555 string closeImage = Dynamicweb.Core.Converter.ToString(Pageview.Area.Item["PopboxCloseImage"]); 556 string popboxMobileImage = Dynamicweb.Core.Converter.ToString(Pageview.Area.Item["PopboxMobileImage"]); 557 558 bool isActive = Dynamicweb.Core.Converter.ToBoolean(Pageview.Area.Item["NewsletterPopboxActive"]); 559 bool isActiveMobile = Dynamicweb.Core.Converter.ToBoolean(Pageview.Area.Item["ShowPopboxOnMobile"]); 560 561 string mobileCss = "mobile-position"; 562 563 if (isActive) 564 { 565 <div class='newsletter-popbox-wrapper @popPosition'> 566 <input type="checkbox" name="newsletterpopbox-toggle" class='@popPosition @mobileCss' id="newsletterpopbox-toggle"> 567 <label for="newsletterpopbox-toggle" class="@popPosition"> 568 <img class="hidden-xs-down" src="@popboxImage"> 569 <img class="hidden-sm-up" src="@popboxMobileImage"> 570 </label> 571 <div class="newsletter-popbox-message-container @popPosition"> 572 <form method="post" action='@GetValue("DWExtranetAction")'> 573 <input type="hidden" name="UserManagement_Form_EmailAllowed" value="True"> 574 <input type="hidden" name="UserManagement_Form_EmailAllowed_ApplyValue" value="True"> 575 <div class='newsletter-popbox-message @popPosition'> 576 <label for="newsletterpopbox-toggle"> 577 <img class="cursor @popPosition" title='@Translate("Smartpage:NewsletterPopBox.CloseBox", "Close box")' src="@closeImage"> 578 @*<i class="fa fa-times-circle" aria-hidden="true"></i>*@ 579 </label> 580 <div class="form-group"> 581 <input name='@GetValue("UserManagement:User.Name.InputName")' type="text" placeholder='@Translate("Smartpage:NewsletterPopbox.Name", "Dit navn")' class="form-control js-req" required="required"> 582 <div class="form-control-feedback alert alert-info display-none js-invalid-nofill"> 583 @Translate("Smartpage:Validation.Error.NeedFill", "Skal udfyldes.") 584 </div> 585 </div> 586 <div class="form-group text-center"> 587 <input name='@GetValue("UserManagement:User.Email.InputName")' type="email" placeholder='@Translate("Smartpage:NewsletterPopbox.YourEmail", "E-mail adresse")' class="form-control js-req js-email" required="required"> 588 <div class="form-control-feedback alert alert-info display-none js-invalid-nofill"> 589 @Translate("Smartpage:Validation.Error.NeedFill", "Skal udfyldes.") 590 </div> 591 <div class="form-control-feedback alert alert-info display-none js-invalid-email"> 592 @Translate("Smartpage:Validation.Error.NeedEmail", "Skal være en email.") 593 </div> 594 </div> 595 <div class="input-group-btn"> 596 <button class="btn btn-primary js-validate-form" type="submit">@Translate("Smartpage:NewsletterPopBox.SignUp", "Tilmeld")</button> 597 </div> 598 </div> 599 </form> 600 </div> 601 </div> 602 } 603 } 604 @using Dynamicweb; 605 @inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> 606 @helper RenderUSP(string position) 607 { 608 var usps = GetLoop("Item.Area.USP"); 609 if (usps.Any()) 610 { 611 <ul class="list-inline usp-list"> 612 @foreach (var usp in GetLoop("Item.Area.USP")) 613 { 614 string icon = usp.GetString("Item.Area.USP.Icon"); 615 string text = usp.GetString("Item.Area.USP.Text"); 616 string link = usp.GetString("Item.Area.USP.Link"); 617 string hiddenMobile = usp.GetBoolean("Item.Area.USP.HiddenMobile") ? "hidden-mobile" : ""; 618 619 620 //show in different positions 621 bool displayHeader = position == "header" && usp.GetBoolean("Item.Area.USP.ShowTop") ? displayHeader = true : false; 622 bool displayFooter = position == "footer" && usp.GetBoolean("Item.Area.USP.ShowBottom") ? displayFooter = true : false; 623 624 625 if (displayHeader || displayFooter) 626 { 627 <li class="list-inline-item @hiddenMobile"> 628 @if (link.Any()) 629 { 630 <a class="list-inline-item" href="@link"> 631 @if (icon.Any()) 632 { 633 <img src="@icon"> 634 } 635 else 636 { 637 <i class="fa fa-check" aria-hidden="true"></i> 638 } 639 <span class="usp-text">@text</span> 640 </a> 641 } 642 else 643 { 644 <span class="list-inline-item"> 645 @if (icon.Any()) 646 { 647 <img src="@icon"> 648 } 649 else 650 { 651 <i class="fa fa-check" aria-hidden="true"></i> 652 } 653 <span class="usp-text">@text</span> 654 </span> 655 } 656 </li> 657 } 658 659 660 } 661 </ul> 662 } 663 } 664 @inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> 665 @using Dynamicweb; 666 @using Dynamicweb.Environment; 667 668 @helper RenderStandardInstantProductSearchTemplates() 669 { 670 //var searchPageUrl = String.Format("/Default.aspx?id={0}", Dynamicweb.Core.Converter.ToString(Pageview.Area.Item["SearchPage"])) + "&q="; 671 var searchPageUrl = String.Format("/Default.aspx?id={0}", Pageview.Page.ID.ToString()) + "&q="; 672 <script id="product-instant-search-header-template" type="text/x-handlebars-template"> 673 <header class="typeahead-header">@Translate("Smartpage:Search.Header.Label", "Søgeresultater")</header> 674 </script> 675 676 <script id="product-instant-search-footer-template" type="text/x-handlebars-template"> 677 <footer class="typeahead-footer"> 678 <a href="@searchPageUrl{{query}}">@Translate("Smartpage:Search.Footer.Label", "Vis alle resultater for") {{query}}</a> 679 </footer> 680 </script> 681 682 <script id="product-instant-search-empty-template" type="text/x-handlebars-template"> 683 <div>@Translate("Smartpage:Search.EmptySearch", "Søgningen gav ingen resultater")</div> 684 </script> 685 686 <script id="product-instant-search-suggestion-template" type="text/x-handlebars-template"> 687 <a href="{{url}}" class="product-instant-search-item"> 688 <span class="">{{name}}</span> 689 <span class="info">{{{description}}}</span> 690 <span class="info">{{number}}</span> 691 </a> 692 </script> 693 } 694 695 696 <script> 697 var viewall = '@Translate("SearchViewAll", "View all")'; 698 var searchproducts = '@Translate("SearchProducts","Products")'; 699 var searchprojects = '@Translate("SearchProjects","Projects")'; 700 var searchvideos = '@Translate("SearchVideos","Videos")'; 701 var searchnoproducts = '@Translate("SearchNoProductsText","Unable to find any products that match the current query")'; 702 var searchnoprojects = '@Translate("SearchNoProjectsText","Unable to find any projects that match the current query")'; 703 var searchnovideos = '@Translate("SearchNoVideos","Unable to find any videos that match the current query")'; 704 </script> 705 706 707 @* Please use RenderProductSearchForm(string, string) instead *@ 708 @helper RenderInstantProductSearchForm(string btnText = null, string searchFieldPlaceholder = null) 709 { 710 //int id = Dynamicweb.Core.Converter.ToInt32(Pageview.Area.Item["SearchPage"]); 711 int id = Pageview.Page.ID; 712 string placeholder = searchFieldPlaceholder ?? Translate("Smartpage:Search.WriteSearch", "Indtast produktnavn"); 713 714 <form method="get" class="search-form" action="/Default.aspx"> 715 716 <input type="hidden" name="id" value="@id"> 717 <div class="search-input-wrapper"> 718 719 <input type="search" @*="" use="" with="" 'search'="" or="" 'text'="">>--!!-->> this input field is ALL u need for the typeahead functionality.. a form is only necessary when normal submit actions is needed *@ 720 class="js-typeahead-control input-search" @* the js-typeahead-control class is required. u can add whatever classes u need in addition *@ 721 name="q" @* parameter name used in both normal form submit AND in the XMLHttpRequest (normally 'q') *@ 722 value="@Dynamicweb.Context.Current.Request.GetString("q")" 723 placeholder="@placeholder" @* whatever.. *@ 724 data-minlength="@Dynamicweb.Core.Converter.ToInt32(Pageview.Area.Item["ProductSearchTypeaheadMinimumLength"])" @* minimum length of input text before we make the XMLHttpRequest (the results are cached so if u type the same thing twice it wont make a request the second time..) *@ 725 data-hint="@Dynamicweb.Core.Converter.ToBoolean(Pageview.Area.Item["ProductSearchTypeaheadShowHint"])" @* suggest the first search result 'behind' what is typed in the textfield (use right or down arrow to autocomplete ur search query).. the hint can be styled independently!! *@ 726 data-highlight="@Dynamicweb.Core.Converter.ToBoolean(Pageview.Area.Item["ProductSearchTypeaheadHighlight"])" @* will highlight the query text inside the suggestions *@ 727 data-suggestion-limit="@Dynamicweb.Core.Converter.ToInt32(Pageview.Area.Item["ProductSearchTypeaheadResultLimit"])" @* sets max number of results in suggestion template *@ 728 data-suggestion-limit-param-name="limit" @* the name of the limit parameter that will be added to the XMLHttpRequest url *@ 729 data-display-property="name" @* this is the property name in the returned result objects that we want to use for hints. *@ 730 data-load-indicator-selector="" @* puts a 'loading' class on the defined element when the XMLHttpRequest is waiting for response. If left empty, puts the 'loading' on 'this'. useful for using a pseudo class to show a loading icon with font-awesome or whatever *@ 731 data-remote-url="@String.Format(Dynamicweb.Core.Converter.ToString(Pageview.Page.PropertyItem["TypeAheadSearchLink"]))" @* @String.Format(" /Default.aspx?id={0}", Pageview.Area.Item["TypeAheadSearch"].ToString()) url for the XMLHttpRequest.. the name & limit parameters will automatically be added to this url *@ 732 data-empty-template="product-instant-search-empty-template" @* handlebars template id for when no results are found *@ 733 data-header-template="product-instant-search-header-template" @* handlebars template id for the header in the result *@ 734 data-suggestion-template="product-instant-search-suggestion-template" @* handlebars template id for each result object *@ 735 data-footer-template="product-instant-search-footer-template" @* handlebars template id for the footer in the result *@ 736 data-navigate-on-select="@Dynamicweb.Core.Converter.ToBoolean(Pageview.Area.Item["ProductSearchTypeaheadNavigateOnSelect"])" /> @* will navigate to the url of the selected result (on click or enter key).. !! the result objects must have a 'url' property for this to work *@ 737 738 <svg width="25px" height="25px" xmlns="http://www.w3.org/2000/svg" viewbox="0 0 100 100" preserveaspectratio="xMidYMid" class="lds-reload typeahead-load-indicator" style="background: rgba(0, 0, 0, 0) none repeat scroll 0% 0%;"> 739 <g> 740 <path d="M50 15A35 35 0 1 0 74.787 25.213" fill="none" stroke="#63a6b5" stroke-width="4"></path> 741 <path d="M49 7L49 23L57 15L49 7" fill="#63a6b5"></path> 742 <animatetransform attributename="transform" type="rotate" calcmode="linear" values="0 50 50;360 50 50" keytimes="0;1" dur="1s" begin="0s" repeatcount="indefinite"></animatetransform> 743 </g> 744 </svg> 745 <button class="btn btn-search" type="submit"> 746 @if (btnText != null) 747 { 748 @btnText 749 } 750 else 751 { 752 <i class="fa fa-search" aria-hidden="true"></i> 753 } 754 </button> 755 756 </div> 757 </form> 758 } 759 760 @helper RenderProductSearchForm(string btnText = null, string searchFieldPlaceholder = null) 761 { 762 int id = Dynamicweb.Core.Converter.ToInt32(Pageview.Area.Item["SearchPage"]); 763 764 string placeholder = searchFieldPlaceholder ?? Translate("Smartpage:Search.WriteSearch", "Indtast produktnavn"); 765 766 <form method="get" class="search-form" action="/Default.aspx"> 767 768 <input type="hidden" name="id" value="@id"> 769 <div class="search-input-wrapper"> 770 <div class="search-overlay"></div> 771 <div class="search-container tt-scrollable"> 772 773 <input type="search" name="q" class="form-control search-input" placeholder='@Translate("Smartpage:Global.Search.TypeToSearch","type to search")'> 774 <svg class="close-icon" data-name="Layer 1" xmlns="http://www.w3.org/2000/svg" viewbox="0 0 14 14"> 775 <path class="cls-1" d="M11.95,2.05a7,7,0,0,0-9.9,0A7,7,0,0,0,7,14,7,7,0,0,0,11.95,2.05Zm-.56,9.34A6.2,6.2,0,0,1,2.61,2.61a6.2,6.2,0,0,1,8.77,8.77Zm-1.3-7.47a.4.4,0,0,0-.56,0L7,6.44,4.48,3.92a.4.4,0,0,0-.56.56L6.44,7,3.91,9.52a.4.4,0,0,0,.28.68.39.39,0,0,0,.28-.12L7,7.56l2.52,2.52a.4.4,0,0,0,.28.12.38.38,0,0,0,.28-.12.4.4,0,0,0,0-.56L7.56,7l2.52-2.52A.4.4,0,0,0,10.09,3.92Z" transform="translate(0)"></path> 776 </svg> 777 </div> 778 779 @*<button class="btn btn-search" type="submit"> 780 @if (btnText != null) 781 { 782 @btnText 783 } 784 else 785 { 786 <i class="fa fa-search" aria-hidden="true"></i> 787 } 788 </button>*@ 789 </div> 790 </form> 791 } 792 793 @helper RenderProductSearchFormSimple(string searchFieldPlaceholder = null) 794 { 795 int id = Dynamicweb.Core.Converter.ToInt32(Pageview.Area.Item["SearchPage"]); 796 797 string placeholder = searchFieldPlaceholder ?? Translate("Smartpage:Search.WriteSearch", "Indtast produktnavn"); 798 799 <form method="get" class="search-form-v2" action="/Default.aspx"> 800 <input type="hidden" name="id" value="@id"> 801 <div class="tt-scrollable"> 802 <input type="search" @*="" use="" with="" 'search'="" or="" 'text'="">>--!!-->> this input field is ALL u need for the typeahead functionality.. a form is only necessary when normal submit actions is needed *@ 803 name="q" 804 value="@Dynamicweb.Context.Current.Request.GetString("q")" 805 class="form-control search-input typeahead" 806 placeholder="@Translate("Smartpage:Global.Search.TypeToSearch","type to search")" /> 807 </div> 808 809 </form> 810 } 811 812 @* Please use RenderProductSearchForm(string, string) instead *@ 813 @helper RenderProductSearchFormSmall(string btnText = null, string searchFieldPlaceholder = null) 814 { 815 int id = Dynamicweb.Core.Converter.ToInt32(Pageview.Area.Item["SearchPage"]); 816 817 string placeholder = searchFieldPlaceholder ?? Translate("Smartpage:Search.WriteSearch", "Indtast produktnavn"); 818 819 <form method="get" class="search-form" action="/Default.aspx"> 820 821 <input type="hidden" name="id" value="@id"> 822 <div class="search-input-wrapper"> 823 <div class="search-overlay"></div> 824 <div class="search-container-small"> 825 <svg class="search-icon" data-name="Layer 1" xmlns="http://www.w3.org/2000/svg" viewbox="0 0 21.99 20"> 826 <path class="cls-1" d="M9.31,13.85a6,6,0,0,1-4.18-1.58,5,5,0,0,1,0-7.61A6,6,0,0,1,9.31,3.08a6,6,0,0,1,4.18,1.58,5,5,0,0,1,0,7.61A6,6,0,0,1,9.31,13.85Zm12.2,3.53L17,13.26a7.79,7.79,0,0,0,.91-8.08,8.46,8.46,0,0,0-2-2.7,9.41,9.41,0,0,0-3-1.8,10.12,10.12,0,0,0-7.23,0,9.4,9.4,0,0,0-3,1.8,8.46,8.46,0,0,0-2,2.7,7.73,7.73,0,0,0,0,6.58,8.45,8.45,0,0,0,2,2.7,9.4,9.4,0,0,0,3,1.8,9.93,9.93,0,0,0,3.62.67,9.69,9.69,0,0,0,5.27-1.49l4.53,4.11A1.65,1.65,0,0,0,20.3,20a1.71,1.71,0,0,0,1.19-.46,1.43,1.43,0,0,0,0-2.16Z"></path> 827 </svg> 828 <input type="search" @*="" use="" with="" 'search'="" or="" 'text'="">>--!!-->> this input field is ALL u need for the typeahead functionality.. a form is only necessary when normal submit actions is needed *@ 829 name="q" @* parameter name used in both normal form submit AND in the XMLHttpRequest (normally 'q') *@ 830 value="@Dynamicweb.Context.Current.Request.GetString("q")" 831 class="form-control search-input" 832 placeholder="@Translate("Smartpage:Global.Search.TypeToSearch","type to search")" /> 833 834 </div> 835 836 837 @*<button class="btn btn-search" type="submit"> 838 @if (btnText != null) 839 { 840 @btnText 841 } 842 else 843 { 844 <i class="fa fa-search" aria-hidden="true"></i> 845 } 846 </button>*@ 847 </div> 848 </form> 849 } 850 851 @helper RenderFacebookScript() 852 { 853 <div id="fb-root"></div> 854 <script> 855 (function (d, s, id) { 856 var js, fjs = d.getElementsByTagName(s)[0]; 857 if (d.getElementById(id)) return; 858 js = d.createElement(s); js.id = id; 859 js.src = "//connect.facebook.net/da_DK/sdk.js#xfbml=1&version=v2.8"; 860 fjs.parentNode.insertBefore(js, fjs); 861 }(document, 'script', 'facebook-jssdk'));</script> 862 } 863 @using System; 864 @using Dynamicweb; 865 @inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> 866 @helper RenderFacebookShare() 867 { 868 bool sharePageFB = GetBoolean("Item.Page.SharePageOnFacebook"); 869 var pageViewUrlForSharing = Dynamicweb.Environment.Helpers.LinkHelper.GetHttpDomain() + Pageview.SearchFriendlyUrl; 870 871 if (sharePageFB) 872 { 873 <div class="fb-share-button" data-href="@pageViewUrlForSharing" data-layout="button" data-size="small" data-mobile-iframe="true"> 874 <a class="fb-xfbml-parse-ignore" target="_blank" href="https://www.facebook.com/sharer/sharer.php?u=https%3A%2F%2Fdevelopers.facebook.com%2Fdocs%2Fplugins%2F&amp;src=sdkpreparse"> 875 @Translate("Smartpage:SocialMedia.Share", "Del") 876 </a> 877 </div> 878 } 879 } 880 @*@SnippetStart("Meta") 881 @{ 882 string sharePageImage = Dynamicweb.Environment.Helpers.LinkHelper.GetHttpDomain() + GetString("Item.Page.ImageForSharing"); 883 string title = GetString("Title"); 884 string description = GetString("Meta.Description"); 885 var pageViewUrlForSharing = Dynamicweb.Environment.Helpers.LinkHelper.GetHttpDomain() + Pageview.SearchFriendlyUrl; 886 887 <meta property="fb:app_id" content="@appId"> /* default facebook app-id */ 888 <meta property="og:title" content='@title'> 889 <meta property="og:type" content="article"> 890 <meta property="og:image" content='@sharePageImage'> 891 <meta property="og:url" content='@pageViewUrlForSharing'> 892 <meta property="og:description" content="@description"> 893 } 894 @SnippetEnd("Meta")*@ 895 896 @{ 897 898 @SnippetStart("Meta") 899 //take default appid unless defined 900 string appID = !String.IsNullOrEmpty(Dynamicweb.Core.Converter.ToString(Pageview.Area.Item["FacebookAppId"])) ? "" : Dynamicweb.Core.Converter.ToString(Pageview.Area.Item["FacebookAppId"]); 901 <meta property="fb:app_id" content='@appID'> 902 903 if (string.IsNullOrEmpty(Dynamicweb.Context.Current.Request.GetString("ProductID"))) 904 { 905 string sharePageImage = Dynamicweb.Environment.Helpers.LinkHelper.GetHttpDomain() + GetString("Item.Page.ImageForSharing"); 906 string title = GetString("Title"); 907 string description = GetString("Meta.Description"); 908 var pageViewUrlForSharing = Dynamicweb.Environment.Helpers.LinkHelper.GetHttpDomain() + Pageview.SearchFriendlyUrl; 909 910 if (!string.IsNullOrEmpty(title)) 911 { 912 <meta property="og:title" content="@title"> 913 } 914 <meta property="og:type" content="website"> 915 if (!string.IsNullOrEmpty(sharePageImage)) 916 { 917 <meta property="og:image" content="@sharePageImage"> 918 } 919 if (!string.IsNullOrEmpty(pageViewUrlForSharing)) 920 { 921 <meta property="og:url" content="@pageViewUrlForSharing"> 922 } 923 if (!string.IsNullOrEmpty(description)) 924 { 925 <meta property="og:description" content="@description"> 926 } 927 928 } 929 @SnippetEnd("Meta") 930 } 931 @using Dynamicweb; 932 @using Dynamicweb.Core; 933 @inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> 934 @helper RenderLanguageList(string display = "Name") 935 { 936 if (Converter.ToBoolean(Pageview.Area.Item["LanguageActive"])) 937 { 938 var languages = GetLoop("Languages"); 939 if (languages.Any()) 940 { 941 <ul class="nav-list"> 942 @foreach (LoopItem language in languages) 943 { 944 var qs = HttpUtility.ParseQueryString(HttpContext.Current.Request.QueryString.ToString()); 945 qs.Set("ID", language.GetString("PageID")); 946 947 var link = "/Default.aspx?" + qs.ToString(); 948 var name = language.GetValue(display); 949 950 if (display == "TwoLetterISOLanguageName") 951 { 952 System.Globalization.CultureInfo culture = new System.Globalization.CultureInfo(language.GetString("Culture")); 953 name = culture.TwoLetterISOLanguageName; 954 } 955 if(display == "DisplayName") 956 { 957 System.Globalization.CultureInfo culture = new System.Globalization.CultureInfo(language.GetString("Culture")); 958 if (culture.IsNeutralCulture) 959 { 960 name = culture.EnglishName; 961 962 } 963 else 964 { 965 name = culture.Parent.EnglishName; 966 967 } 968 969 } 970 971 <li class="nav-item"> 972 <a href="@link" class="nav-link" title="@HttpUtility.HtmlEncode(name)">@name</a> 973 </li> 974 } 975 </ul> 976 } 977 } 978 } 979 @helper RenderLanguageDropdown(string display = "Name") 980 { 981 if (Converter.ToBoolean(Pageview.Area.Item["LanguageActive"])) 982 { 983 var languages = GetLoop("Languages"); 984 if (languages.Any()) 985 { 986 <div class="dropdown"> 987 <button type="button" id="langDropdown" class="dropdown-button js-toggle" data-target="#langDrop"> 988 @*@Translate("Smartpage.Language.Selector.Label", "Vælg sprog") <i class="fa fa-angle-down" aria-hidden="true"></i>*@ 989 @foreach (var k in GetLoop("Languages")) 990 { 991 var name = k.GetValue(display); 992 993 if (k.GetBoolean("IsCurrent")) 994 { 995 System.Globalization.CultureInfo culture = new System.Globalization.CultureInfo(k.GetString("Culture")); 996 name = culture.TwoLetterISOLanguageName; 997 <i class="fa fa-angle-down" aria-hidden="true"></i> @name; 998 } 999 else 1000 { 1001 @k.GetString("Culcure"); 1002 } 1003 } 1004 </button> 1005 <div id="langDrop" class="lang-dropdown"> 1006 @RenderLanguageList(display) 1007 </div> 1008 </div> 1009 } 1010 } 1011 } 1012 @helper RenderHeaderHrefLang() 1013 { 1014 if (Converter.ToBoolean(Pageview.Area.Item["LanguageActive"])) 1015 { 1016 var languages = GetLoop("Languages"); 1017 if (languages.Any()) 1018 { 1019 foreach (var language in languages) 1020 { 1021 var domain = Dynamicweb.Environment.Helpers.LinkHelper.GetHttpDomain(); 1022 1023 // Overwrite is we have a primary domain set on the area 1024 if (!string.IsNullOrEmpty(language.GetString("PrimaryDomain"))) 1025 { 1026 domain = HttpContext.Current.Request.IsSecureConnection ? "https://" : "http://"; 1027 domain += language.GetString("PrimaryDomain"); 1028 } 1029 1030 var qs = HttpUtility.ParseQueryString(HttpContext.Current.Request.QueryString.ToString()); 1031 qs.Set("ID", language.GetString("PageID")); 1032 var page = new Dynamicweb.Content.PageService().GetPage(language.GetInteger("FirstActivePageID")); 1033 string url = domain + Dynamicweb.Frontend.SearchEngineFriendlyURLs.GetFriendlyUrl(language.GetInteger("PageID")); 1034 1035 1036 foreach (string key in qs) 1037 { 1038 if (key == null || key.Equals("ID", StringComparison.InvariantCultureIgnoreCase)) 1039 { 1040 continue; 1041 } 1042 1043 var urlFromHandler = Dynamicweb.Frontend.UrlProviders.Handler.GetUrlFromQueryString(key, qs[key], page.Area.EcomLanguageId); 1044 if (Dynamicweb.Frontend.SearchEngineFriendlyURLs.UseExtensionLessUrls) 1045 { 1046 url += urlFromHandler.Replace(".aspx", ""); 1047 } 1048 else 1049 { 1050 url = url.Replace(".aspx", urlFromHandler); 1051 } 1052 } 1053 1054 <link rel="alternate" hreflang='@GetHrefLang(language.GetString("Culture"))' href="@url"> 1055 } 1056 } 1057 } 1058 } 1059 @functions{ 1060 string GetHrefLang(string cultureName) 1061 { 1062 var hrefLang = cultureName; 1063 switch (cultureName) 1064 { 1065 case "en-GB": 1066 hrefLang = "en"; 1067 break; 1068 } 1069 return hrefLang; 1070 } 1071 } 1072 1073 @using Dynamicweb; 1074 @inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> 1075 @helper RenderNewsletterSubscribeForm() 1076 { 1077 @*<form class="newsletter-signup-form" method="post" action='@Pageview.Area.Item["NewsletterSignupAction"]'> 1078 <input type="hidden" name="UserManagement_Form_EmailAllowed" value="True"> 1079 <input type="hidden" name="UserManagement_Form_EmailAllowed_ApplyValue" value="True"> 1080 <input type="hidden" name="UserManagementForm" value="1"> 1081 <input type="hidden" name="UserManagementForm.DeleteImage"> 1082 <div class="input-group text-center"> 1083 <input name="UserManagement_Form_Email" type="email" placeholder='@Translate("Smartpage:NewsletterPopbox.YourEmail", "E-mail adresse")' class="form-control js-req js-email inverted" required="required"> 1084 <span class="input-group-btn"> 1085 <button class="btn btn-primary js-validate-form form-control" type="submit"> 1086 <i class="newsletter-busy fa fa-refresh fa-spin fa-fw" style="display:none"></i> 1087 <span class="lbl">@Translate("Smartpage:NewsletterPopBox.SignUp", "Submit")</span> 1088 </button> 1089 </span> 1090 </div> 1091 1092 1093 </form>*@ 1094 1095 <div class="newsletter-signup-form-wrapper" style="margin: 0 auto;"> 1096 <form class="text-xs-center newsletter-signup-form js-active-campaignform" action="/systemactivecampaign"> 1097 <div class="input-group text-center"> 1098 <input name="list_id" value="3" type="hidden"> 1099 <input name="tag" value="Entertainment, Architecture" type="hidden"> 1100 <input name="email_address" type="email" placeholder="E-mail" class="form-control js-req js-email " required="required"> 1101 <div class="form-control-feedback alert alert-danger newsletter display-none js-invalid-nofill offset-xs-8 offset-sm-12 offset-md-14"> 1102 Must be completed 1103 </div> 1104 <div class="form-control-feedback alert alert-danger newsletter display-none js-error offset-xs-8 offset-sm-12 offset-md-14"> 1105 Something went wrong 1106 </div> 1107 <span class="input-group-btn"> 1108 <button class="btn btn-primary js-validate-form form-control" type="submit"> 1109 <img src="/files/images/svg/loading.svg" width="25" class="newsletter-busy" style="display:none" alt="SGM LIGHT"> 1110 <span class="lbl">@Translate("Smartpage:NewsletterPopBox.SignUp", "Submit")</span> 1111 </button> 1112 </span> 1113 </div> 1114 </form> 1115 </div> 1116 1117 } 1118 @{ 1119 string languageCode = GetGlobalValue("Global:Area.Lang").ToLower(); 1120 string version = Dynamicweb.Core.Converter.ToBoolean(Pageview.Area.Item["DeveloperMode"]) ? "0." + DateTime.Now.Ticks : "2.6"; 1121 string cookieLink = GetString("Item.Area.CookieLink"); 1122 1123 1124 string primaryProductPageId = PageView.Current().Area.Item["PrimaryProductPage"].ToString(); 1125 string pageId = GetString("Global.PageId"); 1126 } 1127 <!DOCTYPE html> 1128 <html lang="@languageCode"> 1129 <head> 1130 1131 @{ 1132 var designBaseUrl = GetString("Template:DesignBaseUrl").TrimEnd('/'); 1133 bool isLoggedIn = Dynamicweb.Security.UserManagement.User.IsExtranetUserLoggedIn(); 1134 bool useAlternativeHeader = Pageview.Page.PropertyItem != null && Dynamicweb.Core.Converter.ToBoolean(Pageview.Page.PropertyItem["UseAlternativeHeader"]); 1135 } 1136 1137 <meta charset="utf-8"> 1138 <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"> 1139 <meta http-equiv="x-ua-compatible" content="ie=edge"> 1140 <title>@GetValue("Title")</title> 1141 @GetValue("MetaTags") 1142 @GetValue("CopyRightNotice") 1143 1144 @RenderSnippet("Meta") 1145 @{ 1146 1147 // HEADTAGS 1148 var headTags = (Pageview.Area.Item["HeadTags"] != null && !string.IsNullOrEmpty(Converter.ToString(Pageview.Area.Item["HeadTags"])) ? Converter.ToString(Pageview.Area.Item["HeadTags"]) : null); 1149 if (headTags != null) 1150 { 1151 <!-- Head Tags --> 1152 @headTags 1153 <!-- // Head Tags --> 1154 } 1155 } 1156 <link rel="stylesheet" href="@designBaseUrl/Assets/Styles/Main.min.css?v=@version"> 1157 1158 1159 <link rel="stylesheet" href="@designBaseUrl/Assets/Styles/Custom/_custom-changes.css?v=@version"> 1160 1161 <link href="@designBaseUrl/Assets/Styles/Custom/1stweb/first.main.min.css?v=@version" rel="stylesheet"> 1162 1163 @*GOOGLE FONTS*@ 1164 1165 <link href="https://fonts.googleapis.com/css2?family=IBM+Plex+Sans:wght@300;400&family=Montserrat:wght@400;500;700&family=Material+Icons&display=swap" rel="stylesheet"> 1166 1167 1168 @RenderHeaderHrefLang() 1169 1170 @*Scripts*@ 1171 @RenderStandardInstantProductSearchTemplates() 1172 1173 <link rel="apple-touch-icon" sizes="76x76" href="/files/images/favicon/apple-touch-icon.png"> 1174 <link rel="icon" type="image/png" sizes="32x32" href="/files/images/favicon/favicon-32x32.png"> 1175 <link rel="icon" type="image/png" sizes="16x16" href="/files/images/favicon/favicon-16x16.png"> 1176 <link rel="manifest" href="/files/images/favicon/manifest.json"> 1177 <link rel="mask-icon" href="/files/images/favicon/safari-pinned-tab.svg" color="#225f82"> 1178 <link rel="shortcut icon" href="/files/images/favicon/favicon.ico"> 1179 <meta name="msapplication-config" content="/files/images/favicon/browserconfig.xml"> 1180 <meta name="theme-color" content="#ffffff"> 1181 @if (GetGlobalValue("Global:Request.Url").Contains("staging") || GetGlobalValue("Global:Request.Url").Contains("development")) 1182 { 1183 <meta name="robots" content="noindex, nofollow"> 1184 } 1185 @*@RenderSnippet("PaginationLinks")*@ 1186 @GetValue("Stylesheets") 1187 @GetValue("Javascripts") 1188 </head> 1189 1190 1191 <body class="body"> 1192 @{ 1193 var googleAnalyticsId = (Pageview.Area.Item["GoogleAnalyticsId"] != null && !string.IsNullOrEmpty(Converter.ToString(Pageview.Area.Item["GoogleAnalyticsId"])) 1194 ? Converter.ToString(Pageview.Area.Item["GoogleAnalyticsId"]) : null); 1195 if (googleAnalyticsId != null) 1196 { 1197 <!-- Google Analytics --> 1198 @googleAnalyticsId 1199 <!-- // Google Analytics --> 1200 } 1201 } 1202 @*@RenderFacebookScript() *@ 1203 1204 1205 1206 1207 <header class="header"> 1208 @{ 1209 var headerNavigationMobileClass = Converter.ToBoolean(Pageview.Area.Item["LanguageActive"]) ? "has-language" : ""; 1210 } 1211 1212 <div class="header-navigation"> 1213 <nav class="navbar v-align"> 1214 1215 1216 @if (Dynamicweb.Core.Converter.ToString(Pageview.Area.Item["LogoLarge"]) != "") 1217 { 1218 var logoLargeLink = "Default.aspx?ID=" + GetInteger("DwAreaFirstPageID"); 1219 var logoLarge = Dynamicweb.Core.Converter.ToString(Pageview.Area.Item["LogoLarge"]); 1220 @*<div class="header-logo-large"> 1221 <a href="@logoLargeLink" title='@GetString("DwAreaName")'> 1222 <img src="@logoLarge" class="img-fluid" alt='@GetString("DwAreaName")'> 1223 </a> 1224 </div>*@ 1225 <a class="navbar-brand abs" href="/"><img src="@logoLarge" class="img-fluid" alt='@GetString("DwAreaName")'></a> 1226 } 1227 1228 @RenderNavigationMega() 1229 1230 <ul class="header-right nav v-align"> 1231 @*<li class="nav-item"> 1232 1233 @RenderLanguageDropdown("DisplayName") 1234 </li>*@ 1235 <li class="nav-item"> 1236 @RenderCartMiniIcon("link") 1237 </li> 1238 </ul> 1239 </nav> 1240 </div> 1241 <div class="header-mobile v-align hidden-lg-up"> 1242 @*<button class="hamburger hamburger--slider js-navigation-toggle js-toggle hidden-lg-up" type="button" data-target=".js-navigation-mobile" data-toggle-type="hamburger"> 1243 <span class="hamburger-box"> 1244 <span class="hamburger-inner"></span> 1245 </span> 1246 </button>*@ 1247 @*<button class="hamburger hamburger--slider js-hamburger-slide js-navigation-toggle hidden-lg-up" type="button"> 1248 <span class="hamburger-box"> 1249 <span class="hamburger-inner"></span> 1250 </span> 1251 </button>*@ 1252 <div class="hamburger js-hamburger-slide" id="hamburger-9"> 1253 <span class="line"></span> 1254 <span class="line"></span> 1255 <span class="line"></span> 1256 </div> 1257 1258 <div class="header-navigation-mobile @headerNavigationMobileClass"> 1259 <div class="navigation-slide-right"> 1260 @RenderNavigationSlideRight() 1261 </div> 1262 </div> 1263 @if (Dynamicweb.Core.Converter.ToString(Pageview.Area.Item["Logo"]) != "") 1264 { 1265 var logoLink = "Default.aspx?ID=" + GetInteger("DwAreaFirstPageID"); 1266 var logo = Dynamicweb.Core.Converter.ToString(Pageview.Area.Item["LogoLarge"]); 1267 1268 <a class="navbar-brand abs" href="#"><img src="@logo" class="img-fluid" alt='@GetString("DwAreaName")'></a> 1269 } 1270 <ul class="header-right nav v-align"> 1271 <li class="nav-item"> 1272 @RenderCartMiniIcon("link") 1273 </li> 1274 <li class="nav-item"> 1275 <span class="header-icon-search js-search-form-icon nav-item-link"> 1276 <img src="/Files/Templates/Designs/Basic/Assets/Images/search.svg" alt="search"><span class="hidden-md-down">Search</span> 1277 </span> 1278 </li> 1279 </ul> 1280 1281 <div class="js-search-form"> 1282 @RenderProductSearchForm() 1283 </div> 1284 1285 </div> 1286 1287 </header> 1288 1289 1290 @{ 1291 var frontPageClass = ""; 1292 1293 if (GetBoolean("Item.Page.IsFrontpage")) 1294 { 1295 frontPageClass = "frontpage"; 1296 } 1297 1298 var alternativeHeader = GetBoolean("Item.Page.UseAlternativeHeader") ? "alternative-header" : ""; 1299 1300 } 1301 1302 <div class="wrapper @frontPageClass @alternativeHeader"> 1303 <div class="page"> 1304 1305 @*OLD HEADER PLACEMENT*@ 1306 <div class="content"> 1307 <div class="global-content-wrapper"> 1308 @if (primaryProductPageId != pageId && !GetString("DwTopPageName").ToLower().Contains("products")) 1309 { 1310 if (Dynamicweb.Core.Converter.ToBoolean(Pageview.Area.Item["ShowBreadcrumbsOnWebsite"]) && (Pageview.Page.PropertyItem == null || 1311 !Dynamicweb.Core.Converter.ToBoolean(Pageview.Page.PropertyItem["DisableBreadcrumbsOnPage"]))) 1312 { 1313 string hiddenMobileClass = Dynamicweb.Core.Converter.ToBoolean(Pageview.Area.Item["ShowBreadcrumbsOnMobile"]) ? "" : "hidden-xs-down"; 1314 string prefix = Dynamicweb.Core.Converter.ToString(Pageview.Area.Item["BreadcrumbsPrefix"]); 1315 <div class="container breadcrumbs @hiddenMobileClass"> 1316 1317 @if (!string.IsNullOrWhiteSpace(prefix)) 1318 { 1319 <span class="pull-left">@prefix&nbsp;&nbsp;</span> 1320 } 1321 1322 1323 @RenderNavigation(new 1324 { 1325 template = "breadcrumbs.xslt", 1326 id = "breadcrumb", 1327 sitemapmode = "true", 1328 homepageText = @Translate("homepage", "Forside") 1329 }) 1330 </div> 1331 } 1332 } 1333 1334 @using System; 1335 @using System.Web; 1336 @using System.Linq; 1337 @using Dynamicweb; 1338 @inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> 1339 1340 1341 @using System; 1342 @using System.Web; 1343 @using Dynamicweb; 1344 @inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> 1345 1346 @helper RenderBreadcrumbsProductPage(string currentGroup, string linkPageId, string productId) 1347 { 1348 List<Dynamicweb.Ecommerce.Products.Group> breadcumbGroups = SGMLight.Website.CustomCode.EcomGroups.getBreadCrumbGroupListByProduct(productId, true); 1349 1350 if (Dynamicweb.Core.Converter.ToBoolean(Pageview.Area.Item["ShowBreadcrumbsOnWebsite"]) && (Pageview.Page.PropertyItem == null || !Dynamicweb.Core.Converter.ToBoolean(Pageview.Page.PropertyItem["DisableBreadcrumbsOnPage"])) && breadcumbGroups != null && breadcumbGroups.Count > 0) 1351 { 1352 string hiddenMobileClass = Dynamicweb.Core.Converter.ToBoolean(Pageview.Area.Item["ShowBreadcrumbsOnMobile"]) ? "" : "hidden-xs-down"; 1353 string prefix = Dynamicweb.Core.Converter.ToString(Pageview.Area.Item["BreadcrumbsPrefix"]); 1354 <div class="container breadcrumbs @hiddenMobileClass"> 1355 1356 @if (!string.IsNullOrWhiteSpace(prefix)) 1357 { 1358 <span class="pull-left">@prefix&nbsp;&nbsp;</span> 1359 } 1360 1361 <ul class="breadcrumb-ul"> 1362 @foreach (Dynamicweb.Ecommerce.Products.Group group in breadcumbGroups) 1363 { 1364 string groupLinkLoop = string.Format("/Default.aspx?ID={0}&GroupID={1}", int.Parse(linkPageId), group.Id); 1365 <li> 1366 <a href="@groupLinkLoop ">@group.Name</a> 1367 <span> / </span> 1368 </li> 1369 } 1370 1371 <li><span class="divider">@GetString("Ecom:Product.Name")</span></li> 1372 </ul> 1373 </div> 1374 } 1375 } 1376 1377 1378 @helper RenderBreadcrumbsProductGroupPage(Dynamicweb.Ecommerce.Products.Group breadcumbGroup, string linkPageId) 1379 { 1380 List<Dynamicweb.Ecommerce.Products.Group> breadcumbGroups = SGMLight.Website.CustomCode.EcomGroups.getBreadCrumbGroupList(breadcumbGroup, true); 1381 1382 1383 if (Dynamicweb.Core.Converter.ToBoolean(Pageview.Area.Item["ShowBreadcrumbsOnWebsite"]) && (Pageview.Page.PropertyItem == null || !Dynamicweb.Core.Converter.ToBoolean(Pageview.Page.PropertyItem["DisableBreadcrumbsOnPage"])) && breadcumbGroups != null && breadcumbGroups.Count > 0) 1384 { 1385 string hiddenMobileClass = Dynamicweb.Core.Converter.ToBoolean(Pageview.Area.Item["ShowBreadcrumbsOnMobile"]) ? "" : "hidden-xs-down"; 1386 string prefix = Dynamicweb.Core.Converter.ToString(Pageview.Area.Item["BreadcrumbsPrefix"]); 1387 1388 if (breadcumbGroups.Any(x => x.Id != breadcumbGroup.Id)) 1389 { 1390 <div class="container breadcrumbs @hiddenMobileClass"> 1391 @if (!string.IsNullOrWhiteSpace(prefix)) 1392 { 1393 <span class="pull-left">@prefix&nbsp;&nbsp;</span> 1394 } 1395 1396 <ul class="breadcrumb-ul"> 1397 @foreach (Dynamicweb.Ecommerce.Products.Group group in breadcumbGroups.Where(x => x.Id != breadcumbGroup.Id)) 1398 { 1399 string groupLinkLoop = string.Format("/Default.aspx?ID={0}&GroupID={1}", int.Parse(linkPageId), group.Id); 1400 <li> 1401 <a href="@groupLinkLoop ">@group.Name</a> 1402 <span> / </span> 1403 </li> 1404 } 1405 <li><span class="divider">@breadcumbGroup.Name</span></li> 1406 </ul> 1407 </div> 1408 } else { 1409 <div class="container breadcrumbs @hiddenMobileClass"> 1410 @if (!string.IsNullOrWhiteSpace(prefix)) 1411 { 1412 <span class="pull-left">@prefix&nbsp;&nbsp;</span> 1413 } 1414 1415 <ul class="breadcrumb-ul"> 1416 <li><span class="divider">@breadcumbGroup.Name</span></li> 1417 </ul> 1418 </div> 1419 } 1420 } 1421 } 1422 @using System.ServiceModel.Security 1423 @using System.Web 1424 @using Dynamicweb 1425 @using Dynamicweb.Environment; 1426 @using Dynamicweb.Core; 1427 @using Dynamicweb.Ecommerce; 1428 @using System.Text.RegularExpressions; 1429 @using SGMLight.Website.CustomModules.Files; 1430 1431 @inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> 1432 1433 1434 @helper RenderProductClean(LoopItem i, string gutter, string colSize, bool useGroupLink = true, string pageId = null) 1435 { 1436 1437 object productLink = i.GetValue("Ecom:Product.Link.Clean"); 1438 string productName = i.GetString("Ecom:Product.Name"); 1439 string productNameForAttribute = Dynamicweb.Core.Encoders.HtmlEncoder.HtmlEncode(productName); 1440 1441 string productImageClean = i.GetString("Ecom:Product:Field.SpPerfionMarketingProductPageImage1"); 1442 string productImage = string.IsNullOrEmpty(productImageClean) ? i.GetString("Ecom:Product.ImageLarge.Default.Clean") : "/admin/public/GetImage.ashx?Image=" + Dynamicweb.Core.Encoders.HtmlEncoder.UrlPathEncode(productImageClean) + "&amp;Compression=75&amp;crop=6&amp;width=400&amp;height=400"; 1443 Image image = new Image(productImage); 1444 1445 string productIconsPage = i.GetString("Ecom:Product:Field.icons.Value.Clean"); 1446 int productIconsPageId = 0; 1447 if (productIconsPage != "") 1448 { 1449 productIconsPageId = Int32.Parse(productIconsPage.Substring(productIconsPage.LastIndexOf('=') + 1)); 1450 } 1451 1452 <div class="productlist-item @gutter @colSize js-productlist-item"> 1453 <form method="post" class="js-ecom-product-form" autocomplete="off" data-disabled="false" data-check-stock='@Converter.ToString(Pageview.Area.Item["CheckStock"])'> 1454 <input type="hidden" name="CartCmd" value="add"> 1455 <input type="hidden" name="ProductID" value="@i.GetValue(" ecom:product.id")"=""> 1456 <a href="@productLink" class="productlist-content js-product-link"> 1457 1458 <div class="e-productlist-item-image-container"> 1459 <div class="e-productlist-item-image-wrapper"> 1460 <img class="e-productlist-item-image hover-zoom" alt='@(image.GetMetaData("ImageAlt") ?? Translate("Novicell:DefaultImageAltText", "SGM LIGHT"))' src="@productImage" title="@productNameForAttribute"> 1461 </div> 1462 </div> 1463 1464 <span class="co3-productlist-name" title="@productNameForAttribute"> 1465 @productNameForAttribute 1466 </span> 1467 <span class="d-block"><small>@i.GetString("Ecom:Product:Field.SpPerfionStrMarketingDataProductFolderProductPageSubheader")</small></span> 1468 @if (productIconsPageId != 0) 1469 { 1470 <div class="icons">@RenderPageContent(productIconsPageId)</div> 1471 } 1472 @RenderProductRibbon(i) 1473 </a> 1474 @RenderProductListAddToCart(i) 1475 </form> 1476 </div> 1477 } 1478 1479 @helper RenderProduct(LoopItem i, string gutter, string colSize, bool useGroupLink = true, string pageId = null) 1480 { 1481 var id = i.GetValue("Ecom:Product.ID"); 1482 var productLink = i.GetValue("Ecom:Product.Link.Clean"); 1483 1484 string productName = i.GetString("Ecom:Product.Name"); 1485 string ItemNumber = i.GetString("Ecom:Product:Field.SpPerfionItemNumber"); 1486 //string productImageClean = i.GetString("Ecom:Product.Image.1.Clean"); 1487 var productImageClean = i.GetString("Ecom:Product:Field.SpPerfionMarketingProductPageImage1"); 1488 1489 string productImage = string.IsNullOrEmpty(productImageClean) ? i.GetString("Ecom:Product.ImageLarge.Default.Clean") 1490 : "/admin/public/GetImage.ashx?Image=" + Dynamicweb.Core.Encoders.HtmlEncoder.UrlPathEncode(productImageClean) + "&amp;Compression=75&amp;crop=6&amp;width=400&amp;height=400"; 1491 1492 var image = new Image(productImageClean); 1493 //var altText = metaData == null ? Translate("Novicell:DefaultImageAltText", "SGM LIGHT") : metaData.GetValue("ImageAlt") ?? Translate("Novicell:DefaultImageAltText", "SGM LIGHT"); 1494 1495 bool service = i.GetInteger("Ecom:Product.Type") == 1; 1496 string productNameForAttribute = Dynamicweb.Core.Encoders.HtmlEncoder.HtmlEncode(productName); 1497 1498 @*var iam = Dynamicweb.Content.Files.Metadata.EditorFactory.GetMetadataForFile("C:/DW9Projects/SGMLight.Website/SGMLight.Website/Files/images/perfion/P-1_front.png"); 1499 @iam.GetValue("ImageAlt")<hr>*@ 1500 1501 @*var product = Dynamicweb.Ecommerce.Products.Product.GetProductById(i.GetString("Ecom:Product.ID")); 1502 @product.Meta.ToString()*@ 1503 1504 <div class='productlist-item @gutter @colSize js-productlist-item'> 1505 <form method="post" class="js-ecom-product-form" autocomplete="off" data-disabled="false" data-check-stock='@Converter.ToString(Pageview.Area.Item["CheckStock"])'> 1506 <input type="hidden" name="CartCmd" value="add"> 1507 <input type="hidden" name="ProductID" value="@i.GetValue(" ecom:product.id")"=""> 1508 <div class="productlist-content"> 1509 1510 <a href="@productLink" class="productlist-image-link js-product-link d-block"> 1511 <img class="img-fluid hover-zoom" alt='@(image.GetMetaData("ImageAlt") ?? Translate("Novicell:DefaultImageAltText", "SGM LIGHT"))' src="@productImage" title="@productNameForAttribute"> 1512 </a> 1513 <a href="@productLink" class="name" title="@productNameForAttribute"> 1514 @productNameForAttribute 1515 </a> 1516 <span class="d-block">@i.GetString("Ecom:Product:Field.SpPerfionStrMarketingDataProductFolderProductPageSubheader")</span> 1517 @*@RenderProductPrice(false, i)*@ 1518 @RenderProductRibbon(i) 1519 </div> 1520 @RenderProductListAddToCart(i) 1521 </form> 1522 </div> 1523 } 1524 1525 1526 1527 @helper RenderProductListAddToCart(LoopItem i, bool isAddMulti = false) 1528 { 1529 var enableCart = Converter.ToBoolean(Pageview.Area.Item["EnableCart"]); 1530 if (enableCart) 1531 { 1532 var enableVariant = false; 1533 var quantityColClass = isAddMulti ? "col-xs-24" : "col-xs-10"; 1534 1535 <div class="row no-gutters js-input-spinner add-to-cart"> 1536 @if (enableVariant && i.GetInteger("Ecom:Product.VariantCount") > 0) 1537 { 1538 @*<a href="@productLink" class="btn btn-primary btn-block js-ecom-product-button">@Translate("Smartpage:Ecom.ProductList.Button.ChooseVariant", "Vælg variant")</a>*@ 1539 } 1540 else 1541 { 1542 @*<div class="@quantityColClass"> 1543 @RenderChevrons(i, isAddMulti) 1544 </div>*@ 1545 if (!isAddMulti) 1546 { 1547 <div class="col-xs-24"> 1548 @*<button class="btn btn-primary btn-block js-ecom-product-button"> 1549 <i class="js-ecom-product-button-spinner"></i> 1550 <span class="js-ecom-product-button-text">@Translate("Smartpage:Ecom.ProductList.Button.AddToBasket", "Læg i kurv")</span> 1551 </button>*@ 1552 <button class="btn btn-block btn-small js-ecom-product-button"> 1553 <i class="js-ecom-product-button-spinner"></i> 1554 <span class="js-ecom-product-button-text">@Translate("Smartpage:Ecom.ProductList.Button.AddToQuote", "Add to quote list")</span> 1555 </button> 1556 </div> 1557 } 1558 } 1559 </div> 1560 } 1561 } 1562 1563 @helper RenderProductAddToCart() 1564 { 1565 @*@if (i.GetInteger("Ecom:Product.VariantCount") > 0) 1566 { 1567 <a href="@productLink" class="btn btn-primary btn-block js-ecom-product-button">@Translate("Smartpage:Ecom.ProductList.Button.ChooseVariant", "Vælg variant")</a> 1568 } 1569 else 1570 {*@ 1571 <div class="row"> 1572 <div class="col-xs-7"> 1573 @RenderChevrons(null, false) 1574 </div> 1575 <div class="col-xs-17"> 1576 <button class="btn btn-primary js-ecom-product-button addtocart"> 1577 <i class="js-ecom-product-button-spinner"></i> 1578 <span class="js-ecom-product-button-text">@Translate("Smartpage:Ecom.ProductList.Button.AddToBasket", "Læg i kurv")</span> 1579 </button> 1580 </div> 1581 </div> 1582 @* } *@ 1583 } 1584 1585 @helper RenderChevrons(LoopItem i, bool isAddMulti, bool isreciept = false) 1586 { 1587 bool service = getIntegerByKey(i, "Ecom:Product.Type") == 1; 1588 string id = getStringByKey(i, "Ecom:Product.ID"); 1589 string productName = getStringByKey(i, "Ecom:Product.Name"); 1590 string productNameForAttribute = Dynamicweb.Core.Encoders.HtmlEncoder.HtmlEncode(productName); 1591 string quantity = isAddMulti ? "0" : (getStringByKey(i, "Ecom:Order:OrderLine.Quantity") != "") ? getStringByKey(i, "Ecom:Order:OrderLine.Quantity") : "1"; 1592 int loopCounter = getIntegerByKey(i, "Ecom:Product.LoopCounter"); 1593 string name = isAddMulti ? "Quantity" + loopCounter : (getStringByKey(i, "Ecom:Order:OrderLine.Quantity.Input.Name") != "") ? getStringByKey(i, "Ecom:Order:OrderLine.Quantity.Input.Name") : "Quantity"; 1594 if (!isreciept) 1595 { 1596 <div class="input-group qty-container"> 1597 @*<input type="number" min="@quantity" name="@name" tabindex="@loopCounter" class="form-control stack-input js-ecom-product-quantity" value="@quantity" data-productid='@id' data-service='@service' data-productname="@productNameForAttribute">*@ 1598 1599 <input type="tel" min="1" name="@name" tabindex='@loopCounter' class="form-control text-xs-center js-ecom-product-quantity" value="@quantity"> 1600 1601 <div class="input-group-btn qty-group"> 1602 <span class="btn-chevron btn-chevron-up js-input-spinner-up"> 1603 <i class="fa fa-angle-up" aria-hidden="true"></i> 1604 </span> 1605 <span class="btn-chevron btn-chevron-down js-input-spinner-down"> 1606 <i class="fa fa-angle-down"></i> 1607 </span> 1608 </div> 1609 </div> 1610 } 1611 else 1612 { 1613 @quantity 1614 } 1615 } 1616 1617 1618 @helper RenderProductList(LoopItem i, string gutter, string colSize, bool favoriteList = false, string pageId = null, bool priceDeals = false) 1619 { 1620 <form method="post" class="js-ecom-product-form @colSize" autocomplete="off" data-disabled="false" data-check-stock='@Dynamicweb.Core.Converter.ToString(Pageview.Area.Item["CheckStock"])'> 1621 <input type="hidden" name="CartCmd" value="add"> 1622 <input type="hidden" name="ProductID" value="@i.GetValue(" ecom:product.id")"=""> 1623 @RenderProductListContent(i, gutter, colSize, favoriteList, false, true, pageId) 1624 </form> 1625 1626 } 1627 1628 @helper RenderProductListContent(LoopItem i, string gutter, string colSize, bool favoriteList = false, bool isAddMulti = false, bool useGroupLink = true, string pageId = null, bool priceDeals = false) 1629 { 1630 1631 var id = i.GetValue("Ecom:Product.ID"); 1632 var productLink = useGroupLink ? i.GetValue("Ecom:Product.LinkGroup.Clean") : i.GetValue("Ecom:Product.Link.Clean"); 1633 if (!string.IsNullOrEmpty(pageId)) 1634 { 1635 productLink = "/Default.aspx?Id=" + pageId; 1636 if (useGroupLink) 1637 { 1638 productLink += "&groupid=" + i.GetString("Ecom:Product.PrimaryOrFirstGroupID"); 1639 } 1640 productLink += "&ProductId=" + id; 1641 } 1642 string productName = i.GetString("Ecom:Product.Name"); 1643 string productImageClean = i.GetString("Ecom:Product.Image.1.Clean"); 1644 string productImage = string.IsNullOrEmpty(productImageClean) ? i.GetString("Ecom:Product.ImageLarge.Default.Clean") 1645 : "/admin/public/GetImage.ashx?Image=" + Dynamicweb.Core.Encoders.HtmlEncoder.UrlPathEncode(productImageClean) + "&amp;Compression=75&amp;width=400&amp;height=400"; 1646 bool service = i.GetInteger("Ecom:Product.Type") == 1; 1647 1648 string productNameForAttribute = Dynamicweb.Core.Encoders.HtmlEncoder.HtmlEncode(productName); 1649 string shortDescription = i.GetString("Ecom:Product.ShortDescription"); 1650 1651 int loopCounter = GetInteger("Ecom:Product.LoopCounter"); 1652 string addMultiClass = isAddMulti ? "add-multi" : ""; 1653 colSize = isAddMulti ? colSize : ""; 1654 1655 1656 <div class="py-2 my-1 productlist-content productlist-item @gutter @colSize @addMultiClass"> 1657 @if (isAddMulti) 1658 { 1659 <text>@i.GetString("Ecom:Product.Form.Multi.HiddenFields")</text> 1660 } 1661 <div class=""> 1662 <div class="row row-eq-height"> 1663 <div class="col-xs-24 col-lg-5 text-xs-center"> 1664 <a href="@productLink" title="@productNameForAttribute" class="productlist-image-link "> 1665 <img class="img-fluid product-img" alt="@productNameForAttribute" src="@productImage" title="@productNameForAttribute"> 1666 @RenderProductRibbon(i) 1667 </a> 1668 @RenderProductRibbon(i) 1669 </div> 1670 <div class="col-xs-24 col-lg-11 text-lg-left list_text"> 1671 <a href="@productLink" class="name" title="@productNameForAttribute"> 1672 @productNameForAttribute 1673 </a> 1674 <div class="short_desc"> 1675 @shortDescription 1676 </div> 1677 @if (string.IsNullOrEmpty(i.GetString("Ecom.Product.Number"))) 1678 { 1679 1680 <div class="row"> 1681 <div class="col-xs-14 col-xl-11"> 1682 1683 <strong>@Translate("Smartpage:Ecom.ProductList.SKU.Label", "Varenr"):</strong> 1684 </div> 1685 <div class="col-xs-10 col-xl-13 text-xs-right text-md-left"> 1686 @i.GetString("Ecom:Product.Number") 1687 </div> 1688 </div> 1689 } 1690 1691 @if (priceDeals) 1692 { 1693 <div class="row"> 1694 <div class="col-xs-14 col-xl-11"> 1695 1696 <strong>@Translate("Smartpage:Ecom.ProductList.BruttoPrice", "Bruttopris"):</strong> 1697 </div> 1698 <div class="col-xs-10 col-xl-13 text-xs-right text-md-left"> 1699 @i.GetString("Ecom:Product:Field.AXBruttoPrice") 1700 </div> 1701 </div> 1702 } 1703 1704 1705 <div class="row"> 1706 <div class="col-xs-14 col-xl-11"> 1707 <strong>@Translate("Smartpage:Ecom.ProductList.Stock.Label", "Lagerbeholdning"):</strong> 1708 </div> 1709 <div class="col-xs-10 col-xl-13 text-xs-right text-md-left"> 1710 1711 @RenderProductStock(false, i) 1712 </div> 1713 </div> 1714 </div> 1715 1716 <div class="col-xs-24 col-lg-8 vbottom"> 1717 @if (favoriteList) 1718 { 1719 <div class="row no-gutters pull-right"> 1720 <a class="remove-from-fav js-remove-from-fav" href="@i.GetValue(" ecom:product.removefromlist")"=""><strong>@Translate("Smartpage:MyList.ProductList.DeleteFromList", "Fjern fra liste")</strong></a> 1721 </div> 1722 } 1723 <div class="row no-gutters"> 1724 <div class="col-xs-24"> 1725 <div class="float-xs-left float-lg-right"> 1726 1727 @RenderProductPrice(false, i) 1728 </div> 1729 </div> 1730 </div> 1731 <div class="row no-gutters js-input-spinner add-to-cart"> 1732 <div class="col-xs-24"> 1733 @*@if (i.GetInteger("Ecom:Product.VariantCount") > 0) 1734 { 1735 <a href="@productLink" class="btn btn-primary btn-block js-ecom-product-button">@Translate("Smartpage:Ecom.ProductList.Button.ChooseVariant", "Vælg variant")</a> 1736 } 1737 else 1738 {*@ 1739 @RenderProductListAddToCart(i, isAddMulti) 1740 @* } *@ 1741 </div> 1742 </div> 1743 1744 </div> 1745 </div> 1746 </div> 1747 </div> 1748 1749 1750 } 1751 1752 @helper RenderGroup(LoopItem g, string colSize) 1753 { 1754 string imagePath = g.GetString("Ecom:Group.LargeImage"); 1755 var groupImg = "/Admin/Public/GetImage.ashx?Image=" + imagePath + "&Width=400&Height=400&Crop=5;"; 1756 var tempImg = groupImg.Replace("//", "/"); 1757 string groupName = g.GetString("Ecom:Group.Name"); 1758 string groupLink = g.GetString("Ecom:Group.Link.Clean"); 1759 1760 <div class="@colSize"> 1761 <div class="grouplist"> 1762 <a href="@groupLink"> 1763 <img src="@tempImg" alt="@groupName" class="img-fluid grouplist-img hidden-md-down"> 1764 </a> 1765 <div class="grouplist-name"> 1766 <a href="@groupLink"> 1767 @groupName 1768 </a> 1769 </div> 1770 </div> 1771 </div> 1772 1773 } 1774 1775 @helper RenderPageTotals() 1776 { 1777 <div> 1778 1779 @{ 1780 var pageSize = Dynamicweb.Core.Converter.ToInt32(@GetValue("Ecom:ProductList.PageSize")); 1781 var pageCount = Dynamicweb.Core.Converter.ToInt32(@GetValue("Ecom:ProductList.PageProdCnt")); 1782 } 1783 1784 @if (pageSize > pageCount) 1785 { 1786 <span>@pageCount @Translate("SmartPage:ProductList.Total.Of", "af") @pageCount @Translate("SmartPage:ProductList.Total.ProductsInTotal", "produkter")</span> 1787 } 1788 else 1789 { 1790 <span>@pageSize @Translate("SmartPage:ProductList.Total.Of", "af") @pageCount @Translate("SmartPage:ProductList.Total.ProductsInTotal", "produkter")</span> 1791 } 1792 1793 </div> 1794 } 1795 1796 @functions 1797 { 1798 string getStringByKey(LoopItem i, string key) 1799 { 1800 return (i == null ? GetString(key) : i.GetString(key)); 1801 } 1802 1803 int getIntegerByKey(LoopItem i, string key) 1804 { 1805 return (i == null ? GetInteger(key) : i.GetInteger(key)); 1806 } 1807 1808 double getDoubleByKey(LoopItem i, string key) 1809 { 1810 return (i == null ? GetDouble(key) : i.GetDouble(key)); 1811 } 1812 1813 bool getBooleanByKey(LoopItem i, string key) 1814 { 1815 return (i == null ? GetBoolean(key) : i.GetBoolean(key)); 1816 } 1817 } 1818 1819 1820 @helper RenderProductPrice(bool showItemProp, LoopItem product = null) 1821 { 1822 var enableProductPrices = Converter.ToBoolean(Pageview.Area.Item["EnableProductPrices"]); 1823 if (enableProductPrices) 1824 { 1825 var productPrice = getStringByKey(product, "Ecom:Product.Price.PriceFormatted"); 1826 var productHasDiscount = getBooleanByKey(product, "Ecom:Product.HaveDiscount"); 1827 var productPriceDiscount = getStringByKey(product, "Ecom:Product.Discount.Price.PriceFormatted"); 1828 var productPriceItemProp = getDoubleByKey(product, "Ecom:Product.Discount.Price.PricePIP") / 100; 1829 var productCurrencyCode = getStringByKey(product, "Ecom:Product.Currency.Code"); 1830 string productStockItemPropSchema = (getDoubleByKey(product, "Ecom:Product.Stock") > 0 || getIntegerByKey(product, "Ecom:Product.Type") == 1) 1831 ? "http://schema.org/InStock" : "http://schema.org/OutOfStock"; 1832 1833 if (showItemProp) 1834 { 1835 <div class="prices" itemprop="offers" itemscope="" itemtype="http://schema.org/Offer"> 1836 <span class="price">@productPriceDiscount</span> 1837 @if (productHasDiscount) 1838 { 1839 <span class="price-old">@productPrice</span> 1840 } 1841 <span itemprop="price" class="display-none">@productPriceItemProp.ToString().Replace(",", ".")</span> 1842 <span itemprop="priceCurrency" class="display-none">@productCurrencyCode</span> 1843 <link itemprop="availability" href="@productStockItemPropSchema"> 1844 </div> 1845 } 1846 else 1847 { 1848 <div class="prices"> 1849 <span class="price">@productPriceDiscount</span> 1850 @if (productHasDiscount) 1851 { 1852 <span class="price-old">@productPrice</span> 1853 } 1854 </div> 1855 } 1856 } 1857 } 1858 1859 @helper RenderProductRibbon(LoopItem product = null) 1860 { 1861 var enableProductPrices = Converter.ToBoolean(Pageview.Area.Item["EnableProductPrices"]); 1862 if (enableProductPrices) 1863 { 1864 var productHasDiscount = getBooleanByKey(product, "Ecom:Product.HaveDiscount"); 1865 if (productHasDiscount) 1866 { 1867 <ul class="ribbons"> 1868 @if (productHasDiscount) 1869 { 1870 var productPriceDiscountTotalProcentage = getDoubleByKey(product, "Ecom:Product.Discount.TotalPercentWithVATFormatted"); 1871 1872 <li><span class="ribbon ribbon-price-savings">@Translate("Smartpage:Ecom.Product.Price.Discount.Save", "Spar") @productPriceDiscountTotalProcentage%</span></li> 1873 } 1874 </ul> 1875 } 1876 } 1877 } 1878 1879 @helper RenderProductSort() 1880 { 1881 string sortPriceUrl = Dynamicweb.Environment.Helpers.LinkHelper.ReplaceQueryString("sortby", "price"); 1882 string sortNameUrl = Dynamicweb.Environment.Helpers.LinkHelper.ReplaceQueryString("sortby", "productname"); 1883 string sortCreated = Dynamicweb.Environment.Helpers.LinkHelper.ReplaceQueryString("sortby", "created"); 1884 string priceQueryAsc = Dynamicweb.Environment.Helpers.LinkHelper.ReplaceQueryString(sortPriceUrl, "sortorder", "asc"); 1885 string priceQueryDesc = Dynamicweb.Environment.Helpers.LinkHelper.ReplaceQueryString(sortPriceUrl, "sortorder", "desc"); 1886 string nameQueryAsc = Dynamicweb.Environment.Helpers.LinkHelper.ReplaceQueryString(sortNameUrl, "sortorder", "asc"); 1887 string nameQueryDesc = Dynamicweb.Environment.Helpers.LinkHelper.ReplaceQueryString(sortNameUrl, "sortorder", "desc"); 1888 string createdQueryDesc = Dynamicweb.Environment.Helpers.LinkHelper.ReplaceQueryString(sortCreated, "sortorder", "desc"); 1889 1890 1891 1892 string sortByValue = Dynamicweb.Context.Current.Request.GetString("sortby"); 1893 string sortOrderValue = Dynamicweb.Context.Current.Request.GetString("sortorder"); 1894 1895 bool priceQueryAscSelected = Dynamicweb.Core.Converter.ToString(sortByValue).ToLower() == "price" && Dynamicweb.Core.Converter.ToString(sortOrderValue).ToLower() == "asc"; 1896 bool priceQueryDescSelected = Dynamicweb.Core.Converter.ToString(sortByValue).ToLower() == "price" && Dynamicweb.Core.Converter.ToString(sortOrderValue).ToLower() == "desc"; 1897 bool nameQueryAscSelected = Dynamicweb.Core.Converter.ToString(sortByValue).ToLower() == "productname" && Dynamicweb.Core.Converter.ToString(sortOrderValue).ToLower() == "asc"; 1898 bool nameQueryDescSelected = Dynamicweb.Core.Converter.ToString(sortByValue).ToLower() == "productname" && Dynamicweb.Core.Converter.ToString(sortOrderValue).ToLower() == "desc"; 1899 bool createdQueryDescSelected = Dynamicweb.Core.Converter.ToString(sortByValue).ToLower() == "created" && Dynamicweb.Core.Converter.ToString(sortOrderValue).ToLower() == "desc"; 1900 <div class="list-sort-wrapper"> 1901 <i class="fa fa-spinner fa-spin"></i> 1902 <select class="form-control js-sort-list"> 1903 <option value="">@Translate("SmartPage:Product.Sort.ChooseSort", "Sorter efter")</option> 1904 <option value="@priceQueryAsc" data-href="@priceQueryAsc" selected="@priceQueryAscSelected">@Translate("SmartPage:Product.Sort.PristAsc", "Pris stigende")</option> 1905 <option value="@priceQueryDesc" data-href="@priceQueryDesc" selected="@priceQueryDescSelected">@Translate("SmartPage:Product.Sort.PristDesc", "Pris faldende")</option> 1906 <option value="@nameQueryAsc" data-href="@nameQueryAsc" selected="@nameQueryAscSelected">@Translate("SmartPage:Product.Sort.NameA-z", "Navn (A-Z)")</option> 1907 <option value="@nameQueryDesc" data-href="@nameQueryDesc" selected="@nameQueryDescSelected">@Translate("SmartPage:Product.Sort.NameZ-A", "Navn (Z-A)")</option> 1908 <option value="@createdQueryDesc" data-href="@createdQueryDesc" selected="@createdQueryDescSelected">@Translate("SmartPage:Product.Sort.Newest", "Nyeste")</option> 1909 </select> 1910 </div> 1911 } 1912 1913 1914 @helper RenderProductStock(bool useDescriptionList, LoopItem i = null) 1915 { 1916 string stockState = Dynamicweb.Core.Converter.ToString(Pageview.Area.Item["StockState"]); 1917 if (string.IsNullOrWhiteSpace(stockState) || stockState == "none") 1918 { 1919 return; //If stockstate is set to "none" og not set - don't show stock 1920 } 1921 1922 double stock = getDoubleByKey(i, "Ecom:Product.Stock"); 1923 string image = getStringByKey(i, "Ecom:Product:Stock.Image.Clean"); 1924 string text = getStringByKey(i, "Ecom:Product:Stock.Text"); 1925 string imageUrl = "/admin/public/GetImage.ashx?Image=" + Dynamicweb.Core.Encoders.HtmlEncoder.UrlPathEncode(image) + "&amp;Compression=75&amp;width=12&amp;height=12"; 1926 1927 if (useDescriptionList) 1928 { 1929 <dt class="col-sm-8">@Translate("Smartpage:eCom.Product.StockStatus.Label.DescriptionList", "Lager")</dt> 1930 if (stockState == "quantity") 1931 { 1932 <dd class="col-sm-16">@stock</dd> 1933 } 1934 else if (stockState == "range") 1935 { 1936 <dd class="col-sm-16"> 1937 @if (!string.IsNullOrWhiteSpace(image)) 1938 { 1939 <img src="@imageUrl" alt="@text"> 1940 } 1941 <span>&nbsp;@text</span> 1942 </dd> 1943 } 1944 } 1945 else 1946 { 1947 if (stockState == "quantity") 1948 { 1949 <span><strong>@Translate("Smartpage:eCom.Product.StockStatus.Label", "Lager:") </strong>@stock</span> 1950 } 1951 else if (stockState == "range") 1952 { 1953 if (!string.IsNullOrEmpty(text)) 1954 { 1955 if (!string.IsNullOrWhiteSpace(image)) 1956 { 1957 <img src="@imageUrl" alt="@text"><span>&nbsp;@text</span> 1958 } 1959 else 1960 { 1961 <span><strong>@Translate("Smartpage:eCom.Product.StockStatus.Label", "Lager:") </strong>@text</span> 1962 } 1963 } 1964 else 1965 { 1966 <span>@Translate("Smartpage:eCom.Product.StockStatus.Unknown", "Ukendt")</span> 1967 } 1968 } 1969 } 1970 } 1971 1972 @helper RenderProductStockCheckModal(string Mode) 1973 { 1974 if (!string.IsNullOrWhiteSpace(Mode) && Mode != "ignore") 1975 { 1976 <div class="modal fade js-stock-check-modal-@Mode" id="stock-check-modal-@Mode" tabindex="-1" role="dialog" aria-labelledby="stock-check-label-@Mode" aria-hidden="true"> 1977 <div class="modal-dialog" role="document"> 1978 <div class="modal-content js-stock-check-@Mode"> 1979 <div class="modal-header"> 1980 <button type="button" class="close" data-dismiss="modal" aria-label="Close"> 1981 <span aria-hidden="true">&times;</span> 1982 </button> 1983 <h4 class="modal-title" id="stock-check-label-@Mode"> 1984 @if (Mode == "break") 1985 { 1986 @Translate("Smartpage:Ecom.Modal.StockCheck.Title.Stop", "Der er ikke nok på lager, prøv med et mindre antal.") 1987 } 1988 else if (Mode == "retry") 1989 { 1990 @Translate("Smartpage:Ecom.Modal.StockCheck.Title.Retry", "Der er ikke nok på lager, antallet er blevet justeret automatisk.") 1991 } 1992 </h4> 1993 </div> 1994 <div class="modal-body js-stock-check-body"> 1995 @if (Mode == "break") 1996 { 1997 <div> 1998 @Translate("Smartpage:Ecom.Modal.StockCheck.ProductsAffected.Stop", "Følgende produkter var ikke tilgængelige:") 1999 </div> 2000 <div class="js-stock-check-productname"></div> 2001 } 2002 else if (Mode == "retry") 2003 { 2004 <div> 2005 @Translate("Smartpage:Ecom.Modal.StockCheck.ProductsAffected.Retry", "Der er lagt følgende antal i kurven:") 2006 </div> 2007 <dl class="js-stock-check-productline"> 2008 <dt class="js-stock-check-productname"></dt> 2009 <dd class="js-stock-check-productname"></dd> 2010 </dl> 2011 } 2012 </div> 2013 <div class="modal-footer"> 2014 <button type="button" class="btn btn-secondary" data-dismiss="modal">@Translate("Smartpage:UserManagement.LoginModal.Button.Close", "Luk")</button> 2015 </div> 2016 </div> 2017 </div> 2018 </div> 2019 } 2020 } 2021 2022 @helper RenderProductCarousel(LoopItem i, bool useGroupLink = true, string pageId = null) 2023 { 2024 var id = i.GetValue("Ecom:Product.ID"); 2025 //var productLink = useGroupLink ? i.GetValue("Ecom:Product.LinkGroup.Clean") : i.GetValue("Ecom:Product.Link.Clean"); 2026 var projectsGroup = ""; 2027 if (i.GetString("Ecom:Product:Field.SpProductDivisionGroup") == "Architectural") 2028 { 2029 projectsGroup = "2426"; 2030 } 2031 else if (i.GetString("Ecom:Product:Field.SpProductDivisionGroup") == "Entertainment") 2032 { 2033 projectsGroup = "2410"; 2034 } 2035 2036 var groupId = !string.IsNullOrEmpty(GetString("Ecom:Product.PrimaryOrCurrentPageID")) ? GetString("Ecom:Product.PrimaryOrCurrentPageID") : projectsGroup; 2037 2038 var productLink = "Default.aspx?ID=" + groupId + "&ProductID=" + i.GetString("Ecom:Product.ID"); 2039 if (!string.IsNullOrEmpty(pageId)) 2040 { 2041 productLink = "/Default.aspx?Id=" + pageId; 2042 if (useGroupLink) 2043 { 2044 productLink += "&groupid=" + i.GetString("Ecom:Product.PrimaryOrFirstGroupID"); 2045 } 2046 productLink += "&ProductId=" + id; 2047 } 2048 string productName = i.GetString("Ecom:Product.Name"); 2049 string productImageClean = i.GetString("Ecom:Product:Field.SpPerfionMarketingProductPageImage1"); 2050 string productImage = string.IsNullOrEmpty(productImageClean) ? i.GetString("Ecom:Product.ImageLarge.Default.Clean") 2051 : "/admin/public/GetImage.ashx?Image=" + Dynamicweb.Core.Encoders.HtmlEncoder.UrlPathEncode(productImageClean) + "&amp;Compression=75&amp;crop=6&amp;width=400&amp;height=400"; 2052 var image = new Image(productImageClean); 2053 2054 bool service = i.GetInteger("Ecom:Product.Type") == 1; 2055 string productNameForAttribute = Dynamicweb.Core.Encoders.HtmlEncoder.HtmlEncode(productName); 2056 <div class="product-item"> 2057 <form method="post" class="js-ecom-product-form" autocomplete="off" data-disabled="false" data-check-stock='@Converter.ToString(Pageview.Area.Item["CheckStock"])'> 2058 <input type="hidden" name="CartCmd" value="add"> 2059 <input type="hidden" name="ProductID" value='@i.GetString("Ecom:Product.ID")'> 2060 <div class="productlist-content"> 2061 @if (image.Exists) 2062 { 2063 <a href="@productLink" title="@productNameForAttribute" class="productlist-image-link"> 2064 <img class="img-fluid" alt='@(image.GetMetaData("ImageAlt") ?? productNameForAttribute ?? Translate("Novicell:DefaultImageAltText", "SGM Light"))' src="@productImage" title="@productNameForAttribute"> 2065 </a> 2066 } 2067 <a href="@productLink" class="name" title="@productNameForAttribute"> 2068 <h5>@productNameForAttribute</h5> 2069 </a> 2070 <span>@i.GetString("Ecom:Product:Field.SpPerfionStrMarketingDataProductFolderProductPageSubheader")</span> 2071 </div> 2072 @RenderProductCarouselAddToCart(i) 2073 </form> 2074 </div> 2075 } 2076 2077 2078 @helper RenderProductRelatedProductsList(LoopItem i, bool useGroupLink = true, string pageId = null) 2079 { 2080 var id = i.GetValue("Ecom:Product.ID"); 2081 2082 var projectsGroup = ""; 2083 if (i.GetString("Ecom:Product:Field.SpProductDivisionGroup") == "Architectural") 2084 { 2085 projectsGroup = "2426"; 2086 } 2087 else if (i.GetString("Ecom:Product:Field.SpProductDivisionGroup") == "Entertainment") 2088 { 2089 projectsGroup = "2410"; 2090 } 2091 2092 var groupId = !string.IsNullOrEmpty(GetString("Ecom:Product.PrimaryOrCurrentPageID")) ? GetString("Ecom:Product.PrimaryOrCurrentPageID") : projectsGroup; 2093 2094 var productLink = "Default.aspx?ID=" + groupId + "&ProductID=" + i.GetString("Ecom:Product.ID"); 2095 if (!string.IsNullOrEmpty(pageId)) 2096 { 2097 productLink = "/Default.aspx?Id=" + pageId; 2098 if (useGroupLink) 2099 { 2100 productLink += "&groupid=" + i.GetString("Ecom:Product.PrimaryOrFirstGroupID"); 2101 } 2102 productLink += "&ProductId=" + id; 2103 } 2104 string productName = i.GetString("Ecom:Product.Name"); 2105 string productImageClean = i.GetString("Ecom:Product:Field.SpPerfionMarketingProductPageImage1"); 2106 string productImage = string.IsNullOrEmpty(productImageClean) ? i.GetString("Ecom:Product.ImageLarge.Default.Clean") 2107 : "/admin/public/GetImage.ashx?Image=" + Dynamicweb.Core.Encoders.HtmlEncoder.UrlPathEncode(productImageClean) + "&amp;Compression=75&amp;crop=6&amp;width=400&amp;height=400"; 2108 var image = new Image(productImageClean); 2109 2110 2111 string productNameForAttribute = Dynamicweb.Core.Encoders.HtmlEncoder.HtmlEncode(productName); 2112 <div class="col-xs-12 col-lg-6 text-xs-center co3-sgm-related-product product-item"> 2113 <form method="post" class="js-ecom-product-form" autocomplete="off" data-disabled="false" data-check-stock='@Converter.ToString(Pageview.Area.Item["CheckStock"])'> 2114 <input type="hidden" name="CartCmd" value="add"> 2115 <input type="hidden" name="ProductID" value='@i.GetString("Ecom:Product.ID")'> 2116 <a href="@productLink" class="productlist-content js-product-link"> 2117 <div class="e-productlist-item-image-container"> 2118 <div class="e-productlist-item-image-wrapper"> 2119 <img class="e-productlist-item-image hover-zoom" alt='@(image.GetMetaData("ImageAlt") ?? Translate("Novicell:DefaultImageAltText", "SGM LIGHT"))' src="@productImage" title="@productNameForAttribute"> 2120 </div> 2121 </div> 2122 <span class="co3-productlist-name" title="@productNameForAttribute"> 2123 @productNameForAttribute 2124 </span> 2125 <span class="d-block"><small>@i.GetString("Ecom:Product:Field.SpPerfionStrMarketingDataProductFolderProductPageSubheader")</small></span> 2126 @RenderProductRibbon(i) 2127 </a> 2128 @RenderProductRelatedProductsListAddToCart(i) 2129 </form> 2130 </div> 2131 } 2132 2133 2134 @helper RenderProductCarouselAddToCart(LoopItem i) 2135 { 2136 var enableCart = Converter.ToBoolean(Pageview.Area.Item["EnableCart"]); 2137 if (enableCart) 2138 { 2139 @*<button class="btn btn-border js-ecom-product-button"> 2140 <i class="js-ecom-product-button-spinner"></i> 2141 <span class="js-ecom-product-button-text">@Translate("Smartpage:Ecom.ProductList.Button.AddToList", "Add to List")</span> 2142 </button>*@ 2143 <div class="row no-gutters js-input-spinner add-to-cart"> 2144 2145 2146 <div class="col-xs-24"> 2147 <button class="btn btn-border btn-small js-ecom-product-button"> 2148 <i class="js-ecom-product-button-spinner"></i> 2149 <span class="js-ecom-product-button-text">@Translate("Smartpage:Ecom.ProductList.Button.AddToList", "Add to List")</span> 2150 </button> 2151 </div> 2152 2153 2154 </div> 2155 } 2156 } 2157 2158 @helper RenderProductRelatedProductsListAddToCart(LoopItem i) 2159 { 2160 var enableCart = Converter.ToBoolean(Pageview.Area.Item["EnableCart"]); 2161 if (enableCart) 2162 { 2163 <div class="js-input-spinner add-to-cart"> 2164 <button class="btn btn-block btn-small js-ecom-product-button"> 2165 <i class="js-ecom-product-button-spinner"></i> 2166 <span class="js-ecom-product-button-text">@Translate("Smartpage:Ecom.ProductList.Button.AddToQuote", "Add to quote list")</span> 2167 </button> 2168 </div> 2169 } 2170 } 2171 2172 2173 @helper RenderCollapseButton(string tag, string containerId) 2174 { 2175 <div class="collapse-button" data-toggle="collapse" data-target="#@containerId" aria-expanded="false" role="button" aria-controls="@containerId"> 2176 <p> 2177 <svg data-name="Layer 1" xmlns="http://www.w3.org/2000/svg" viewbox="0 0 30.84 30.84"> 2178 <path d="M15.42,30.84A15.42,15.42,0,1,1,30.84,15.42,15.44,15.44,0,0,1,15.42,30.84Zm0-29.34A13.92,13.92,0,1,0,29.34,15.42,13.93,13.93,0,0,0,15.42,1.5Z" transform="translate(0 0)"></path> 2179 <path d="M14.85,22.3h1.32V16.13h6.65V14.71H16.17V8.5H14.85v6.21H8v1.42h6.84Z" transform="translate(0 0)"></path> 2180 </svg> 2181 @tag 2182 </p> 2183 </div> 2184 } 2185 2186 2187 @helper RenderCollapseButtonTextUpdate(string textshow, string texthide, string containerId) 2188 { 2189 <div class="js-btn-collapse collapse-button" data-toggle="collapse" data-target="#@containerId" aria-expanded="false" role="button" aria-controls="@containerId" data-textshow="@textshow" data-texthide="@texthide"> 2190 2191 <p> 2192 <svg data-name="Layer 1" xmlns="http://www.w3.org/2000/svg" viewbox="0 0 30.84 30.84"> 2193 <path d="M15.42,30.84A15.42,15.42,0,1,1,30.84,15.42,15.44,15.44,0,0,1,15.42,30.84Zm0-29.34A13.92,13.92,0,1,0,29.34,15.42,13.93,13.93,0,0,0,15.42,1.5Z" transform="translate(0 0)"></path> 2194 <path d="M14.85,22.3h1.32V16.13h6.65V14.71H16.17V8.5H14.85v6.21H8v1.42h6.84Z" transform="translate(0 0)"></path> 2195 </svg> 2196 <span class="js-btn-collapse-text-@containerId">@textshow</span> 2197 </p> 2198 </div> 2199 2200 2201 @SnippetStart("JavaScript") 2202 <script> 2203 $('.js-btn-collapse[data-target="#@containerId"]') 2204 .click(function () { 2205 2206 $(this).toggleClass("active"); 2207 2208 var testshow = $('.js-btn-collapse[data-target="#@containerId"]').data('textshow'); 2209 var texthide = $('.js-btn-collapse[data-target="#@containerId"]').data('texthide'); 2210 2211 if ($(this).hasClass("active")) { 2212 $(this).find('.js-btn-collapse-text-'+'@containerId').text(texthide); 2213 } 2214 else { 2215 $(this).find('.js-btn-collapse-text-'+'@containerId').text(testshow); 2216 } 2217 2218 }); 2219 </script> 2220 @SnippetEnd("JavaScript") 2221 } 2222 2223 2224 @helper RenderSimpleStringCollapse(string tag, string containerId, bool img = false) 2225 { 2226 <div class="background gray collapse m-0 p-0" id="@containerId"> 2227 <div class="container text-xs-center pt-3 pb-3"> 2228 @if (img) 2229 { 2230 <img src="@(" iles")@tag"="" class="img-fluid" alt="SGM Light"> 2231 } 2232 else 2233 { 2234 @tag 2235 } 2236 2237 </div> 2238 </div> 2239 } 2240 2241 @helper RenderProductHr() 2242 { 2243 <div class="container text-xs-center"> 2244 <div class="row narrow"> 2245 <hr> 2246 </div> 2247 </div> 2248 } 2249 2250 @helper RenderProjectCarousel(LoopItem i, bool useGroupLink = true, string pageId = null) 2251 { 2252 string img = i.GetString("Smartpage:RelatedProjects.MarketingProjectPrimaryPhoto"); 2253 string image = !string.IsNullOrEmpty(img) ? "/admin/public/GetImage.ashx?Image=/files" + img + "&amp;Compression=75&amp;crop=6&amp;width=300&amp;height=200" : 2254 "/admin/public/GetImage.ashx?Image=/files/images/light-press2.jpg&amp;Compression=75&amp;crop=6&amp;width=300&amp;height=200"; 2255 string text = i.GetString("Smartpage:RelatedProjects.MarketingProjectTextPrimaryPhotoHeadline"); 2256 string textStripped = Regex.Replace(text, "<.*?>", string.Empty); 2257 if (pageId == null) 2258 { 2259 pageId = i.GetString("Smartpage:RelatedProjects.PageId"); 2260 } 2261 2262 var link = "Default.aspx?ID=" + pageId; 2263 string[] tags = i.GetString("ItemPublisher:Item.Tags").Split(','); 2264 <div class="project-item-carousel"> 2265 <div class="img-container"> 2266 <a class="d-block" href="@link"> 2267 <img src="@image" class="img-block img-fluid" alt="SGM LIGHT"> 2268 </a> 2269 </div> 2270 <div class="text-container"> 2271 @if (!string.IsNullOrEmpty(GetString("ItemPublisher:Item.Tags"))) 2272 { 2273 <ul class="tags"> 2274 @foreach (var tag in tags) 2275 { 2276 <li class="tag">@tag</li> 2277 } 2278 </ul> 2279 } 2280 @textStripped 2281 <a class="d-block" href="@link">@Translate("Smartpage:Press.Readmore", "Read more")</a> 2282 </div> 2283 2284 </div> 2285 } 2286 2287 2288 <div class="js-ecom-container" data-cart-id='@Pageview.Area.Item["CartMini"]'> 2289 @RenderBreadcrumbs() 2290 <div class="container"> 2291 <div class="row"> 2292 <div class="col-xs-24"> 2293 <h1 class="customer-center-header"> 2294 @Pageview.Page.MenuText 2295 </h1> 2296 </div> 2297 </div> 2298 <div class="row"> 2299 @{ 2300 var col = ""; 2301 } 2302 @if (isLoggedIn) 2303 { 2304 <div id="sidebar" class="hidden-md-down col-lg-6"> 2305 <ul class="list-unstyled user-list"> 2306 @GetValue("DwNavigation(navigationcustomercenter)") 2307 2308 <li class="nav-item"> 2309 <a class="" href='/Admin/Public/ExtranetLogoff.aspx?RedirectUrl=/'> 2310 @Translate("Smartpage:UserManagement.LoginModal.LoggedIn.SignOut", "Log ud") 2311 </a> 2312 </li> 2313 2314 </ul> 2315 </div> 2316 col = "col-lg-18"; 2317 } 2318 2319 <div class="col-xs-24 @col"> 2320 2321 <div class="js-ecom-page"> 2322 <div class="js-ecom-page-container" id="main-content">@GetValue("DwContent(maincontent)")</div> 2323 </div> 2324 </div> 2325 2326 </div> 2327 </div> 2328 </div> 2329 @RenderProductStockCheckModal(Dynamicweb.Core.Converter.ToString(Pageview.Area.Item["CheckStock"])) 2330 2331 </div> 2332 </div> 2333 </div> 2334 </div> 2335 <footer class="footer hidden-print"> 2336 2337 @RenderSocialMediaList("footer") 2338 <div class="footer-links hidden-print"> 2339 <div class="container"> 2340 <div class="row"> 2341 <div class="col-xs-24 col-md-8 col-lg-7 mb-2"> 2342 <strong>@GetValue("Item.Area.CompanyName")</strong> 2343 <ul class="list-unstyled"> 2344 <li class="d-block"> 2345 @GetValue("Item.Area.CompanyAddress") 2346 </li> 2347 <li class="d-block"> 2348 @GetValue("Item.Area.CompanyCountry") 2349 </li> 2350 <li class="d-block"> 2351 @Translate("Smartpage:Footer.Phone", "Telefon") 2352 <a href='tel:@GetValue("Item.Area.CompanyPhone")'> 2353 @GetValue("Item.Area.CompanyPhone") 2354 </a> 2355 </li> 2356 <li class="d-block"> 2357 @Translate("Smartpage:Footer.Mail", "Mail") 2358 <a href='mailto:@GetValue("Item.Area.CompanyEmail")'> 2359 @GetValue("Item.Area.CompanyEmail") 2360 </a> 2361 </li> 2362 2363 </ul> 2364 </div> 2365 <div class="col-xs-24 col-md-16 col-lg-9 mb-2"> 2366 <div class="row"> 2367 @RenderNavigationFooter() 2368 </div> 2369 </div> 2370 2371 </div> 2372 </div> 2373 </div> 2374 2375 2376 </footer> 2377 @*Modals*@ 2378 @RenderSnippet("Modal") 2379 @*@RenderUserManagementLoginModal()*@ 2380 2381 @*Newsletter Popbox*@ 2382 @*@RenderNewsletterPopbox()*@ 2383 2384 <button class="cookie-info-open" id="js-cookie-info-open"> 2385 @Translate("cookieInfoOpenText", "Cookies") 2386 </button> 2387 @*<section class="cookie-info" id="js-cookie-info"> 2388 <div class="cookie-info__content"> 2389 <p class="cookie-info__text">@GetString("Item.Area.CookieMessage")<a class="cookie-info__more" href="@cookieLink">@GetString("Item.Area.CookieReadMore")</a></p> 2390 2391 <button class="cookie-info__close button" id="js-cookie-info-close"> 2392 @GetString("Item.Area.CookieWarningClose") 2393 </button> 2394 </div> 2395 </section>*@ 2396 2397 @if (Dynamicweb.Core.Converter.ToBoolean(Pageview.Area.Item["DeveloperMode"])) 2398 { 2399 <script type="text/javascript" src="@designBaseUrl/Assets/Scripts/Plugins/jquery-3.1.1.js"></script> 2400 <script type="text/javascript" src="@designBaseUrl/Assets/Scripts/Plugins/tether.min.js"></script> 2401 <script type="text/javascript" src="@designBaseUrl/Assets/Scripts/Plugins/bootstrap.min.js"></script> 2402 <script type="text/javascript" src="@designBaseUrl/Assets/Scripts/Plugins/slick.min.js"></script> 2403 <script type="text/javascript" src="@designBaseUrl/Assets/Scripts/Plugins/lightbox.min.js"></script> 2404 <script type="text/javascript" src="@designBaseUrl/Assets/Scripts/Plugins/jquery.history.custom.js"></script> 2405 <script type="text/javascript" src="@designBaseUrl/Assets/Scripts/Plugins/dynamicweb.filters.js"></script> 2406 <script type="text/javascript" src="@designBaseUrl/Assets/Scripts/Plugins/levenshtein.js"></script> 2407 <script type="text/javascript" src="@designBaseUrl/Assets/Scripts/Plugins/bloodhound.js"></script> 2408 <script type="text/javascript" src="@designBaseUrl/Assets/Scripts/Plugins/handlebars-v4.0.5.js"></script> 2409 <script type="text/javascript" src="@designBaseUrl/Assets/Scripts/Plugins/typeahead.jquery.js"></script> 2410 <script type="text/javascript" src="@designBaseUrl/Assets/Scripts/Plugins/jquery.validate.js"></script> 2411 <script type="text/javascript" src="@designBaseUrl/Assets/Scripts/Plugins/additional-methods.js"></script> 2412 <script type="text/javascript" src="@designBaseUrl/Assets/Scripts/Plugins/select2.full.js"></script> 2413 <script type="text/javascript" src="@designBaseUrl/Assets/Scripts/Plugins/jquery.blockUI.js"></script> 2414 <script type="text/javascript" src="@designBaseUrl/Assets/Scripts/Plugins/sticky-kit.min.js"></script> 2415 <script type="text/javascript" src="@designBaseUrl/Assets/Scripts/Plugins/download.js"></script> 2416 <script type="text/javascript" src="@designBaseUrl/Assets/Scripts/Basic/Basic.js?v=@version"></script> 2417 <script type="text/javascript" src="@designBaseUrl/Assets/Scripts/Basic/Validation.js?v=@version"></script> 2418 <script type="text/javascript" src="@designBaseUrl/Assets/Scripts/Packages/Ecommerce.js?v=@version"></script> 2419 <script type="text/javascript" src="@designBaseUrl/Assets/Scripts/Packages/Navigation.js?v=@version"></script> 2420 <script type="text/javascript" src="@designBaseUrl/Assets/Scripts/Packages/UserManagement.js?v=@version"></script> 2421 <script type="text/javascript" src="@designBaseUrl/Assets/Scripts/Packages/ProductInstantSearch.js?v=@version"></script> 2422 <script type="text/javascript" src="@designBaseUrl/Assets/Scripts/Packages/FacebookPage.js?v=@version"></script> 2423 <script type="text/javascript" src="@designBaseUrl/Assets/Scripts/Custom/cookieinfo.js?v=@version"></script> 2424 <script type="text/javascript" src="@designBaseUrl/Assets/Scripts/Custom/Custom.js?v=@version"></script> 2425 2426 } 2427 else 2428 { 2429 2430 <script type="text/javascript" src="@designBaseUrl/Assets/Scripts/Dist/Main.min.js?v=1.1"></script> 2431 } 2432 2433 2434 2435 2436 <script> 2437 $(document).ready(function () { 2438 $('.js-fade-effect').delay(3000).addClass('active'); 2439 2440 $('.arrow-down-container.js-button-bounce').hide(); 2441 2442 $(".arrow-down-container.js-button-bounce").delay(4000).css({ opacity: 0.95 }).fadeIn(1500); 2443 2444 2445 }); 2446 2447 2448 2449 </script> 2450 2451 @RenderSnippet("JavaScript") 2452 2453 2454 </body> 2455 </html> 2456 2457