0
Din indkøbskurv

Opdaterer kurv

stk. a

-
+

Din kurv i alt (ex. fragt)

Handel videre

Gå til kassen
VISA/DK VISA/DK VISA/DK VISA/DK VISA/DK
Find forhandler

,

Tlf.

Se alle
Error executing template "Designs/Mobler2018/eCom/Product/Product.cshtml"
System.NullReferenceException: Object reference not set to an instance of an object.
   at CompiledRazorTemplates.Dynamic.RazorEngine_0363c4e2ed9f42f2902a6a3afd6df4cd.Execute() in D:\dynamicweb.net\Solutions\mobler.LIVE\Files\Templates\Designs\Mobler2018\eCom\Product\Product.cshtml:line 994
   at RazorEngine.Templating.TemplateBase.RazorEngine.Templating.ITemplate.Run(ExecuteContext context, TextWriter reader)
   at RazorEngine.Templating.RazorEngineService.RunCompile(ITemplateKey key, TextWriter writer, Type modelType, Object model, DynamicViewBag viewBag)
   at RazorEngine.Templating.RazorEngineServiceExtensions.<>c__DisplayClass16_0.b__0(TextWriter writer)
   at RazorEngine.Templating.RazorEngineServiceExtensions.WithWriter(Action`1 withWriter)
   at Dynamicweb.Rendering.Template.RenderRazorTemplate()

1 @using System.Web 2 @using Mobler.Website.CustomModules.MoblerHelpers 3 @using System.Text.RegularExpressions 4 @inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> 5 6 7 @{ 8 string shopname = MoblerHelpers.GetShopName(); 9 string SelectPlaceholder = Translate("ShopSelectPlaceholder", "Indtast by, postnummer eller adresse"); 10 var shopInfo = MoblerHelpers.ShopInfo(); 11 int ShopPageId = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetInt("ShopPageId"); 12 var AllShops = Firstweb.Custom.CustomCode.Frontend.Helpers.Shops.GetAllShops(ShopPageId); 13 int AjaxCartPageId = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetInt("AjaxCartPageId"); 14 int CustomersAlsoSawPageId = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetInt("CustomersAlsoSawPageId"); 15 string CartPage = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("CartPage"); 16 string VariantsEndpoint = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("VariantsUrl"); 17 string VariantDetailsEndpoint = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("VariantDetailsUrl"); 18 string BlackFridayTheme = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("BlackFridayTheme"); 19 string ProductID = GetString("Ecom:Product.ID"); 20 string GroupID = Firstweb.Custom.CustomCode.Frontend.Helpers.EcomGroups.GetProductDefaultShopGroupID(ProductID); //GetString("Ecom:Product.PrimaryOrFirstGroupID"); 21 string DefaultVariantID = GetString("Ecom:Product.DefaultVariantComboID"); 22 string ProductImage = MoblerHelpers.GetProductListImage(ProductID, DefaultVariantID); 23 string ProductName = GetString("Ecom:Product.Name"); 24 string ProductNumber = GetString("Ecom:Product.Number"); 25 string ProductCatalogLink = !String.IsNullOrEmpty(GetString("Ecom:Product:Field.ProductCatelog.Value.Clean")) ? GetString("Ecom:Product:Field.ProductCatelog.Value.Clean") : ""; 26 string VariantId = GetString("Ecom:Product.VariantID"); 27 string ShortDescription = GetString("Ecom:Product.ShortDescription"); 28 string LongDescription = GetString("Ecom:Product.LongDescription").Replace("||", "<br/>"); 29 string CurrentVariantName = GetString("Ecom:Product.SelectedVariantComboName"); 30 var FaqQuestions = MoblerHelpers.GetProductFAQs(ProductID, GroupID); 31 32 string MetaDescription = GetString("Ecom:Product.MetaDescription"); 33 34 if (string.IsNullOrEmpty(MetaDescription)) 35 { 36 MetaDescription = Mobler.Website.CustomCode.Frontend.Helpers.Text.GetFirstLine(LongDescription.Replace("<br/>", " ")); 37 } 38 else 39 { 40 MetaDescription = ""; //Meta data description bliver sat af DW, hvis dette felt er udfyldt, så vi skal ikke opsætte noget. 41 } 42 43 44 var RelatedBlogs = Firstweb.Custom.CustomCode.Frontend.Helpers.Blogs.GetBlogsRelatedToProduct(ProductID); 45 bool NewItem = GetBoolean("Ecom:Product:Field.NewItem"); 46 bool LowPrice = GetBoolean("Ecom:Product:Field.Splash3"); 47 48 49 Mobler.Website.CustomCode.Frontend.ProductsDisplayVariant productsDisplayVariant = Mobler.Website.CustomCode.Frontend.ProductsDisplayVariant.Instance(); 50 51 bool ForSale = !GetBoolean("Ecom:Product:Field.NotForSaleOnline"); 52 53 var MainProdNr = string.Empty; 54 var VariantNr = string.Empty; 55 string FirstImage = ""; 56 if (!string.IsNullOrWhiteSpace(ProductNumber)) 57 { 58 string[] MainProdSplit = ProductNumber.Split('_'); 59 60 61 62 if (MainProdSplit.Length > 1) 63 { 64 MainProdNr = MainProdSplit[0]; 65 VariantNr = MainProdSplit[1]; 66 } 67 else 68 { 69 MainProdNr = ProductNumber; 70 } 71 } 72 var Images = MoblerHelpers.GetProductImages(GetString("Ecom:Product.ID"), VariantId); 73 bool First = true; 74 bool FirstIndicator = true; 75 int IndicatorIncrementer = 0; 76 string ProductLink = GetString("Ecom:Product.Link.Clean"); 77 78 double ActualPrice = GetDouble("Ecom:Product.Price.Price"); 79 double spar = 0; 80 double price = 0; 81 double normalPrice = 0; 82 83 string priceFormatted = ""; 84 string sparFormatted = ""; 85 string normalPriceFormatted = ""; 86 87 string campaignColor = ""; 88 string campaignText = ""; 89 string campaignDate = ""; 90 91 bool CampaignActiveOnProduct = GetBoolean("CampaignModule:Product.CampaignActiveOnProduct"); 92 if (!CampaignActiveOnProduct) 93 { 94 price = ActualPrice; 95 priceFormatted = MoblerHelpers.formatPrice(price); 96 } 97 else 98 { 99 normalPrice = GetDouble("CampaignModule:Product.CampaignProduct.NormalPrice"); 100 normalPriceFormatted = GetString("CampaignModule:Product.CampaignProduct.NormalPrice.FormattedRetail"); 101 102 price = GetDouble("CampaignModule:Product.CampaignProduct.CampaignPrice"); 103 priceFormatted = GetString("CampaignModule:Product.CampaignProduct.CampaignPrice.FormattedRetail"); 104 105 spar = GetDouble("CampaignModule:Product.CampaignProduct.DiscountAmount"); 106 sparFormatted = GetString("CampaignModule:Product.CampaignProduct.DiscountAmount.FormattedRetail"); 107 108 campaignColor = GetString("CampaignModule:Product.Campaign.Color"); 109 campaignText = GetString("CampaignModule:Product.Campaign.Text"); 110 111 112 } 113 114 115 string DataLayerPrice = ActualPrice.ToString().Replace(".", "").Replace(",", "."); 116 System.Web.HttpContext.Current.Items["OverrideOgTags"] = true; 117 string OgImage = "https://mobler.dk" + Images.FirstOrDefault(); 118 119 string TrimmedTeaser = Firstweb.Custom.CustomCode.Frontend.Helpers.JSFormatting.TrimLinebreaks(ShortDescription); 120 string TrimmedName = Firstweb.Custom.CustomCode.Frontend.Helpers.JSFormatting.TrimLinebreaks(ProductName); 121 122 var ParentGroups = Firstweb.Custom.CustomCode.Frontend.Helpers.EcomGroups.getBreadCrumbGroupList(GroupID, true); 123 string ShowOnPageUrl = ""; 124 string GetCartEndpoint = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("GetCartJson"); 125 126 string QuickDeliveryColor = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("QuickDeliveryColor"); 127 string QuickDeliveryDescription = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("QuickDeliveryDescription"); 128 string NormalDeliveryDescription = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("NormalDeliveryDescription"); 129 string BrandName = GetString("Ecom:Product:Field.Maerkevarer.Value.Clean"); 130 string DeliveryTime = Translate("DeliveryTime." + BrandName, "Gns. leveringstid 3-12 dage"); 131 bool HideDelivery = DeliveryTime == "Skjul"; 132 string DeliveryColor = "#00AB5D"; 133 bool QuickDelivery = GetBoolean("Ecom:Product:Field.QuickDelivery.Value.Clean"); 134 string CustomDelivery = GetString("Ecom:Product:Field.CustomDeliveryTime.Value.Clean"); 135 if (QuickDelivery) 136 { 137 DeliveryColor = QuickDeliveryColor; 138 DeliveryTime = Translate("DeliveryTime.QuickDelivery", "Ekstra hurtig levering"); 139 } 140 else if (!String.IsNullOrEmpty(CustomDelivery)) 141 { 142 DeliveryTime = CustomDelivery; 143 } 144 string DeliveryFontWeightModifier = QuickDelivery ? "font-weight-bold" : ""; 145 bool DisplayAverageDeliveryTime = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetBoolean("DisplayAverageDeliveryTime"); 146 147 double CostPrice = GetDouble("Ecom:Product:Field.FirstwebCostPrice.Value.Raw"); 148 string DailyPriceBackgroundColor = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("AktuelDagsprisBackgroundColor"); 149 string DailyPriceTextColor = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("AktuelDagsprisTextColor"); 150 string EAN = GetString("Ecom:Product:Field.FirstEan.Value"); 151 152 string productionDescription = GetString("Ecom:Product:Field.FirstwebProductionDescription"); 153 } 154 155 156 @SnippetStart("ProductDetailsMeta") 157 @if (!string.IsNullOrEmpty(MetaDescription)) 158 { 159 <meta name="description" content="@MetaDescription" /> 160 } 161 @SnippetEnd("ProductDetailsMeta") 162 163 @SnippetStart("OgTags") 164 <meta property="og:type" content="product" /> 165 <meta property="og:description" content="@Regex.Replace(ShortDescription, "<.*?>", String.Empty)" /> 166 <meta property="og:image" content="@OgImage" /> 167 @SnippetEnd("OgTags") 168 169 @using Mobler.Website.CustomModules.MoblerHelpers 170 @using Dynamicweb.Ecommerce.Products 171 @inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> 172 173 @helper RenderProduct(LoopItem product) 174 { 175 string BlackFridayTheme = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("BlackFridayTheme"); 176 string CTAbg = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("SeProdukt_CTABaggrundsfarve"); 177 string CTAtextcolor = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("SeProdukt_CTATekstfarve"); 178 string ProductID = product.GetString("Ecom:Product.ID"); 179 string ProductNumber = product.GetString("Ecom:Product.Number"); 180 string DefaultVariantID = product.GetString("Ecom:Product.DefaultVariantComboID"); 181 string VariantId = product.GetString("Ecom:Product.VariantID"); 182 if (String.IsNullOrEmpty(VariantId)) { 183 VariantId = DefaultVariantID; 184 } 185 var Images = MoblerHelpers.GetProductImages(ProductID, VariantId); 186 string ProductImage = string.Format("/Admin/Public/GetImage.ashx?Image={0}&Width=260&height=200&Format=png&Crop=5&resolution=50", Images.FirstOrDefault()); //MoblerHelpers.GetProductListImageWithMainImage(ProductID, ProductNumber); 187 string ProductName = product.GetString("Ecom:Product.Name"); 188 189 bool NewItem = product.GetBoolean("Ecom:Product:Field.NewItem"); 190 bool LowPrice = product.GetBoolean("Ecom:Product:Field.Splash3"); 191 double CostPrice = product.GetDouble("Ecom:Product:Field.FirstwebCostPrice.Value.Raw"); 192 string ShortDescription = product.GetString("Ecom:Product.ShortDescription"); 193 string PriceSaving = product.GetString("Ecom:Product:Field.Spar.Value"); 194 string ProductLink = product.GetString("Ecom:Product.Link.Clean"); 195 196 if (!String.IsNullOrEmpty(VariantId)) { 197 ProductLink = ProductLink + "&variantid=" + VariantId; 198 } 199 200 201 /* 202 double DiscountedPrice = product.GetDouble("Ecom:Product.Discount.Price.Price"); 203 double ActualPrice = product.GetDouble("Ecom:Product.Price.Price"); 204 var TotalDiscount = product.GetDouble("Ecom:Product.Discount.TotalAmount.Price"); 205 double spar = 0; 206 double price = 0; 207 if (!product.GetBoolean("Ecom:Product:Field.Splash3.Value") && !product.GetBoolean("Ecom:Product:Field.Offer.Value")) 208 { 209 if (DiscountedPrice < ActualPrice) 210 { 211 spar = TotalDiscount; 212 price = DiscountedPrice; 213 } 214 else 215 { 216 price = ActualPrice; 217 } 218 } 219 else 220 { 221 spar = product.GetDouble("Ecom:Product:Field.Spar.Value.Clean"); 222 price = product.GetDouble("Ecom:Product.Price.Price"); 223 } 224 double OriginalPrice = spar + price; 225 */ 226 227 double ActualPrice = product.GetDouble("Ecom:Product.Price.Price"); 228 double spar = 0; 229 double price = 0; 230 double normalPrice = 0; 231 232 string priceFormatted = ""; 233 string sparFormatted = ""; 234 string normalPriceFormatted = ""; 235 236 string campaignColor = ""; 237 string campaignText = ""; 238 string campaignDate = ""; 239 240 bool CampaignActiveOnProduct = product.GetBoolean("CampaignModule:Product.CampaignActiveOnProduct"); 241 if (!CampaignActiveOnProduct) 242 { 243 price = ActualPrice; 244 priceFormatted = MoblerHelpers.formatPrice(price); 245 } 246 else 247 { 248 normalPrice = product.GetDouble("CampaignModule:Product.CampaignProduct.NormalPrice"); 249 normalPriceFormatted = product.GetString("CampaignModule:Product.CampaignProduct.NormalPrice.FormattedRetail"); 250 251 price = product.GetDouble("CampaignModule:Product.CampaignProduct.CampaignPrice"); 252 priceFormatted = product.GetString("CampaignModule:Product.CampaignProduct.CampaignPrice.FormattedRetail"); 253 254 spar = product.GetDouble("CampaignModule:Product.CampaignProduct.DiscountAmount"); 255 sparFormatted = product.GetString("CampaignModule:Product.CampaignProduct.DiscountAmount.FormattedRetail"); 256 257 campaignColor = product.GetString("CampaignModule:Product.Campaign.Color"); 258 campaignText = product.GetString("CampaignModule:Product.Campaign.Text"); 259 } 260 261 262 263 var languageId = product.GetString("Ecom:Product.LanguageID"); 264 var dwProduct = Dynamicweb.Ecommerce.Services.Products.GetProductById(ProductID, VariantId, languageId); 265 var VariantCombinations = dwProduct.VariantCombinations.ToList().Where(v => v.GetProduct(languageId).Number != VariantId); 266 bool ManyVariants = VariantCombinations.Count() > 3; 267 if (ManyVariants) 268 { 269 VariantCombinations = VariantCombinations.Take(3).ToList(); 270 } 271 272 string BrandName = product.GetString("Ecom:Product:Field.Maerkevarer.Value.Clean"); 273 bool QuickDelivery = product.GetBoolean("Ecom:Product:Field.QuickDelivery.Value.Clean"); 274 string DeliveryTime = Translate("DeliveryTime." + BrandName, "Gns. leveringstid 3-12 dage"); 275 string DeliveryColor = "#00AB5D"; 276 if (QuickDelivery) { 277 DeliveryTime = Translate("DeliveryTime.QuickDelivery", "Ekstra hurtig levering"); 278 DeliveryColor = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("QuickDeliveryColor"); 279 } 280 281 <div class="col-11 col-sm-6 col-lg-3 mt-3 mx-auto mx-sm-0 mb-3 js-product-list-item"> 282 <a href="@ProductLink" class="product-list-product box-shadow px-3 pt-3 pb-5 h-100 d-flex flex-column align-items-center mb-3 overflow-hidden"> 283 <div class="d-flex flex-column align-items-center"> 284 <div class="img-container"> 285 <img class="js-product-image-@ProductID" src="@ProductImage" alt="@ProductName" /> 286 </div> 287 </div> 288 <h3 class="mt-2 mb-0 fs2 text-center mw-100 font-weight-bold">@ProductName</h3> 289 <div class="fs0 color-subtle text-center mw-100 mb-0 product-description">@ShortDescription</div> 290 <div class="d-flex flex-wrap justify-content-center w-100 align-content-end flex-fill"> 291 <p class="color-subtle m-0 fs0 w-100 text-center"> 292 @if (!string.IsNullOrWhiteSpace(product.GetString("Ecom:Product:Field.dybdeint.Value.Clean"))) 293 { 294 if (product.GetString("Ecom:Product:Field.dybdeint.Value.Clean") != "0") 295 { 296 <span>D/L: @product.GetValue("Ecom:Product:Field.dybdeint.Value.Clean")</span> 297 } 298 } 299 @if (!string.IsNullOrWhiteSpace(product.GetString("Ecom:Product:Field.hoejdeint.Value.Clean"))) 300 { 301 if (product.GetString("Ecom:Product:Field.hoejdeint.Value.Clean") != "0") 302 { 303 <span>H: @product.GetValue("Ecom:Product:Field.hoejdeint.Value.Clean")</span> 304 } 305 } 306 @if (!string.IsNullOrWhiteSpace(product.GetString("Ecom:Product:Field.breddeint.Value.Clean"))) 307 { 308 if (product.GetString("Ecom:Product:Field.breddeint.Value.Clean") != "0") 309 { 310 <span>B: @product.GetValue("Ecom:Product:Field.breddeint.Value.Clean")</span> 311 } 312 } 313 </p> 314 @if (QuickDelivery) 315 { 316 <div class="delivery-information my-2 w-100 justify-content-center"> 317 <svg class="delivery-icon mr-2" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1" id="Capa_1" fill="@DeliveryColor" x="0px" y="0px" width="20px" height="20px" viewBox="0 0 612 612" style="enable-background:new 0 0 612 612;" xml:space="preserve"> 318 <g> 319 <g> 320 <path d="M226.764,375.35c-28.249,0-51.078,22.91-51.078,51.16c0,28.166,22.829,51.078,51.078,51.078s51.078-22.912,51.078-51.078 C277.841,398.26,255.013,375.35,226.764,375.35z M226.764,452.049c-14.125,0-25.54-11.498-25.54-25.541 c0-14.123,11.415-25.539,25.54-25.539c14.124,0,25.539,11.416,25.539,25.539C252.302,440.551,240.888,452.049,226.764,452.049z M612,337.561v54.541c0,13.605-11.029,24.635-24.636,24.635h-26.36c-4.763-32.684-32.929-57.812-66.927-57.812 c-33.914,0-62.082,25.129-66.845,57.812H293.625c-4.763-32.684-32.93-57.812-66.845-57.812c-33.915,0-62.082,25.129-66.844,57.812 h-33.012c-13.606,0-24.635-11.029-24.635-24.635v-54.541H612L612,337.561z M494.143,375.35c-28.249,0-51.16,22.91-51.16,51.16 c0,28.166,22.912,51.078,51.16,51.078c28.166,0,51.077-22.912,51.077-51.078C545.22,398.26,522.309,375.35,494.143,375.35z M494.143,452.049c-14.125,0-25.539-11.498-25.539-25.541c0-14.123,11.414-25.539,25.539-25.539 c14.042,0,25.539,11.416,25.539,25.539C519.682,440.551,508.185,452.049,494.143,452.049z M602.293,282.637l-96.817-95.751 c-6.159-6.077-14.453-9.526-23.076-9.526h-48.86v-18.313c0-13.631-11.004-24.635-24.635-24.635H126.907 c-13.55,0-24.635,11.005-24.635,24.635v3.86L2.3,174.429l177.146,23.068L0,215.323l178.814,25.423L0,256.25l102.278,19.29 l-0.007,48.403h509.712v-17.985C611.983,297.171,608.452,288.796,602.293,282.637z M560.084,285.839h-93.697 c-2.135,0-3.86-1.724-3.86-3.859v-72.347c0-2.135,1.725-3.86,3.86-3.86h17.82c0.985,0,1.971,0.411,2.71,1.068l75.796,72.347 C565.257,281.569,563.532,285.839,560.084,285.839z" /> 321 322 </g> 323 </g> 324 </svg> 325 <p class="delivery-text font-weight-bold">@DeliveryTime - <span class="text-underline cursor-pointer" data-bind="click: ToggleQuickDeliveryInfo" style="color: @DeliveryColor">@Translate("Product.DeliveryInfo.ReadmoreText", "L&aelig;s mere")</span></p> 326 </div> 327 } 328 <p class="fs5 my-0 d-flex align-items-center font-weight-bold"> 329 @if (VariantCombinations.Count() > 0) 330 { 331 <span class="font-weight-semibold fs0 mr-2">@Translate("ProductPrice.From", "Fra")</span> 332 } 333 @priceFormatted 334 </p> 335 @if (CostPrice > 0) 336 { 337 string DailyPriceBackgroundColor = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("AktuelDagsprisBackgroundColor"); 338 string DailyPriceTextColor = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("AktuelDagsprisTextColor"); 339 string EAN = product.GetString("Ecom:Product:Field.FirstEan.Value"); 340 var PriceShapePrices = Firstweb.Custom.CustomCode.Frontend.Helpers.PriceShapeHelpers.GetProductPrice(ProductNumber, EAN); 341 342 <div class="discount-splash price-shape" style="background-color: @DailyPriceBackgroundColor"><p class="m-0" style="color: @DailyPriceTextColor;">@Translate("ProductDailyPriceSplash", "Dagspris")</p></div> 343 if (PriceShapePrices != null) 344 { 345 if (price < PriceShapePrices.MoblerPrice) 346 { 347 <div class="d-flex w-100 mb-2"> 348 @if (VariantCombinations.Count() > 0) 349 { 350 <p class="color-black-w-opacity fs0 m-0 text-uppercase">@Translate("PriceRecommendPriceFrom", "Vejl. pris fra") @MoblerHelpers.formatPrice(PriceShapePrices.MoblerPrice)</p> 351 } 352 else 353 { 354 <p class="color-black-w-opacity fs0 m-0 text-uppercase">@Translate("PriceRecommendPrice", "Vejl. pris") @MoblerHelpers.formatPrice(PriceShapePrices.MoblerPrice)</p> 355 } 356 </div> 357 } 358 } 359 360 } 361 else if (spar > 0) 362 { 363 if (BlackFridayTheme == "True") 364 { 365 <div class="discount-splash bf-bg-black bf-color-white"><p class="m-0 font-weight-bold">@Translate("ProductOffer", "Tilbud")</p></div> 366 } 367 else 368 { 369 <div class="discount-splash"><p class="m-0 font-weight-bold">@Translate("ProductOffer", "Tilbud")</p></div> 370 } 371 <div class="d-flex justify-content-between w-100 mb-2"> 372 <p class="color-black-w-opacity fs0 m-0 text-uppercase">@Translate("PriceBefore", "Før") @normalPriceFormatted</p> 373 <p class="bg-discount fs0 text-uppercase m-0 px-2 font-weight-bold">@Translate("PriceSaving", "Spar") @sparFormatted</p> 374 </div> 375 } 376 else if (NewItem) 377 { 378 <div class="discount-splash new-item"><p class="m-0 font-weight-bold">@Translate("ProductNew", "Nyhed")</p></div> 379 } 380 else if (LowPrice) 381 { 382 <div class="discount-splash low-price"><p class="m-0 font-weight-bold">@Translate("ProductLowPrice", "Fast lavpris")</p></div> 383 } 384 </div> 385 @if (VariantCombinations.Count() > 0) 386 { 387 <div class="w-100 row align-items-center justify-content-center"> 388 @foreach (var Variant in VariantCombinations) 389 { 390 string VariantLink = product.GetString("Ecom:Product.Link.Clean") + "&variantid=" + Variant.VariantId; 391 string imageProductDetails = string.Format("/Admin/Public/GetImage.ashx?Image={0}&Width=60&height=50&Format=png&Crop=5&resolution=50", MoblerHelpers.GetProductImages(ProductID, Variant.VariantId).First()); 392 string ImageLarge = imageProductDetails.Replace("&Width=60&height=50", "&Width=260&height=200"); 393 <div class="w-25 p-1 mb-2 d-block" data-bind="previewVariant: { variantImage: '@ImageLarge', currentImage: '.js-product-image-@ProductID', originalImage: '@ProductImage', link: '@VariantLink' }"> 394 <img class="img-fluid" src="@imageProductDetails" /> 395 </div> 396 } 397 @if (ManyVariants) 398 { 399 <div class="w-25 p-1 mb-2 d-flex justify-content-center align-items-center fs2"> 400 <span class="see-more-dots"> 401 <i class="fas fa-ellipsis-h"></i> 402 </span> 403 </div> 404 } 405 </div> 406 <div class="variant-price-disclaimer">@Translate("VariantPriceDisclaimer", "Prisen kan variere efter materialevalg")</div> 407 } 408 @if (BlackFridayTheme == "True") 409 { 410 <div class="bf-bg-black product-cta d-block text-center fs2 font-weight-bold">@Translate("GoToProduct", "Se produkt")</div> 411 } else { 412 <div class="bg-brand product-cta d-block text-center fs2 font-weight-bold" style="background-color: @CTAbg;color: @CTAtextcolor;">@Translate("GoToProduct", "Se produkt")</div> 413 } 414 415 </a> 416 417 </div> 418 } 419 420 @helper RenderWideOffer(LoopItem product) 421 { 422 string ProductID = product.GetString("Ecom:Product.ID"); 423 string DefaultVariantID = product.GetString("Ecom:Product.DefaultVariantComboID"); 424 string ProductImage = MoblerHelpers.GetProductListImage(ProductID, DefaultVariantID).Replace("Width=260&height=200", "Width=400&height=230"); 425 string ProductName = product.GetString("Ecom:Product.Name"); 426 string ShortDescription = product.GetString("Ecom:Product.ShortDescription"); 427 string PriceSaving = product.GetString("Ecom:Product:Field.Spar.Value"); 428 string ProductLink = product.GetString("Ecom:Product.Link.Clean"); 429 double DiscountedPrice = product.GetDouble("Ecom:Product.Discount.Price.Price"); 430 double ActualPrice = product.GetDouble("Ecom:Product.Price.Price"); 431 var TotalDiscount = product.GetDouble("Ecom:Product.Discount.TotalAmount.Price"); 432 double spar = 0; 433 double price = 0; 434 if (!product.GetBoolean("Ecom:Product:Field.Splash3.Value") && !product.GetBoolean("Ecom:Product:Field.Offer.Value")) 435 { 436 if (DiscountedPrice < ActualPrice) 437 { 438 spar = TotalDiscount; 439 price = DiscountedPrice; 440 } 441 else 442 { 443 price = ActualPrice; 444 } 445 } 446 else 447 { 448 spar = product.GetDouble("Ecom:Product:Field.Spar.Value.Clean"); 449 price = product.GetDouble("Ecom:Product.Price.Price"); 450 } 451 double OriginalPrice = spar + price; 452 453 <div class="col-12 bg-white box-shadow-grey border-radius-bottom-8px mt-5"> 454 <div class="row"> 455 456 <div class="col-12 col-md-4 d-flex align-items-center justify-content-center p-2"> 457 @if (spar > 0) 458 { 459 <div class="discount-splash d-md-none"> 460 <p class="m-0"> 461 @Translate("ProductOffer", "Tilbud") 462 </p> 463 </div> 464 } 465 <a href="@ProductLink"> 466 <img class="img-fluid" src="@ProductImage" alt="@ProductName" /> 467 </a> 468 </div> 469 <div class="col-12 col-md-8 px-0 pt-4 pb-0 pb-sm-3 d-flex flex-column align-items-center 470 justify-content-end"> 471 @if (spar > 0) 472 { 473 <div class="discount-splash d-none d-md-flex"> 474 <p class="m-0"> 475 @Translate("ProductOffer", "Tilbud") 476 </p> 477 </div> 478 } 479 <div class="px-2"> 480 <h1 class="wide-offer--title mw-100 word-break mt-3 mt-sm-0 font-weight-bold text-uppercase text-center">@ProductName</h1> 481 <div class="wide-offer--subtitle word-break text-center color-dark-grey rte-content"> 482 @ShortDescription 483 </div> 484 </div> 485 <div class="mt-2 fs5 font-weight-bold"> 486 @MoblerHelpers.formatPrice(price) 487 </div> 488 <div class="d-flex flex-column justify-content-center align-items-center flex-sm-row w-100"> 489 490 @if (spar > 0) 491 { 492 <div class="d-flex mb-2 mb-sm-0 justify-content-center"> 493 <p class="color-black-w-opacity m-0 mr-5 p-1 text-uppercase"> 494 @Translate("PriceBefore", "Før") @MoblerHelpers.formatPrice(OriginalPrice) 495 </p> 496 <p class="bg-discount font-weight-bold mb-0 mr-sm-5 px-2 p-1 text-uppercase"> 497 @Translate("PriceSaving", "Spar") @MoblerHelpers.formatPrice(spar) 498 </p> 499 </div> 500 } 501 <a class="wide-offer--button btn btn-primary pl-3 pr-3" href="@ProductLink"> 502 @Translate("GoToProduct", "Se produkt") 503 </a> 504 </div> 505 </div> 506 507 </div> 508 </div> 509 510 } 511 512 @helper Render2ColOffer(LoopItem product) 513 { 514 string ProductID = product.GetString("Ecom:Product.ID"); 515 string DefaultVariantID = product.GetString("Ecom:Product.DefaultVariantComboID"); 516 string ProductImage = MoblerHelpers.GetProductListImage(ProductID, DefaultVariantID).Replace("Width=260", "Width=450").Replace("height=200", "Height=400"); 517 string ProductName = product.GetString("Ecom:Product.Name"); 518 string ShortDescription = product.GetString("Ecom:Product.ShortDescription"); 519 string PriceSaving = product.GetString("Ecom:Product:Field.Spar.Value"); 520 string ProductLink = product.GetString("Ecom:Product.Link.Clean"); 521 double DiscountedPrice = product.GetDouble("Ecom:Product.Discount.Price.Price"); 522 double ActualPrice = product.GetDouble("Ecom:Product.Price.Price"); 523 var TotalDiscount = product.GetDouble("Ecom:Product.Discount.TotalAmount.Price"); 524 double spar = 0; 525 double price = 0; 526 if (!product.GetBoolean("Ecom:Product:Field.Splash3.Value") && !product.GetBoolean("Ecom:Product:Field.Offer.Value")) 527 { 528 if (DiscountedPrice < ActualPrice) 529 { 530 spar = TotalDiscount; 531 price = DiscountedPrice; 532 } 533 else 534 { 535 price = ActualPrice; 536 } 537 } 538 else 539 { 540 spar = product.GetDouble("Ecom:Product:Field.Spar.Value.Clean"); 541 price = product.GetDouble("Ecom:Product.Price.Price"); 542 } 543 double OriginalPrice = spar + price; 544 545 546 <div class="col-12 col-md-6 mt-5"> 547 <a href="@ProductLink" class="offer-2col box-shadow-large border-radius-bottom-10px w-100 h-100 d-flex flex-column color-black"> 548 <div class="d-flex align-items-center justify-content-center offer-2col--img-container"> 549 <img class="img-fluid" src="@ProductImage" alt="@ProductName"> 550 @if (spar > 0) 551 { 552 <div class="discount-splash"> 553 <p class="m-0"> 554 @Translate("ProductOffer", "Tilbud") 555 </p> 556 </div> 557 } 558 </div> 559 <div> 560 <h1 class="offer-2col--title pl-3 pr-3 mb-3 text-center color-black text-uppercase"> 561 @ProductName 562 </h1> 563 <div class="offer-2col--subtitle color-dark-grey pl-3 pr-3 my-3 my-md-5 text-center"> 564 @ShortDescription 565 </div> 566 </div> 567 <div class="d-flex flex-wrap flex-fill justify-content-center align-items-end"> 568 <div class="d-flex flex-wrap flex-fill justify-content-center align-items-end"> 569 <p class="offer-2col--price mb-3 text-center font-weight-bold color-black w-100"> 570 @MoblerHelpers.formatPrice(price) 571 </p> 572 @if (spar > 0) 573 { 574 <div class="d-flex justify-content-center mb-3"> 575 <span class="offer-2col--pricebefore color-black-w-opacity mr-5 p-1 text-uppercase"> 576 @Translate("PriceBefore", "Før") @MoblerHelpers.formatPrice(OriginalPrice) 577 </span> 578 <span class="offer-2col--pricesave color-black bg-discount font-weight-bold p-1 text-uppercase"> 579 @Translate("PriceSaving", "Spar") @MoblerHelpers.formatPrice(spar) 580 </span> 581 </div> 582 } 583 584 <div class="w-100"> 585 <div class="offer-2col--button btn btn-primary p-3 border-radius-bottom-10px w-100 mb-sm-0 font-weight-bold"> 586 @Translate("GoToProduct", "Se produkt") 587 </div> 588 </div> 589 </div> 590 </div> 591 </a> 592 </div> 593 } 594 595 @using Mobler.Website.CustomModules.MoblerHelpers 596 @inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> 597 598 @helper RenderBlogTeaser(Firstweb.Custom.CustomCode.Frontend.Helpers.Blog Blog) 599 { 600 string CleanLink = Blog.Link.Replace("default.aspx?id", "Default.aspx?Id"); 601 <div class="col-12 col-md-4 px-0 px-md-3 mb-4"> 602 <a href="@CleanLink" class="blog d-block"> 603 <div class="image" style="background-image:url('@Blog.Image')"> 604 <img class="d-none" src="@Blog.Image" alt="Alternate Text" /> 605 </div> 606 <div class="text"> 607 <div class="positioning"> 608 <h4 class="col-10 col-md-9 px-2 pt-3 bg-white font-weight-bold text-center mx-auto">@Blog.Header</h4> 609 <p class="text-center color-subtle">@Blog.Date</p> 610 <p class="text-center font-weight-bold m-0 color-primary">@Translate("BlogReadMore", "L&aelig;s mere her")</p> 611 </div> 612 </div> 613 </a> 614 </div> 615 } 616 617 @helper RenderLargeBlogTeaser(Firstweb.Custom.CustomCode.Frontend.Helpers.Blog Blog, string ImagePosition) 618 { 619 string ImageClass = ImagePosition == "Left" ? "" : "offset-md-4"; 620 string TextClass = ImagePosition == "Left" ? "" : "left"; 621 string Image = "/Admin/Public/GetImage.ashx?Image=" + Blog.Image + "&Height=400&Crop=0"; 622 string CleanLink = Blog.Link.Replace("default.aspx?id", "Default.aspx?Id"); 623 <div class="col-12 blog"> 624 <div class="row"> 625 <div class="col-12 col-md-8 px-0 px-md-3 @ImageClass"> 626 <div class="image-container" style="background-image:url('@Image')"> 627 <img class="img-fluid" src="@Image" alt="@Blog.Header" /> 628 </div> 629 </div> 630 <div class="col-12 col-md-6 text-container mb-5 mb-md-0 @TextClass"> 631 <div class="text bg-white p-3"> 632 <div> 633 <h4>@Blog.Header</h4> 634 @Blog.Teaser 635 </div> 636 <a class="font-weight-bold" href="@CleanLink">@Translate("BlogReadMore", "L&aelig;s mere her")</a> 637 </div> 638 </div> 639 </div> 640 </div> 641 } 642 643 @helper RenderLatestBlogsTeasers() 644 { 645 var LatestBlogs = Firstweb.Custom.CustomCode.Frontend.Helpers.Blogs.GetLatestBlogs(); 646 foreach (var Blog in LatestBlogs) 647 { 648 @RenderBlogTeaser(Blog) 649 } 650 } 651 652 653 <div class="container pt-3 d-none d-md-block"> 654 655 <div class="bread"> 656 <p class="color-subtle">@Translate("Breadcrumb.CurrentPage", "Her er du:")</p> 657 <p class="bread-item color-subtle"> 658 <a href="/"> 659 @Translate("Breadcrumb.Frontpage", "Forside") 660 </a> 661 </p> 662 @foreach (var Group in ParentGroups) 663 { 664 <p class="bread-item color-subtle"> 665 @if (Group == ParentGroups.First()) 666 { 667 @Group.Name 668 ShowOnPageUrl = Group.ProductGroupFieldValues.GetProductGroupFieldValue("FirstwebGroupPrimaryPage").Value.ToString(); 669 } 670 else 671 { 672 <a href="/@ShowOnPageUrl&GroupId=@Group.Id"> 673 @Group.Name 674 </a> 675 } 676 </p> 677 } 678 679 <p class="active color-subtle">@ProductName</p> 680 </div> 681 682 </div> 683 684 <div class="container mt-3 mb-5 product-details position-relative" data-bind="viewModel: 'ProductViewModel'"> 685 686 <div class="d-none" data-bind="setInitValue: { observable: CartPageId, value: '@AjaxCartPageId' }"></div> 687 <div class="d-none" data-bind="setInitValue: { observable: MiniCart, value: '.js-mini-cart-lines' }"></div> 688 <div class="d-none" data-bind="setInitValue: { observable: CartCount, value: '.js-cart-count' }"></div> 689 <div class="d-none" data-bind="setInitValue: { observable: CustomersAlsoSawLines, value: '.js-customers-also-saw-lines' }"></div> 690 <div class="d-none" data-bind="setInitValue: { observable: CustomersAlsoSawPage, value: '@CustomersAlsoSawPageId' }"></div> 691 <div class="d-none" data-bind="setInitValue: { observable: MainProductId, value: '@ProductID' }"></div> 692 <div class="d-none" data-bind="setInitValue: { observable: VariantsEndpoint, value: '@VariantsEndpoint' }"></div> 693 <div class="d-none" data-bind="setInitValue: { observable: VariantDetailsEndpoint, value: '@VariantDetailsEndpoint' }"></div> 694 <div class="d-none" data-bind="setInitValue: { observable: TeaserText, value: '@TrimmedTeaser' }"></div> 695 <div class="d-none" data-bind="setInitValue: { observable: ProductName, value: '@TrimmedName' }"></div> 696 <div class="d-none" data-bind="setInitValue: { observable: ProductNumber, value: '@ProductNumber' }"></div> 697 <div class="d-none" data-bind="setInitValue: { observable: VariantId, value: '@VariantId' }"></div> 698 <div class="d-none" data-bind="setInitValue: { observable: Price, value: '@priceFormatted' }"></div> 699 <div class="d-none js-update-cart" data-bind="setInitValue: { observable: CartEndpoint, value: '@GetCartEndpoint' }, click: GetCart"></div> 700 701 <div id="blueimp-gallery" class="blueimp-gallery"> 702 <div class="slides"></div> 703 <h3 class="title"></h3> 704 <a class="prev">‹</a> 705 <a class="next">›</a> 706 <a class="close">×</a> 707 <a class="play-pause"></a> 708 <ol class="indicator"></ol> 709 </div> 710 711 <div class="modal fade video-modal" id="videoModal" tabindex="-1" role="dialog" aria-labelledby="video-modal" aria-hidden="true"> 712 <div class="modal-dialog modal-dialog-centered" role="document"> 713 <div class="modal-content"> 714 <div class="modal-body"> 715 <div id="player"></div> 716 </div> 717 </div> 718 </div> 719 </div> 720 721 <div class="add-to-cart-overlay" data-bind="css: { 'd-block': ProcessingAjax }"> 722 <p class="fs4 m-0 color-white">@Translate("ProductAjaxAddingToCart", "Tilf&oslash;jer til kurv") <i class="fa fa-spinner fa-spin ml-3 fs5"></i></p> 723 </div> 724 725 <div class="add-to-cart-overlay" data-bind="css: { 'd-block': ProcessingVariantDetailsAjax }"> 726 <p class="fs4 m-0 color-white">@Translate("ProductAjaxGettingVariant", "Henter variant") <i class="fa fa-spinner fa-spin ml-3 fs5"></i></p> 727 </div> 728 729 <div class="delivery-information-popup" data-bind="css: { 'd-flex': DeliveryInfoOpen }, click: ToggleDeliveryInfo"> 730 <div class="description-content bg-white px-3 py-4 px-lg-4 position-relative" data-bind="click: OpenDeliveryInfo, clickBubble: false"> 731 <div class="modal-closer-custom" data-bind="click: ToggleDeliveryInfo, clickBubble: false"> 732 <img src="/Files/Templates/Designs/Mobler2018/assets/img/icons/close.svg" /> 733 </div> 734 @if (QuickDelivery) 735 { 736 <div> 737 @QuickDeliveryDescription 738 </div> 739 } 740 else if (DisplayAverageDeliveryTime) 741 { 742 <div> 743 @NormalDeliveryDescription 744 </div> 745 } 746 </div> 747 </div> 748 749 @if (CostPrice > 0) 750 { 751 string PriceDescription = Firstweb.Custom.CustomCode.Frontend.Helpers.AreaItems.GetString("DagsprisDescription"); 752 <div class="delivery-information-popup" data-bind="css: { 'd-flex': PriceInfoOpen }, click: TogglePriceInfo"> 753 <div class="description-content bg-white px-3 py-4 px-lg-4 position-relative" data-bind="click: OpenPriceInfo, clickBubble: false"> 754 <div class="modal-closer-custom" data-bind="click: TogglePriceInfo, clickBubble: false"> 755 <img src="/Files/Templates/Designs/Mobler2018/assets/img/icons/close.svg" /> 756 </div> 757 <div> 758 @PriceDescription 759 </div> 760 </div> 761 </div> 762 } 763 764 765 <h1 class="header mb-4" data-bind="text: ProductName">@ProductName</h1> 766 767 <div class="d-flex flex-wrap"> 768 769 <div class="image-container position-relative overflow-hidden"> 770 771 <div class="discount-splash unimportant-hidden" data-bind="css: { 'd-flex': SplashType() == 1 }"><p class="m-0">@Translate("ProductOffer", "Tilbud")</p></div> 772 <div class="discount-splash unimportant-hidden new-item" data-bind="css: { 'd-flex': SplashType() == 2 }"><p class="m-0">@Translate("ProductNew", "Nyhed")</p></div> 773 <div class="discount-splash unimportant-hidden low-price" data-bind="css: { 'd-flex': SplashType() == 3 }"><p class="m-0">@Translate("ProductLowPrice", "Fast lavpris")</p></div> 774 <div class="discount-splash unimportant-hidden price-shape" data-bind="css: { 'd-flex': SplashType() == 4 }" style="background-color: @DailyPriceBackgroundColor;"><p class="m-0" style="color: @DailyPriceTextColor;">@Translate("ProductDailyPriceSplash", "Dagspris")</p></div> 775 776 <div id="imageSlider" class="carousel slide" data-ride="carousel"> 777 <div class="carousel-inner align-items-center" data-bind="if: Images().length == 0"> 778 779 @foreach (var Image in Images) 780 { 781 if (First) 782 { 783 <a href="/Admin/Public/GetImage.ashx?Image=@Image&width=2000" class="mb-3 mb-lg-0 carousel-item active" data-gallery> 784 <img class="product-image main-image" src="/Admin/Public/GetImage.ashx?Image=@Image&width=950&height=500&crop=5" alt="@ProductName" /> 785 </a> 786 First = false; 787 FirstImage = "/Admin/Public/GetImage.ashx?Image=" + Image + "&width=950&height=500&crop=5"; 788 } 789 else 790 { 791 <a href="/Admin/Public/GetImage.ashx?Image=@Image&width=2000" class="mb-3 mb-lg-0 carousel-item" data-gallery> 792 <img class="product-image main-image" src="/Admin/Public/GetImage.ashx?Image=@Image&width=950&height=500&crop=5" alt="@ProductName" /> 793 </a> 794 } 795 796 } 797 798 </div> 799 <div class="carousel-inner align-items-center d-flex js-ko-carousel" data-bind="foreach: Images()"> 800 801 <a data-bind="attr: { href: '/Admin/Public/GetImage.ashx?Image=' + $data + '&width=2000' }" class="mb-3 mb-lg-0 carousel-item active" data-gallery> 802 <img class="product-image main-image" data-bind="attr: { src: '/Admin/Public/GetImage.ashx?Image=' + $data + '&width=950&height=500&crop=5' }" /> 803 </a> 804 805 </div> 806 </div> 807 808 @if (Images.Count > 1) 809 { 810 <div class="row small-gutter carousel-row" data-bind="css: { 'd-none': Images().length > 0 }"> 811 812 @foreach (var Image in Images) 813 { 814 if (FirstIndicator) 815 { 816 <div data-target="#imageSlider" data-slide-to="@IndicatorIncrementer" class="col-4 mt-lg-3 cursor-pointer active"> 817 <div class="secondary-image"> 818 <img class="product-image" src="/Admin/Public/GetImage.ashx?Image=@Image&width=400&height=230&crop=5" alt="@ProductName" /> 819 </div> 820 </div> 821 FirstIndicator = false; 822 } 823 else 824 { 825 <div data-target="#imageSlider" data-slide-to="@IndicatorIncrementer" class="col-4 mt-lg-3 cursor-pointer"> 826 <div class="secondary-image"> 827 <img class="product-image" src="/Admin/Public/GetImage.ashx?Image=@Image&width=400&height=230&crop=5" alt="@ProductName" /> 828 </div> 829 </div> 830 } 831 IndicatorIncrementer++; 832 } 833 834 @if (!String.IsNullOrEmpty(GetString("Ecom:Product:Field.VideoKlip.Value"))) 835 { 836 string BackgroundSize = !String.IsNullOrEmpty(GetString("Ecom:Product:Field.VideoBillede.Value.Clean")) ? "cover" : "contain"; 837 string OverlayImage = !String.IsNullOrEmpty(GetString("Ecom:Product:Field.VideoBillede.Value.Clean")) ? GetString("Ecom:Product:Field.VideoBillede.Value.Clean") : FirstImage; 838 <div class="youtube-video-container mt-lg-3" data-bind="youtubeVideo: { videoId: '@GetString("Ecom:Product:Field.VideoKlip.Value")', overlayId: 'js-video-overlay', playerId: 'player' }"> 839 <div id="js-video-overlay" class="video-overlay pointer" style="background-image:url('@OverlayImage');background-size: @BackgroundSize;"> 840 <div class="visual-overlay d-flex flex-column justify-content-center align-items-center h-100 w-100"> 841 <img src="/Files/Templates/Designs/Mobler2018/assets/img/icons/Play.svg" /> 842 <p class="mt-3 mb-0 color-white">@Translate("Product.WatchVideo", "Se video")</p> 843 </div> 844 </div> 845 </div> 846 } 847 848 </div> 849 850 <div class="row small-gutter carousel-row unimportant-hidden" data-bind="css: { 'd-flex': Images().length > 0 }, foreach: Images()"> 851 852 <!-- ko if: $index() == 0 --> 853 <div data-target="#imageSlider" class="col-4 mt-lg-3 cursor-pointer active" data-bind="click: $parent.ChangeSlide.bind($data, $index())"> 854 <div class="secondary-image"> 855 <img class="product-image" data-bind="attr: { src: '/Admin/Public/GetImage.ashx?Image=' + $data + '&width=400&height=230&crop=5' }" alt="@ProductName" /> 856 </div> 857 </div> 858 <!-- /ko --> 859 <!-- ko if: $index() != 0 --> 860 <div data-target="#imageSlider" class="col-4 mt-lg-3 cursor-pointer" data-bind="click: $parent.ChangeSlide.bind($data, $index())"> 861 <div class="secondary-image"> 862 <img class="product-image" data-bind="attr: { src: '/Admin/Public/GetImage.ashx?Image=' + $data + '&width=400&height=230&crop=5' }" alt="@ProductName" /> 863 </div> 864 </div> 865 <!-- /ko --> 866 867 </div> 868 } 869 870 </div> 871 872 <div class="pl-lg-4 description-container d-flex flex-wrap flex-column mt-3 mt-lg-0 position-relative"> 873 874 <div class="mb-2">@ShortDescription</div> 875 876 <div class="w-100"><p class="color-primary pointer mb-2" data-bind="scrollToElement: { target: '#js-full-description' }">@Translate("ProductReadFullDescription", "L&aelig;s hele beskrivelsen")</p></div> 877 878 <div class="w-100"> 879 <p class="color-subtle m-0">@Translate("ProductProductNumber", "Produktnummer:") <span data-bind="text: ProductNumber">@ProductNumber</span></p> 880 <p class="color-subtle m-0"> 881 @if (!string.IsNullOrWhiteSpace(GetString("Ecom:Product:Field.dybdeint.Value.Clean"))) 882 { 883 if (GetString("Ecom:Product:Field.dybdeint.Value.Clean") != "0") 884 { 885 <span>D/L: @GetValue("Ecom:Product:Field.dybdeint.Value.Clean")</span> 886 } 887 } 888 @if (!string.IsNullOrWhiteSpace(GetString("Ecom:Product:Field.hoejdeint.Value.Clean"))) 889 { 890 if (GetString("Ecom:Product:Field.hoejdeint.Value.Clean") != "0") 891 { 892 <span>H: @GetValue("Ecom:Product:Field.hoejdeint.Value.Clean")</span> 893 } 894 } 895 @if (!string.IsNullOrWhiteSpace(GetString("Ecom:Product:Field.breddeint.Value.Clean"))) 896 { 897 if (GetString("Ecom:Product:Field.breddeint.Value.Clean") != "0") 898 { 899 <span>B: @GetValue("Ecom:Product:Field.breddeint.Value.Clean")</span> 900 } 901 } 902 </p> 903 </div> 904 905 @if ((QuickDelivery || DisplayAverageDeliveryTime) && !HideDelivery) 906 { 907 <div class="w-100 mt-3"> 908 909 <div class="delivery-information"> 910 <svg class="delivery-icon mr-2" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1" id="Capa_1" fill="@DeliveryColor" x="0px" y="0px" width="30px" height="30px" viewBox="0 0 612 612" style="enable-background:new 0 0 612 612;" xml:space="preserve"> 911 <g> 912 <g> 913 <path d="M226.764,375.35c-28.249,0-51.078,22.91-51.078,51.16c0,28.166,22.829,51.078,51.078,51.078s51.078-22.912,51.078-51.078 C277.841,398.26,255.013,375.35,226.764,375.35z M226.764,452.049c-14.125,0-25.54-11.498-25.54-25.541 c0-14.123,11.415-25.539,25.54-25.539c14.124,0,25.539,11.416,25.539,25.539C252.302,440.551,240.888,452.049,226.764,452.049z M612,337.561v54.541c0,13.605-11.029,24.635-24.636,24.635h-26.36c-4.763-32.684-32.929-57.812-66.927-57.812 c-33.914,0-62.082,25.129-66.845,57.812H293.625c-4.763-32.684-32.93-57.812-66.845-57.812c-33.915,0-62.082,25.129-66.844,57.812 h-33.012c-13.606,0-24.635-11.029-24.635-24.635v-54.541H612L612,337.561z M494.143,375.35c-28.249,0-51.16,22.91-51.16,51.16 c0,28.166,22.912,51.078,51.16,51.078c28.166,0,51.077-22.912,51.077-51.078C545.22,398.26,522.309,375.35,494.143,375.35z M494.143,452.049c-14.125,0-25.539-11.498-25.539-25.541c0-14.123,11.414-25.539,25.539-25.539 c14.042,0,25.539,11.416,25.539,25.539C519.682,440.551,508.185,452.049,494.143,452.049z M602.293,282.637l-96.817-95.751 c-6.159-6.077-14.453-9.526-23.076-9.526h-48.86v-18.313c0-13.631-11.004-24.635-24.635-24.635H126.907 c-13.55,0-24.635,11.005-24.635,24.635v3.86L2.3,174.429l177.146,23.068L0,215.323l178.814,25.423L0,256.25l102.278,19.29 l-0.007,48.403h509.712v-17.985C611.983,297.171,608.452,288.796,602.293,282.637z M560.084,285.839h-93.697 c-2.135,0-3.86-1.724-3.86-3.859v-72.347c0-2.135,1.725-3.86,3.86-3.86h17.82c0.985,0,1.971,0.411,2.71,1.068l75.796,72.347 C565.257,281.569,563.532,285.839,560.084,285.839z" /> 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 </g> 930 </g> 931 </svg> 932 <p class="delivery-text @DeliveryFontWeightModifier">@DeliveryTime - <a href="#" class="text-underline" data-bind="click: ToggleDeliveryInfo" style="color: @DeliveryColor">@Translate("Product.DeliveryInfo.ReadmoreText", "L&aelig;s mere")</a></p> 933 </div> 934 935 </div> 936 } 937 938 @if (CostPrice > 0) 939 { 940 <div class="w-100 mt-3"> 941 942 <div class="delivery-information"> 943 <div class="live-price-animation"></div> 944 <p class="delivery-text">@Translate("Product.PriceInfo.RecommendedPriceInfo", "Aktuel dagspris - ")<a href="#" class="text-underline" data-bind="click: TogglePriceInfo">@Translate("Product.PriceInfo.RecommendedPriceLink", "L&aelig;s mere")</a></p> 945 </div> 946 947 </div> 948 } 949 950 951 <div class="w-100"> 952 @if (GetBoolean("Ecom:Product:Field.Farvevarianter1.Value")) 953 { 954 <img class="img-fluid mb-3 mt-5" src="/Files/Images/Farver/farver1.png" /> 955 <p class="mb-0">@Translate("ProductColor1Text", "F&aring;s i flere forskellige varianter og moduler, bes&oslash;g dit lokale M&oslash;blér bolighus og f&aring; vejledning til design af din sofa.")</p> 956 } 957 else if (GetBoolean("Ecom:Product:Field.Farvevarianter2.Value")) 958 { 959 <img class="img-fluid mb-3 mt-5" src="/Files/Images/Farver/farver2.png" /> 960 <p class="mb-0">@Translate("ProductColor2Text", "Farve 2 hj&aelig;lpetekst")</p> 961 } 962 else if (GetBoolean("Ecom:Product:Field.Farvevarianter3.Value")) 963 { 964 <img class="img-fluid mb-3 mt-5" src="/Files/Images/Farver/farver3.png" /> 965 <p class="mb-0">@Translate("ProductColor3Text", "Farve 3 hj&aelig;lpetekst")</p> 966 } 967 else if (GetBoolean("Ecom:Product:Field.Farvevarianter4.Value")) 968 { 969 <img class="img-fluid mb-3 mt-5" src="/Files/Images/Farver/farver4.png" /> 970 <p class="mb-0">@Translate("ProductColor4Text", "Farve 4 hj&aelig;lpetekst")</p> 971 } 972 else if (GetBoolean("Ecom:Product:Field.Farvevarianter5.Value")) 973 { 974 <img class="img-fluid mb-3 mt-5" src="/Files/Images/Farver/farver5.png" /> 975 <p class="mb-0">@Translate("ProductColor5Text", "Farve 5 hj&aelig;lpetekst")</p> 976 } 977 </div> 978 @if (GetLoop("VariantCombinations").Count > 0) 979 { 980 var VariantGroupsWithMultipleOptions = GetLoop("VariantGroups").Where(x => x.GetLoop("VariantAvailableOptions").Count > 1); 981 int VariantGroupCount = VariantGroupsWithMultipleOptions.Count(); 982 int VariantCombinationsCount = GetLoop("VariantCombinations").Count; 983 int PossibleVariantCombinations = 1; 984 foreach (var VG in GetLoop("VariantGroups")) 985 { 986 PossibleVariantCombinations *= VG.GetLoop("VariantAvailableOptions").Count; 987 } 988 if (VariantGroupCount == 1) 989 { 990 var RelevantVariantGroup = VariantGroupsWithMultipleOptions.FirstOrDefault(); 991 var SelectedVariant = RelevantVariantGroup.GetLoop("VariantAvailableOptions").Where(x => x.GetBoolean("Ecom:VariantOption.Selected")).FirstOrDefault(); 992 <div class="position-relative"> 993 <div class="variant-dropdown p-2 box-shadow mt-3 d-flex justify-content-between align-items-center pointer js-variant-dropdown"> 994 <p class="m-0"><span class="font-weight-bold">@RelevantVariantGroup.GetString("Ecom:VariantGroup.Label")</span> - <span data-bind="text: SelectedVariantOption0">@SelectedVariant.GetString("Ecom:VariantOption.Name")</span></p> 995 <i class="fas fa-chevron-down"></i> 996 </div> 997 <div class="variant-options bg-white"> 998 @foreach (var Variant in RelevantVariantGroup.GetLoop("VariantAvailableOptions")) 999 { 1000 var VariantCombination = GetLoop("VariantCombinations").Where(x => x.GetString("Ecom:VariantCombination.VariantID").ToString().Contains(Variant.GetString("Ecom:VariantOption.ID"))).FirstOrDefault(); 1001 string VariantName = Variant.GetString("Ecom:VariantOption.Name"); 1002 string VariantIdentifier = Variant.GetString("Ecom:VariantOption.ID"); 1003 string VariantLink = VariantCombination.GetString("Ecom:VariantCombination.Link.Clean"); 1004 string VariantPreview = String.Empty; 1005 var ObservableToSet = "SelectedVariantOption0"; 1006 var ObservableToSetId = "SelectedVariantOptionId0"; 1007 bool ShowPreview = RelevantVariantGroup.GetString("Ecom:VariantGroup.Name").ToString().ToLower().Contains("farve") || RelevantVariantGroup.GetString("Ecom:VariantGroup.Name").ToString().ToLower().Contains("materiale") ? true : false; 1008 if (!String.IsNullOrEmpty(Variant.GetString("Ecom:VariantOption.ImgSmall.Clean")) && ShowPreview) 1009 { 1010 if (Variant.GetString("Ecom:VariantOption.ImgSmall.Clean").StartsWith("#")) 1011 { 1012 VariantPreview = "style= \"background-color: " + Variant.GetString("Ecom:VariantOption.ImgSmall.Clean") + ";\""; 1013 } 1014 else 1015 { 1016 VariantPreview = "style=\"background-image: url('" + Variant.GetString("Ecom:VariantOption.ImgSmall.Clean") + "');\""; 1017 } 1018 } 1019 <div class="option pointer color-primary d-flex w-100 p-2 bg-grey" data-bind="click: UpdateVariantAndSetObservable.bind($data, '@VariantIdentifier', @ObservableToSet, '@VariantName', @ObservableToSetId)"> 1020 @if (!String.IsNullOrEmpty(VariantPreview)) 1021 { 1022 <span class="option-preview mr-2" @VariantPreview></span> 1023 } 1024 <span>@VariantName</span> 1025 </div> 1026 <div class="d-none" data-bind="setInitValue: { observable: @ObservableToSet, value: '@SelectedVariant.GetString("Ecom:VariantOption.Name")' }"></div> 1027 <div class="d-none" data-bind="setInitValue: { observable: @ObservableToSetId, value: '@SelectedVariant.GetString("Ecom:VariantOption.ID")' }"></div> 1028 1029 } 1030 </div> 1031 </div> 1032 } 1033 else if (PossibleVariantCombinations == VariantCombinationsCount) 1034 { 1035 Dictionary<string, string> CurrentlySelectedVariantOptions = new Dictionary<string, string>(); 1036 foreach (var VG in GetLoop("VariantGroups")) 1037 { 1038 foreach (var VO in VG.GetLoop("VariantAvailableOptions").Where(x => x.GetBoolean("Ecom:VariantOption.Selected"))) 1039 { 1040 CurrentlySelectedVariantOptions.Add(VG.GetString("Ecom:VariantGroup.Name"), VO.GetString("Ecom:VariantOption.ID")); 1041 } 1042 } 1043 int VGLoopCounter = 0; 1044 foreach (var VG in GetLoop("VariantGroups")) 1045 { 1046 List<LoopItem> RelevantVariantCombinations = new List<LoopItem>(); 1047 var VariantCombinationLink = GetLoop("VariantCombinations"); 1048 var SelectedVariant = VG.GetLoop("VariantAvailableOptions").Where(x => x.GetBoolean("Ecom:VariantOption.Selected")).FirstOrDefault(); 1049 var ObservableToSet = "SelectedVariantOption" + VGLoopCounter.ToString(); 1050 var ObservableToSetId = "SelectedVariantOptionId" + VGLoopCounter.ToString(); 1051 VGLoopCounter++; 1052 foreach (var VC in VariantCombinationLink) 1053 { 1054 var Add = true; 1055 foreach (var KVP in CurrentlySelectedVariantOptions.Where(s => s.Key != VG.GetString("Ecom:VariantGroup.Name"))) 1056 { 1057 if (!VC.GetString("Ecom:VariantCombination.VariantID").ToString().Contains(KVP.Value)) 1058 { 1059 Add = false; 1060 } 1061 } 1062 if (Add) 1063 { 1064 RelevantVariantCombinations.Add(VC); 1065 } 1066 } 1067 <div class="d-none" data-bind="setInitValue: { observable: @ObservableToSet, value: '@SelectedVariant.GetString("Ecom:VariantOption.Name")' }"></div> 1068 <div class="d-none" data-bind="setInitValue: { observable: @ObservableToSetId, value: '@SelectedVariant.GetString("Ecom:VariantOption.ID")' }"></div> 1069 1070 1071 <div class="position-relative"> 1072 <div class="variant-dropdown p-2 box-shadow mt-3 d-flex justify-content-between align-items-center pointer js-variant-dropdown"> 1073 <p class="m-0"><span class="font-weight-bold">@VG.GetString("Ecom:VariantGroup.Label")</span> - <span data-bind="text: @ObservableToSet">@SelectedVariant.GetString("Ecom:VariantOption.Name")</span></p> 1074 <i class="fas fa-chevron-down"></i> 1075 </div> 1076 <div class="variant-options bg-white"> 1077 @foreach (var VO in VG.GetLoop("VariantAvailableOptions")) 1078 { 1079 var VariantCombination = RelevantVariantCombinations.Where(vc => vc.GetString("Ecom:VariantCombination.VariantID").ToString().Contains(VO.GetString("Ecom:VariantOption.ID"))).FirstOrDefault(); 1080 string VariantLink = VariantCombination.GetString("Ecom:VariantCombination.Link.Clean"); 1081 string VariandOptionId = VariantCombination.GetString("Ecom:VariantCombination.VariantID"); 1082 string VariantPreview = String.Empty; 1083 string VOName = VO.GetString("Ecom:VariantOption.Name"); 1084 string VOId = VO.GetString("Ecom:VariantOption.ID"); 1085 bool ShowPreview = VG.GetString("Ecom:VariantGroup.Name").ToString().ToLower().Contains("farve") || VG.GetString("Ecom:VariantGroup.Name").ToString().ToLower().Contains("materiale") ? true : false; 1086 if (!String.IsNullOrEmpty(VO.GetString("Ecom:VariantOption.ImgSmall.Clean")) && ShowPreview) 1087 { 1088 if (VO.GetString("Ecom:VariantOption.ImgSmall.Clean").StartsWith("#")) 1089 { 1090 VariantPreview = "style= \"background-color: " + VO.GetString("Ecom:VariantOption.ImgSmall.Clean") + ";\""; 1091 } 1092 else 1093 { 1094 VariantPreview = "style=\"background-image: url('" + VO.GetString("Ecom:VariantOption.ImgSmall.Clean") + "');\""; 1095 } 1096 } 1097 <div class="option d-flex w-100 p-2 bg-grey color-primary pointer" data-bind="click: UpdateVariantAndSetObservable.bind($data, '@VOId', @ObservableToSet, '@VOName', @ObservableToSetId)"> 1098 @if (!String.IsNullOrEmpty(VariantPreview)) 1099 { 1100 <span class="option-preview mr-2" @VariantPreview></span> 1101 } 1102 @VOName 1103 </div> 1104 } 1105 </div> 1106 </div> 1107 } 1108 } 1109 else if (GetLoop("VariantGroups").Where(x => x.GetString("Ecom:VariantGroup.Name").ToString().ToLower().Contains("farve")).Count() > 0 && GetLoop("VariantGroups").Where(x => x.GetString("Ecom:VariantGroup.Name").ToString().ToLower().Contains("materiale")).Count() > 0) 1110 { 1111 <div class="mt-3"> 1112 <p class="mb-1">@Translate("CurrentDesignName", "Valgte design: ")</p> 1113 <p class="font-weight-bold">@CurrentVariantName</p> 1114 </div> 1115 <div class="d-flex"> 1116 <div class="btn btn-primary" data-bind="click: ToggleVariantPicker">@Translate("ChooseNewDesign", "V&aelig;lg design")</div> 1117 </div> 1118 } 1119 else 1120 { 1121 var SelectedVariant = GetLoop("VariantCombinations").Where(x => x.GetBoolean("Ecom:VariantCombination.Selected")).FirstOrDefault(); 1122 var SelectedVariantName = SelectedVariant.GetString("Ecom:VariantCombination.VariantText"); 1123 var SelectedVariantId = SelectedVariant.GetString("Ecom:VariantOption.ID"); 1124 <div class="d-none" data-bind="setInitValue: { observable: SelectedVariantOption0, value: '@SelectedVariantName' }"></div> 1125 <div class="d-none" data-bind="setInitValue: { observable: SelectedVariantOptionId0, value: '@SelectedVariantId' }"></div> 1126 <div class="position-relative"> 1127 <div class="variant-dropdown p-2 box-shadow mt-3 d-flex justify-content-between align-items-center pointer js-variant-dropdown"> 1128 <p class="m-0"><span class="font-weight-bold">@Translate("FallbackVariantsText", "VARIANTER")</span> - <span data-bind="text: SelectedVariantOption0">@SelectedVariantName</span></p> 1129 <i class="fas fa-chevron-down"></i> 1130 </div> 1131 <div class="variant-options bg-white"> 1132 @foreach (var Variant in GetLoop("VariantCombinations")) 1133 { 1134 string VariantName = Variant.GetString("Ecom:VariantCombination.VariantText"); 1135 string VariantLink = Variant.GetString("Ecom:VariantCombination.Link.Clean"); 1136 string VCId = Variant.GetString("Ecom:Product.VariantID"); 1137 <div class="option color-primary pointer d-block p-2 bg-grey" data-bind="click: UpdateVariantAndSetObservable.bind($data, '@VCId', SelectedVariantOption0, '@VariantName', SelectedVariantOptionId0)">@VariantName</div> 1138 } 1139 </div> 1140 </div> 1141 } 1142 1143 } 1144 1145 <div class="row align-items-end f-grow-1"> 1146 <div class="col-10 offset-1 col-sm-12 offset-sm-0 d-flex justify-content-center justify-content-lg-start"> 1147 1148 <div class="mt-5 d-flex flex-wrap flex-column justify-content-end"> 1149 @if (CostPrice > 0) 1150 { 1151 var PriceShapePrices = Firstweb.Custom.CustomCode.Frontend.Helpers.PriceShapeHelpers.GetProductPrice(ProductNumber, EAN); 1152 <div class="d-none" data-bind="setInitValue: { observable: SplashType, value: 4 }"></div> 1153 if (PriceShapePrices != null && price < PriceShapePrices.MoblerPrice) 1154 { 1155 <div class="d-none" data-bind="setInitValue: { observable: ShowSaving, value: true }"></div> 1156 <div class="d-none" data-bind="setInitValue: { observable: CostPrice, value: '@MoblerHelpers.formatPrice(PriceShapePrices.MoblerPrice)' }"></div> 1157 } 1158 } 1159 else if (spar > 0) 1160 { 1161 <div class="d-none" data-bind="setInitValue: { observable: SplashType, value: 1 }"></div> 1162 <div class="d-none" data-bind="setInitValue: { observable: BeforePrice, value: '@normalPriceFormatted' }"></div> 1163 <div class="d-none" data-bind="setInitValue: { observable: Saving, value: '@sparFormatted' }"></div> 1164 } 1165 else if (NewItem) 1166 { 1167 <div class="d-none" data-bind="setInitValue: { observable: SplashType, value: 2 }"></div> 1168 } 1169 else if (LowPrice) 1170 { 1171 <div class="d-none" data-bind="setInitValue: { observable: SplashType, value: 3 }"></div> 1172 } 1173 1174 <div class="w-100 unimportant-hidden" data-bind="css: { 'd-flex': SplashType() == 1 }"> 1175 <p class="color-subtle fs0 m-0 text-uppercase mr-3">@Translate("PriceBefore", "Før") <span data-bind="text: BeforePrice"></span></p> 1176 <p class="bg-discount fs0 text-uppercase m-0 px-2 font-weight-bold">@Translate("PriceSaving", "Spar") <span data-bind="text: Saving"></span></p> 1177 </div> 1178 <div class="w-100 unimportant-hidden" data-bind="css: { 'd-flex': SplashType() == 4 && ShowSaving }"> 1179 @if (GetLoop("VariantCombinations").Count > 0) 1180 { 1181 <p class="color-subtle fs0 m-0 text-uppercase mr-3">@Translate("PriceRecommendPriceFrom", "Vejl. pris fra") <span data-bind="text: CostPrice"></span></p> 1182 } 1183 else 1184 { 1185 <p class="color-subtle fs0 m-0 text-uppercase mr-3">@Translate("PriceRecommendPrice", "Vejl. pris") <span data-bind="text: CostPrice"></span></p> 1186 } 1187 </div> 1188 <p class="price font-weight-bold m-0"> 1189 <span class="unimportant-hidden" data-bind="css: { 'd-inline': SplashType() == 1 }">@Translate("ProductNow", "NU") </span> 1190 <span data-bind="text: Price"></span> 1191 </p> 1192 1193 <div class="payever-finance-express payever-button" data-code="@GetString("Ecom:Product.Number")" data-name="@GetString("Ecom:Product.Name")" data-price="@GetString("Ecom:Product.Price.Price").Replace(".", string.Empty).Replace(",", ".")" data-currency="DKK"></div> 1194 <script>(function (p, a, y, e, v, r, f) { p[v] = p[v] || []; p[v][r] = p[v][r] || []; if (!p[v][r][y]) { p[v][r][y] = f = a.createElement(y); f.async = 1; f.src = e; a.head.appendChild(f) } })(window, document, 'script', 'https://mein.payever.de/finances/business/mobler/finance-express/91203/scripts/finance_express.embed.min.js', 'Payever', 'FinanceExpress');</script> 1195 1196 @if (ForSale) 1197 { 1198 <div class="d-flex align-items-center mt-3"> 1199 <p class="m-0 font-weight-bold fs1 mr-2">@Translate("Product.Quantity", "Antal")</p> 1200 <div class="d-flex"> 1201 <div class="quantity-controls d-flex align-items-center mr-3"> 1202 <div class="control minus" data-bind="click: DecreaseQuantity"> 1203 - 1204 </div> 1205 <input type="text" name="Quantity" value="1" data-bind="value: Quantity" /> 1206 <div class="control plus" data-bind="click: IncrementQuantity"> 1207 + 1208 </div> 1209 </div> 1210 @if (BlackFridayTheme == "True") 1211 { 1212 <p class="btn btn-black-friday bf-bg-black add-to-cart m-0 d-flex align-items-center px-4" data-bind="click: AddToCart.bind($data, '@DataLayerPrice')"> 1213 @Translate("ProductAddToCart", "L&aelig;g i kurv") 1214 </p> 1215 } 1216 else 1217 { 1218 <p class="btn btn-primary add-to-cart m-0 d-flex align-items-center px-4" data-bind="click: AddToCart.bind($data, '@DataLayerPrice')"> 1219 @Translate("ProductAddToCart", "L&aelig;g i kurv") 1220 </p> 1221 } 1222 </div> 1223 </div> 1224 } 1225 else 1226 { 1227 <p>@Translate("Ecom:Product.NotForSaleMessage", "Produktet kan ikke købes.")</p> 1228 } 1229 </div> 1230 </div> 1231 </div> 1232 1233 </div> 1234 1235 </div> 1236 1237 <div class="d-flex flex-wrap justify-content-center external-ctas"> 1238 1239 @if (!String.IsNullOrWhiteSpace(GetString("Ecom:Product:Field.ProviderLink.Value.Clean"))) 1240 { 1241 <a href="@GetString("Ecom:Product:Field.ProviderLink.Value.Clean")" target="_blank" class="bg-brand font-weight-bold d-flex align-items-center justify-content-center no-underline p-3 color-white"> 1242 <span>@Translate("Product.DesignSelf", "Design selv")</span> 1243 <img src="/Files/Templates/Designs/Mobler2018/assets/img/icons/Pencil1.svg" /> 1244 </a> 1245 } 1246 1247 @if (!String.IsNullOrEmpty(ProductCatalogLink)) 1248 { 1249 <a class="btn btn-secondary rounded-0 d-flex justify-content-center align-items-center p-3 color-white font-weight-bold" href="@ProductCatalogLink" target="_blank"> 1250 <span>@Translate("ProductProductCatalogLink", "Se inspirationsbrochure")</span> 1251 <img src="/Files/Templates/Designs/Mobler2018/assets/img/icons/Brochure.svg" /> 1252 </a> 1253 } 1254 1255 </div> 1256 1257 <div class="d-flex flex-wrap mt-5"> 1258 1259 <div id="js-full-description"> 1260 <p class="fs3 mb-2 font-weight-bold">@Translate("ProductDescriptionHeader", "Beskrivelse")</p> 1261 <div class="unimportant-hidden" data-bind="html: FullDescription, css: { 'd-block': FullDescription().length > 0 }"> 1262 </div> 1263 <div data-bind="css: { 'd-none': FullDescription().length > 0 }"> 1264 @LongDescription 1265 1266 @if (!string.IsNullOrEmpty(productionDescription)) 1267 { 1268 <br/><br /> 1269 <h4>@Translate("Product.ProductionDescription.Headline", "Produktionsbeskrivelse")</h4> 1270 @:@productionDescription 1271 } 1272 </div> 1273 </div> 1274 1275 </div> 1276 1277 <div class="d-flex flex-wrap my-5"> 1278 1279 <div class="description-container mt-5 mt-lg-0"> 1280 <div class="bg-brand color-white box-shadow p-3 pb-5 questions"> 1281 <img class="staff-img" src="/Files/Templates/Designs/Mobler2018/assets/img/sovnmand.png" /> 1282 1283 @if (!String.IsNullOrWhiteSpace(shopInfo.ShopName) && shopInfo.ShopName != "Møblér") 1284 { 1285 <div class="shop-info"> 1286 <h4 class="fs45">@Translate("ProductQuestionsHeader", "Har du sp&oslash;rsm&aring;l?")</h4> 1287 <p class="mb-1">@shopInfo.Address, @shopInfo.PostalAndCity</p> 1288 <p class="mb-1">@shopInfo.Phone</p> 1289 @if (!String.IsNullOrEmpty(shopInfo.Email)) 1290 { 1291 <p class="mb-1"><a class="color-white" href="mailto:@shopInfo.Email">@shopInfo.Email</a></p> 1292 } 1293 @if (!String.IsNullOrEmpty(shopInfo.ShopName1)) 1294 { 1295 <p class="mb-1 mt-2">@shopInfo.Address1, @shopInfo.PostalAndCity1</p> 1296 <p class="mb-2">@shopInfo.Phone1</p> 1297 } 1298 @if (!String.IsNullOrEmpty(shopInfo.ShopName2)) 1299 { 1300 <p class="mb-1 mt-2">@shopInfo.Address2, @shopInfo.PostalAndCity2</p> 1301 <p class="mb-2">@shopInfo.Phone2</p> 1302 } 1303 @shopInfo.OpeningHours 1304 </div> 1305 } 1306 else 1307 { 1308 <h4 class="fs45">@Translate("ProductQuestionsHeader", "Har du sp&oslash;rsm&aring;l?")</h4> 1309 <p class="fs2 text">@Translate("ProductSelectNearestShop", "V&aelig;lg n&aelig;rmeste M&oslash;bler bolighus")</p> 1310 <select style="width: 280px;" data-bind="select2SelectShop: { overlay: 'find-dealer-overlay', placeholder: '@SelectPlaceholder' }"> 1311 @if (shopname == "Møblér") 1312 { 1313 <option selected disabled>@Translate("HeaderFindShop", "Find forhandler")</option> 1314 } 1315 else 1316 { 1317 foreach (var Shop in AllShops.Where(x => x.MenuText == shopname)) 1318 { 1319 <option selected disabled value="@HttpUtility.UrlEncode(Shop.MenuText)">@Shop.ShopName</option> 1320 } 1321 } 1322 @foreach (var Shop in AllShops) 1323 { 1324 if (Shop.MenuText != "Møblér" && Shop.MenuText != shopname) 1325 { 1326 var Address = "<div>" + Shop.Address + "</div><div>" + Shop.PostalAndCity + "</div>"; 1327 <option title="@Address" value="@HttpUtility.UrlEncode(Shop.MenuText)">@Shop.ShopName {{@Shop.PostalAndCity @Shop.SearchKeyWords}}</option> 1328 } 1329 } 1330 </select> 1331 } 1332 </div> 1333 </div> 1334 1335 </div> 1336 1337 @if (GetInteger("Ecom:Product.RelatedCount") > 0) 1338 { 1339 foreach (var Group in GetLoop("ProductRelatedGroups").Where(g => g.GetLoop("Products").Count > 0)) 1340 { 1341 <div class="py-3 mt-5" data-bind="viewModel: 'ProductListViewModel'"> 1342 1343 <div class="delivery-information-popup" data-bind="css: { 'd-flex': QuickDeliveryInfoOpen }, click: ToggleQuickDeliveryInfo"> 1344 <div class="description-content bg-white px-3 py-4 px-lg-4 position-relative" data-bind="click: OpenQuickDeliveryInfo, clickBubble: false"> 1345 <div class="modal-closer-custom" data-bind="click: ToggleQuickDeliveryInfo, clickBubble: false"> 1346 <img src="/Files/Templates/Designs/Mobler2018/assets/img/icons/close.svg" /> 1347 </div> 1348 <div> 1349 @QuickDeliveryDescription 1350 </div> 1351 </div> 1352 </div> 1353 <div class="delivery-information-popup" data-bind="css: { 'd-flex': NormalDeliveryInfoOpen }, click: ToggleNormalDeliveryInfo"> 1354 <div class="description-content bg-white px-3 py-4 px-lg-4 position-relative" data-bind="click: OpenNormalDeliveryInfo, clickBubble: false"> 1355 <div class="modal-closer-custom" data-bind="click: ToggleNormalDeliveryInfo, clickBubble: false"> 1356 <img src="/Files/Templates/Designs/Mobler2018/assets/img/icons/close.svg" /> 1357 </div> 1358 <div> 1359 @NormalDeliveryDescription 1360 </div> 1361 </div> 1362 </div> 1363 1364 <div class="line-through-header mb-3"> 1365 <h4>@Group.GetString("Ecom:Product:RelatedGroup.Name")</h4> 1366 </div> 1367 1368 <div class="row"> 1369 1370 @foreach (var Product in Group.GetLoop("Products")) 1371 { 1372 var productToRender = Product; 1373 string productId = Product.GetString("Ecom:Product.ID"); 1374 string variantIdLoop = productsDisplayVariant.GetDisplayVariantId(productId); 1375 1376 if (Product.GetLoop("VariantCombinations").Count > 0 && Product.GetLoop("VariantCombinations").Any(x => x.GetString("Ecom:Product.VariantID").Equals(variantIdLoop))) 1377 { 1378 productToRender = Product.GetLoop("VariantCombinations").FirstOrDefault(x => x.GetString("Ecom:Product.VariantID").Equals(variantIdLoop)); 1379 } 1380 1381 @RenderProduct(productToRender) 1382 } 1383 </div> 1384 </div> 1385 } 1386 } 1387 1388 @if (RelatedBlogs.Count > 0) 1389 { 1390 string ImagePosition = "Left"; 1391 <div class="feature-blogs my-5"> 1392 1393 <div class="row"> 1394 1395 @foreach (var Blog in RelatedBlogs) 1396 { 1397 @RenderLargeBlogTeaser(Blog, ImagePosition) 1398 if (ImagePosition == "Left") 1399 { 1400 ImagePosition = "Right"; 1401 } 1402 else 1403 { 1404 ImagePosition = "Left"; 1405 } 1406 } 1407 1408 </div> 1409 1410 </div> 1411 } 1412 1413 1414 <div class="after-add-to-cart bg-white box-shadow" data-bind="css: { 'd-block': ProductAddedToCart }"> 1415 <div class="closer fs3 pointer" data-bind="click: ProductAddedToCart(false)"> 1416 <i class="fas fa-times-circle color-primary"></i> 1417 </div> 1418 <div class="p-3"> 1419 <p class="font-weight-bold fs4 text-uppercase m-0"> 1420 <i class="fas fa-check-circle color-primary"></i> 1421 @Translate("ProductProductAddedToCart", "Varen er lagt i indk&oslash;bskurven") 1422 </p> 1423 </div> 1424 <div class="mini-cart large-cart power-step"> 1425 1426 <div class="position-relative"> 1427 <div class="cart-command-loader unimportant-hidden justify-content-center align-items-center" data-bind="css: { 'd-flex': Loading }"> 1428 <div class="d-flex align-items-center"> 1429 <p class="m-0 mr-2">@Translate("Cart.UpdatingCart", "Opdaterer kurv")</p> 1430 <i class="fas fa-spinner fa-spin"></i> 1431 </div> 1432 </div> 1433 1434 <div class="lines" data-bind="foreach: Orderlines"> 1435 <div class="cartline d-flex justify-content-between align-items-center px-3 py-2 position-relative bg-grey"> 1436 <span class="delete-orderline color-subtle cursor-pointer mr-2" data-bind="click: $parent.DeleteOrderline.bind($data, OrderlineId)"> 1437 <i class="fas fa-times"></i> 1438 </span> 1439 <div class="product-image w-10"> 1440 <img class="img-fluid" data-bind="attr: { src: ImagePath }" /> 1441 </div> 1442 <div class="flex-fill px-3 w-75"> 1443 <p class="font-weight-bold m-0" data-bind="text: ProductName"></p> 1444 <p class="m-0 color-subtle small-quantity-indicator"><span data-bind="text: Quantity"></span> stk. a <span data-bind="text: QuantityPrice"></span></p> 1445 <div class="variant-dimensions" data-bind="foreach: VariantDimensions"> 1446 <p class="m-0 color-subtle color-dark-grey font-weight-bold"> 1447 <span data-bind="text: Label"></span> 1448 <span class="font-weight-normal" data-bind="text: Value"></span> 1449 </p> 1450 </div> 1451 </div> 1452 <div class="qty-counter w-10"> 1453 <div class="d-flex"> 1454 <div class="quantity-controls d-flex align-items-center mr-3"> 1455 <div class="control minus" data-bind="click: $parent.QuantityControl.bind($data, -1, OrderlineId)"> 1456 - 1457 </div> 1458 <input disabled type="text" name="Quantity" value="1" data-bind="value: Quantity, attr: { 'data-id': 'js-input-' + OrderlineId }" /> 1459 <div class="control plus" data-bind="click: $parent.QuantityControl.bind($data, 1, OrderlineId)"> 1460 + 1461 </div> 1462 </div> 1463 </div> 1464 </div> 1465 1466 <p class="fs0 m-0 orderline-price" data-bind="text: OrderlinePrice"></p> 1467 </div> 1468 </div> 1469 @if (BlackFridayTheme == "True") 1470 { 1471 <div class="bf-bg-black p-3 d-flex justify-content-between align-items-center price-summary"> 1472 <p class="m-0 color-white fs-12px font-weight-semibold">@Translate("MiniCartTotal", "Din kurv i alt (ex. fragt)")</p> 1473 <p class="m-0 color-white fs1 font-weight-bold" data-bind="text: CartTotalNoFees"></p> 1474 </div> 1475 } 1476 else 1477 { 1478 <div class="bg-brand p-3 d-flex justify-content-between align-items-center price-summary"> 1479 <p class="m-0 color-white fs-12px font-weight-semibold">@Translate("MiniCartTotal", "Din kurv i alt (ex. fragt)")</p> 1480 <p class="m-0 color-white fs1 font-extra-bold" data-bind="text: CartTotalNoFees"></p> 1481 </div> 1482 } 1483 </div> 1484 1485 </div> 1486 <div class="p-3 d-flex justify-content-between"> 1487 <p class="pointer py-2 px-3 bg-dark-grey color-white rounded m-0" data-bind="click: ProductAddedToCart(false)">@Translate("MiniCartContinueShopping", "Handel videre")</p> 1488 1489 @if (BlackFridayTheme == "True") 1490 { 1491 <a href="@CartPage" class="pointer py-2 px-3 bf-bg-black color-white rounded d-block no-underline">@Translate("MiniCartGoToCheckout", "G&aring; til kassen")</a> 1492 } 1493 else 1494 { 1495 <a href="@CartPage" class="pointer py-2 px-3 bg-brand color-white rounded d-block no-underline">@Translate("MiniCartGoToCheckout", "G&aring; til kassen")</a> 1496 } 1497 1498 </div> 1499 <div class="js-customers-also-saw-lines"></div> 1500 1501 </div> 1502 <div class="variant-picker" data-bind="css: { 'open': VariantPickerOpen }"> 1503 <div class="closer color-primary fs5 pointer" data-bind="click: ToggleVariantPicker"> 1504 <i class="fas fa-times-circle"></i> 1505 </div> 1506 <div class="container py-5 position-relative"> 1507 <h3 class="fs4 text-center">Design din @ProductName</h3> 1508 @{ 1509 var ColorDimensions = GetLoop("VariantGroups").Where(g => g.GetString("Ecom:VariantGroup.Name").ToLower().Contains("farve")); 1510 var NonColorDimensions = GetLoop("VariantGroups").Where(g => !g.GetString("Ecom:VariantGroup.Name").ToLower().Contains("farve")); 1511 int FilterCounter = 0; 1512 string RowClass = NonColorDimensions.Any() && ColorDimensions.Any() ? "flex-row-reverse" : ""; 1513 } 1514 <div class="row mt-5 @RowClass"> 1515 @if (ColorDimensions.Any()) 1516 { 1517 <div class="col-12 col-md-8"> 1518 @foreach (var VariantDimension in ColorDimensions) 1519 { 1520 string DimensionName = VariantDimension.GetString("Ecom:VariantGroup.Name"); 1521 string FilterName = "filter-" + FilterCounter; 1522 FilterCounter++; 1523 <div class="mb-5 mb-md-0"> 1524 <p class="font-weight-bold fs2 mb-2">@DimensionName</p> 1525 <div class="row custom-row"> 1526 @foreach (var VariantOption in VariantDimension.GetLoop("VariantAvailableOptions").OrderBy(v => v.GetString("Ecom:VariantOption.Name"))) 1527 { 1528 string VariantOptionName = VariantOption.GetString("Ecom:VariantOption.Name"); 1529 string VariantOptionId = VariantOption.GetString("Ecom:VariantOption.ID"); 1530 string Preview = VariantOption.GetString("Ecom:VariantOption.ImgSmall.Clean"); 1531 string PreviewCss = ""; 1532 if (!String.IsNullOrEmpty(Preview)) 1533 { 1534 if (Preview.StartsWith("#")) 1535 { 1536 PreviewCss = "style= \"background-color: " + Preview + ";\""; 1537 } 1538 else 1539 { 1540 PreviewCss = "style=\"background-image: url('" + Preview + "');\""; 1541 } 1542 } 1543 <div class="col-2 col-sm-3 col-md-2 mb-3 d-flex flex-column justify-content-end pointer color-variant" data-bind="click: AddToFilter.bind($data, $element, '@FilterName', '@VariantOptionId')"> 1544 <p class="mb-0 color-variant-name d-none d-sm-block">@VariantOptionName</p> 1545 <div class="variant-preview position-relative d-flex" @PreviewCss></div> 1546 </div> 1547 } 1548 </div> 1549 </div> 1550 } 1551 </div> 1552 } 1553 @if (NonColorDimensions.Any()) 1554 { 1555 <div class="col-12 col-sm-6 col-md-4"> 1556 @foreach (var VariantDimension in NonColorDimensions) 1557 { 1558 string DimensionName = VariantDimension.GetString("Ecom:VariantGroup.Name"); 1559 string FilterName = "filter-" + FilterCounter; 1560 FilterCounter++; 1561 <div class="mb-5"> 1562 <p class="font-weight-bold fs2 mb-2">@DimensionName</p> 1563 <div class="row custom-row"> 1564 @foreach (var VariantOption in VariantDimension.GetLoop("VariantAvailableOptions").OrderBy(v => v.GetString("Ecom:VariantOption.Name"))) 1565 { 1566 string VariantOptionName = VariantOption.GetString("Ecom:VariantOption.Name"); 1567 string VariantOptionId = VariantOption.GetString("Ecom:VariantOption.ID"); 1568 string Preview = VariantOption.GetString("Ecom:VariantOption.ImgSmall.Clean"); 1569 string PreviewCss = ""; 1570 if (!String.IsNullOrEmpty(Preview)) 1571 { 1572 if (Preview.StartsWith("#")) 1573 { 1574 PreviewCss = "style= \"background-color: " + Preview + ";\""; 1575 } 1576 else 1577 { 1578 PreviewCss = "style=\"background-image: url('/Files" + Preview + "');\""; 1579 } 1580 } 1581 if (DimensionName == "STØRRELSE") 1582 { 1583 <div class="col-6 col-sm-4 mb-3 d-flex flex-column justify-content-end pointer size-variant" data-bind="click: AddToFilter.bind($data, $element, '@FilterName', '@VariantOptionId')"> 1584 <div class="variant-preview position-relative d-flex justify-content-center align-items-center" @PreviewCss> 1585 <p class="mb-0 color-variant-name font-weight-bold">@VariantOptionName</p> 1586 </div> 1587 </div> 1588 } 1589 else 1590 { 1591 <div class="col-6 col-sm-4 mb-3 d-flex flex-column justify-content-end pointer" data-bind="click: AddToFilter.bind($data, $element, '@FilterName', '@VariantOptionId')"> 1592 <p class="mb-0 color-variant-name">@VariantOptionName</p> 1593 <div class="variant-preview position-relative d-flex" @PreviewCss></div> 1594 </div> 1595 } 1596 } 1597 </div> 1598 </div> 1599 } 1600 </div> 1601 } 1602 1603 <div class="col-12 d-flex justify-content-end"> 1604 <p class="color-primary pointer my-3" data-bind="click: ResetFilters">Nulstil</p> 1605 </div> 1606 </div> 1607 <p class="font-weight-bold fs2 mt-5"> 1608 @Translate("ChooseProduct", "V&aelig;lg produkt") 1609 </p> 1610 <div class="row align-items-end" data-bind="foreach: FilteredVariants"> 1611 <div class="col-12 col-sm-6 col-md-3 mb-3"> 1612 <a class="color-black no-underline" data-bind="attr: { href: Link }"> 1613 <p class="fs0 font-weight-bold m-0" data-bind="text: Name"></p> 1614 <img class="img-fluid box-shadow my-1" data-bind="attr: { src: Image }" /> 1615 <div class="d-flex justify-content-center mt-2"> 1616 <div class="btn btn-primary">@Translate("VariantChooseProduct", "V&aelig;lg")</div> 1617 </div> 1618 </a> 1619 </div> 1620 </div> 1621 <div data-bind="visible: FilteredVariants().length == 0"> 1622 <p class="font-weight-bold mt-3 fs3">@Translate("VariantsNoResults", "Filtreringen gav ingen resultater")</p> 1623 </div> 1624 </div> 1625 </div> 1626 </div> 1627 1628 @SnippetStart("DataLayerOverwrites") 1629 <script> 1630 ecomm_pagetype = "Product"; 1631 ecomm_totalvalue = @GetString("Ecom:Product.Price.Price").Replace(".","").Replace(",","."); 1632 ecomm_prodid = "@GetString("Ecom:Product.ID")"; 1633 </script> 1634 @SnippetEnd("DataLayerOverwrites") 1635

Tilbud, indretningstips og inspiration – tilmeld dig vores nyhedsbrev

Hold dig opdateret om vores nyeste tilbud på senge, sofaer og spiseborde, eller få inspiration til indretningen af dit hjem. Som abonnent på Møblérs nyhedsbrev får du altid besked om udsalg og gode tilbud på vores mange møbler, ligesom vi ligeledes deler ud af vores store erfaring og viden inden for indretning og tidens trends. 

Tak, du er nu tilmeldt Møblérs nyhedsbrev.
Du er allerede tilmeldt Møblérs nyhedsbrev.
Du er allerede tilmeldt Møblérs nyhedsbrev.