KAZAN og Netsu | HUSK vores pallerabat

Når du køber en Mitsubishi Kazan eller Netsu model skal du huske, at du får pallerabat ved køb af flere produkter.  

Denne rabat gælder assorteret størrelser og modeller - og om du vælger KAZAN eller Netsu.

4 stk = 6 % rabat*
8 stk = 10 % rabat*

*Gælder i forhold til standard rabat

Se udvalget af KAZAN og Netsu modeller nedenfor eller i vores webshop

Læs mere om Kazan og Netsu i vores brochurer

KAZAN

Error executing template "/Designs/Rapido/Paragraph/PromotionProducts.cshtml"
System.NullReferenceException: Object reference not set to an instance of an object.
   at CompiledRazorTemplates.Dynamic.RazorEngine_a50f6fd0e36d4a03b79db1c375449d79.Execute() in E:\HJJ.Web\Files\Templates\Designs\Rapido\Paragraph\PromotionProducts.cshtml:line 43
   at RazorEngine.Templating.TemplateBase.RazorEngine.Templating.ITemplate.Run(ExecuteContext context, TextWriter reader)
   at RazorEngine.Templating.RazorEngineCore.RunTemplate(ICompiledTemplate template, TextWriter writer, Object model, DynamicViewBag viewBag)
   at RazorEngine.Templating.RazorEngineService.RunCompile(ITemplateKey key, TextWriter writer, Type modelType, Object model, DynamicViewBag viewBag)
   at RazorEngine.Templating.DynamicWrapperService.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 RazorEngine.Templating.RazorEngineServiceExtensions.RunCompile(IRazorEngineService service, String name, Type modelType, Object model, DynamicViewBag viewBag)
   at RazorEngine.Templating.RazorEngineServiceExtensions.RunCompile(IRazorEngineService service, ITemplateSource templateSource, String name, Type modelType, Object model, DynamicViewBag viewBag)
   at Dynamicweb.Rendering.Template.RenderRazorTemplate()

1 @inherits Dynamicweb.Rendering.ViewModelTemplate<Dynamicweb.Frontend.ParagraphViewModel> 2 @using Dynamicweb.Ecommerce.Frontend; 3 @using Dynamicweb.Core; 4 @using System.Linq; 5 6 @inherits Dynamicweb.Rendering.ViewModelTemplate<Dynamicweb.Frontend.ParagraphViewModel> 7 8 @functions { 9 public string columnClass() 10 { 11 if (Model.Item.GetList("WidthMobile").SelectedValue == "hide"){ 12 return "grid__col-lg-" + Model.Item.GetList("Width").SelectedValue + " grid__col-md-" + Model.Item.GetList("Width").SelectedValue + " grid__col-sm-" + Model.Item.GetList("Width").SelectedValue + " u-hidden-xs u-hidden-xxs"; 13 } else { 14 return "grid__col-lg-" + Model.Item.GetList("Width").SelectedValue + " grid__col-md-" + Model.Item.GetList("Width").SelectedValue + " grid__col-sm-" + Model.Item.GetList("Width").SelectedValue + " grid__col-xs-" + Model.Item.GetList("WidthMobile").SelectedValue; 15 } 16 } 17 } 18 19 20 @{ 21 int productCatalogId = GetPageIdByNavigationTag("PromotionFeed"); 22 string feedFullUrl = "/Default.aspx?ID=" + productCatalogId; 23 int paragraphId = Model.ID; 24 25 var products = Model.Item.GetValue("Products") as List<ProductViewModel>; 26 27 feedFullUrl += "&Combinations="; 28 bool onlyPreview = Converter.ToBoolean(Pageview.Area.Item["OnlyPreviewForAnonymous"]) && Pageview.User == null; 29 30 if (products != null) { 31 for (var i = 0; i < products.Count; i++) 32 { 33 feedFullUrl += products[i].Id; 34 feedFullUrl += products[i].VariantId != "" ? "%20" + products[i].VariantId : ""; 35 feedFullUrl += ","; 36 } 37 } else { 38 feedFullUrl = ""; 39 } 40 41 var columnSize = 3; 42 43 if (products.Count == 3) { 44 columnSize = 4; 45 } 46 47 if (products.Count == 2) 48 { 49 columnSize = 6; 50 } 51 52 if (products.Count == 1) 53 { 54 columnSize = 12; 55 } 56 57 switch (Model.Item.GetList("Width").SelectedValue) { 58 case "6": 59 case "4": 60 columnSize = 6; 61 break; 62 case "3": 63 columnSize = 12; 64 break; 65 } 66 } 67 68 <div class="@columnClass()"> 69 <div class="grid js-handlebars-root" id="PromotionProductList_@paragraphId" data-template="PromotionProducts" data-pre-render-template="ProductPreRenderContainer" data-json-feed="@feedFullUrl" data-preloader="minimal"></div> 70 </div> 71 72 <script id="ProductPreRenderContainer" type="text/x-template"> 73 <div class="grid__col-md-@columnSize"> 74 <div class="pre-render-element pre-render-element--md"></div> 75 </div> 76 <div class="grid__col-md-@columnSize"> 77 <div class="pre-render-element pre-render-element--md"></div> 78 </div> 79 <div class="grid__col-md-@columnSize"> 80 <div class="pre-render-element pre-render-element--md"></div> 81 </div> 82 <div class="grid__col-md-@columnSize"> 83 <div class="pre-render-element pre-render-element--md"></div> 84 </div> 85 </script> 86 87 88 @* Grid view *@ 89 90 <script id="PromotionProducts" type="text/x-template"> 91 {{#.}} 92 <div class="grid__col-lg-@columnSize grid__col-md-@columnSize grid__col-sm-@columnSize grid__col-xs-6"> 93 <div class="grid__cell product-list__grid-item__image dw-mod {{noImage}}"> 94 <div class="stickers-container dw-mod"> 95 {{#Stickers}} 96 {{>Sticker}} 97 {{/Stickers}} 98 </div> 99 <a href="{{link}}" onclick="Scroll.SavePosition(event)"><img class="grid__cell-img grid__cell-img--centered b-lazy" src="/Files/Images/placeholder.gif" data-src="/Admin/Public/GetImage.ashx?width=300&amp;height=300&amp;crop=5&amp;Compression=75&amp;image={{image}}" alt="{{name}}" /></a> 100 </div> 101 102 <div class="grid__cell product-list__grid-item__price-info {{shortGridInfo}} dw-mod"> 103 <a href="{{link}}" onclick="Scroll.SavePosition(event)" title="{{name}}"><h6>{{name}}</h6></a> 104 <div class="item-number dw-mod">{{number}}</div> 105 @if (!onlyPreview) 106 { 107 <div class="price dw-mod">{{price}}</div> 108 <div class="before-price {{onSale}} dw-mod">{{discount}}</div> 109 } 110 <input type="hidden" id="Quantity_{{id}}" name="Quantity" value="1" min="1"> 111 <input type="hidden" value="{{unitId}}" name="Unit" id="Unit_{{id}}" /> 112 <input type="hidden" value="{{variantid}}" name="VariantID" id="Variant_{{id}}" /> 113 </div> 114 115 <div class="product-list__grid-item__footer dw-mod"> 116 <div class="u-ta-center"> 117 <a href="{{link}}" id="CartButton_{{id}}" class="btn btn--secondary btn--full u-no-margin dw-mod">@Translate("View")</a> 118 </div> 119 </div> 120 </div> 121 {{/.}} 122 123 {{^.}} 124 <div class="grid__col-12"> 125 <h2 class="u-ta-center">@Translate("No products found")</h2> 126 </div> 127 {{/.}} 128 </script> 129 130 <script id="Sticker" type="text/x-template"> 131 <div class="stickers-container__tag {{className}} dw-mod">{{text}}</div> 132 </script>
Error executing template "/Designs/Rapido/Paragraph/PromotionProducts.cshtml"
System.NullReferenceException: Object reference not set to an instance of an object.
   at CompiledRazorTemplates.Dynamic.RazorEngine_a50f6fd0e36d4a03b79db1c375449d79.Execute() in E:\HJJ.Web\Files\Templates\Designs\Rapido\Paragraph\PromotionProducts.cshtml:line 43
   at RazorEngine.Templating.TemplateBase.RazorEngine.Templating.ITemplate.Run(ExecuteContext context, TextWriter reader)
   at RazorEngine.Templating.RazorEngineCore.RunTemplate(ICompiledTemplate template, TextWriter writer, Object model, DynamicViewBag viewBag)
   at RazorEngine.Templating.RazorEngineService.RunCompile(ITemplateKey key, TextWriter writer, Type modelType, Object model, DynamicViewBag viewBag)
   at RazorEngine.Templating.DynamicWrapperService.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 RazorEngine.Templating.RazorEngineServiceExtensions.RunCompile(IRazorEngineService service, String name, Type modelType, Object model, DynamicViewBag viewBag)
   at RazorEngine.Templating.RazorEngineServiceExtensions.RunCompile(IRazorEngineService service, ITemplateSource templateSource, String name, Type modelType, Object model, DynamicViewBag viewBag)
   at Dynamicweb.Rendering.Template.RenderRazorTemplate()

1 @inherits Dynamicweb.Rendering.ViewModelTemplate<Dynamicweb.Frontend.ParagraphViewModel> 2 @using Dynamicweb.Ecommerce.Frontend; 3 @using Dynamicweb.Core; 4 @using System.Linq; 5 6 @inherits Dynamicweb.Rendering.ViewModelTemplate<Dynamicweb.Frontend.ParagraphViewModel> 7 8 @functions { 9 public string columnClass() 10 { 11 if (Model.Item.GetList("WidthMobile").SelectedValue == "hide"){ 12 return "grid__col-lg-" + Model.Item.GetList("Width").SelectedValue + " grid__col-md-" + Model.Item.GetList("Width").SelectedValue + " grid__col-sm-" + Model.Item.GetList("Width").SelectedValue + " u-hidden-xs u-hidden-xxs"; 13 } else { 14 return "grid__col-lg-" + Model.Item.GetList("Width").SelectedValue + " grid__col-md-" + Model.Item.GetList("Width").SelectedValue + " grid__col-sm-" + Model.Item.GetList("Width").SelectedValue + " grid__col-xs-" + Model.Item.GetList("WidthMobile").SelectedValue; 15 } 16 } 17 } 18 19 20 @{ 21 int productCatalogId = GetPageIdByNavigationTag("PromotionFeed"); 22 string feedFullUrl = "/Default.aspx?ID=" + productCatalogId; 23 int paragraphId = Model.ID; 24 25 var products = Model.Item.GetValue("Products") as List<ProductViewModel>; 26 27 feedFullUrl += "&Combinations="; 28 bool onlyPreview = Converter.ToBoolean(Pageview.Area.Item["OnlyPreviewForAnonymous"]) && Pageview.User == null; 29 30 if (products != null) { 31 for (var i = 0; i < products.Count; i++) 32 { 33 feedFullUrl += products[i].Id; 34 feedFullUrl += products[i].VariantId != "" ? "%20" + products[i].VariantId : ""; 35 feedFullUrl += ","; 36 } 37 } else { 38 feedFullUrl = ""; 39 } 40 41 var columnSize = 3; 42 43 if (products.Count == 3) { 44 columnSize = 4; 45 } 46 47 if (products.Count == 2) 48 { 49 columnSize = 6; 50 } 51 52 if (products.Count == 1) 53 { 54 columnSize = 12; 55 } 56 57 switch (Model.Item.GetList("Width").SelectedValue) { 58 case "6": 59 case "4": 60 columnSize = 6; 61 break; 62 case "3": 63 columnSize = 12; 64 break; 65 } 66 } 67 68 <div class="@columnClass()"> 69 <div class="grid js-handlebars-root" id="PromotionProductList_@paragraphId" data-template="PromotionProducts" data-pre-render-template="ProductPreRenderContainer" data-json-feed="@feedFullUrl" data-preloader="minimal"></div> 70 </div> 71 72 <script id="ProductPreRenderContainer" type="text/x-template"> 73 <div class="grid__col-md-@columnSize"> 74 <div class="pre-render-element pre-render-element--md"></div> 75 </div> 76 <div class="grid__col-md-@columnSize"> 77 <div class="pre-render-element pre-render-element--md"></div> 78 </div> 79 <div class="grid__col-md-@columnSize"> 80 <div class="pre-render-element pre-render-element--md"></div> 81 </div> 82 <div class="grid__col-md-@columnSize"> 83 <div class="pre-render-element pre-render-element--md"></div> 84 </div> 85 </script> 86 87 88 @* Grid view *@ 89 90 <script id="PromotionProducts" type="text/x-template"> 91 {{#.}} 92 <div class="grid__col-lg-@columnSize grid__col-md-@columnSize grid__col-sm-@columnSize grid__col-xs-6"> 93 <div class="grid__cell product-list__grid-item__image dw-mod {{noImage}}"> 94 <div class="stickers-container dw-mod"> 95 {{#Stickers}} 96 {{>Sticker}} 97 {{/Stickers}} 98 </div> 99 <a href="{{link}}" onclick="Scroll.SavePosition(event)"><img class="grid__cell-img grid__cell-img--centered b-lazy" src="/Files/Images/placeholder.gif" data-src="/Admin/Public/GetImage.ashx?width=300&amp;height=300&amp;crop=5&amp;Compression=75&amp;image={{image}}" alt="{{name}}" /></a> 100 </div> 101 102 <div class="grid__cell product-list__grid-item__price-info {{shortGridInfo}} dw-mod"> 103 <a href="{{link}}" onclick="Scroll.SavePosition(event)" title="{{name}}"><h6>{{name}}</h6></a> 104 <div class="item-number dw-mod">{{number}}</div> 105 @if (!onlyPreview) 106 { 107 <div class="price dw-mod">{{price}}</div> 108 <div class="before-price {{onSale}} dw-mod">{{discount}}</div> 109 } 110 <input type="hidden" id="Quantity_{{id}}" name="Quantity" value="1" min="1"> 111 <input type="hidden" value="{{unitId}}" name="Unit" id="Unit_{{id}}" /> 112 <input type="hidden" value="{{variantid}}" name="VariantID" id="Variant_{{id}}" /> 113 </div> 114 115 <div class="product-list__grid-item__footer dw-mod"> 116 <div class="u-ta-center"> 117 <a href="{{link}}" id="CartButton_{{id}}" class="btn btn--secondary btn--full u-no-margin dw-mod">@Translate("View")</a> 118 </div> 119 </div> 120 </div> 121 {{/.}} 122 123 {{^.}} 124 <div class="grid__col-12"> 125 <h2 class="u-ta-center">@Translate("No products found")</h2> 126 </div> 127 {{/.}} 128 </script> 129 130 <script id="Sticker" type="text/x-template"> 131 <div class="stickers-container__tag {{className}} dw-mod">{{text}}</div> 132 </script>

Netsu

Error executing template "/Designs/Rapido/Paragraph/PromotionProducts.cshtml"
System.NullReferenceException: Object reference not set to an instance of an object.
   at CompiledRazorTemplates.Dynamic.RazorEngine_a50f6fd0e36d4a03b79db1c375449d79.Execute() in E:\HJJ.Web\Files\Templates\Designs\Rapido\Paragraph\PromotionProducts.cshtml:line 43
   at RazorEngine.Templating.TemplateBase.RazorEngine.Templating.ITemplate.Run(ExecuteContext context, TextWriter reader)
   at RazorEngine.Templating.RazorEngineCore.RunTemplate(ICompiledTemplate template, TextWriter writer, Object model, DynamicViewBag viewBag)
   at RazorEngine.Templating.RazorEngineService.RunCompile(ITemplateKey key, TextWriter writer, Type modelType, Object model, DynamicViewBag viewBag)
   at RazorEngine.Templating.DynamicWrapperService.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 RazorEngine.Templating.RazorEngineServiceExtensions.RunCompile(IRazorEngineService service, String name, Type modelType, Object model, DynamicViewBag viewBag)
   at RazorEngine.Templating.RazorEngineServiceExtensions.RunCompile(IRazorEngineService service, ITemplateSource templateSource, String name, Type modelType, Object model, DynamicViewBag viewBag)
   at Dynamicweb.Rendering.Template.RenderRazorTemplate()

1 @inherits Dynamicweb.Rendering.ViewModelTemplate<Dynamicweb.Frontend.ParagraphViewModel> 2 @using Dynamicweb.Ecommerce.Frontend; 3 @using Dynamicweb.Core; 4 @using System.Linq; 5 6 @inherits Dynamicweb.Rendering.ViewModelTemplate<Dynamicweb.Frontend.ParagraphViewModel> 7 8 @functions { 9 public string columnClass() 10 { 11 if (Model.Item.GetList("WidthMobile").SelectedValue == "hide"){ 12 return "grid__col-lg-" + Model.Item.GetList("Width").SelectedValue + " grid__col-md-" + Model.Item.GetList("Width").SelectedValue + " grid__col-sm-" + Model.Item.GetList("Width").SelectedValue + " u-hidden-xs u-hidden-xxs"; 13 } else { 14 return "grid__col-lg-" + Model.Item.GetList("Width").SelectedValue + " grid__col-md-" + Model.Item.GetList("Width").SelectedValue + " grid__col-sm-" + Model.Item.GetList("Width").SelectedValue + " grid__col-xs-" + Model.Item.GetList("WidthMobile").SelectedValue; 15 } 16 } 17 } 18 19 20 @{ 21 int productCatalogId = GetPageIdByNavigationTag("PromotionFeed"); 22 string feedFullUrl = "/Default.aspx?ID=" + productCatalogId; 23 int paragraphId = Model.ID; 24 25 var products = Model.Item.GetValue("Products") as List<ProductViewModel>; 26 27 feedFullUrl += "&Combinations="; 28 bool onlyPreview = Converter.ToBoolean(Pageview.Area.Item["OnlyPreviewForAnonymous"]) && Pageview.User == null; 29 30 if (products != null) { 31 for (var i = 0; i < products.Count; i++) 32 { 33 feedFullUrl += products[i].Id; 34 feedFullUrl += products[i].VariantId != "" ? "%20" + products[i].VariantId : ""; 35 feedFullUrl += ","; 36 } 37 } else { 38 feedFullUrl = ""; 39 } 40 41 var columnSize = 3; 42 43 if (products.Count == 3) { 44 columnSize = 4; 45 } 46 47 if (products.Count == 2) 48 { 49 columnSize = 6; 50 } 51 52 if (products.Count == 1) 53 { 54 columnSize = 12; 55 } 56 57 switch (Model.Item.GetList("Width").SelectedValue) { 58 case "6": 59 case "4": 60 columnSize = 6; 61 break; 62 case "3": 63 columnSize = 12; 64 break; 65 } 66 } 67 68 <div class="@columnClass()"> 69 <div class="grid js-handlebars-root" id="PromotionProductList_@paragraphId" data-template="PromotionProducts" data-pre-render-template="ProductPreRenderContainer" data-json-feed="@feedFullUrl" data-preloader="minimal"></div> 70 </div> 71 72 <script id="ProductPreRenderContainer" type="text/x-template"> 73 <div class="grid__col-md-@columnSize"> 74 <div class="pre-render-element pre-render-element--md"></div> 75 </div> 76 <div class="grid__col-md-@columnSize"> 77 <div class="pre-render-element pre-render-element--md"></div> 78 </div> 79 <div class="grid__col-md-@columnSize"> 80 <div class="pre-render-element pre-render-element--md"></div> 81 </div> 82 <div class="grid__col-md-@columnSize"> 83 <div class="pre-render-element pre-render-element--md"></div> 84 </div> 85 </script> 86 87 88 @* Grid view *@ 89 90 <script id="PromotionProducts" type="text/x-template"> 91 {{#.}} 92 <div class="grid__col-lg-@columnSize grid__col-md-@columnSize grid__col-sm-@columnSize grid__col-xs-6"> 93 <div class="grid__cell product-list__grid-item__image dw-mod {{noImage}}"> 94 <div class="stickers-container dw-mod"> 95 {{#Stickers}} 96 {{>Sticker}} 97 {{/Stickers}} 98 </div> 99 <a href="{{link}}" onclick="Scroll.SavePosition(event)"><img class="grid__cell-img grid__cell-img--centered b-lazy" src="/Files/Images/placeholder.gif" data-src="/Admin/Public/GetImage.ashx?width=300&amp;height=300&amp;crop=5&amp;Compression=75&amp;image={{image}}" alt="{{name}}" /></a> 100 </div> 101 102 <div class="grid__cell product-list__grid-item__price-info {{shortGridInfo}} dw-mod"> 103 <a href="{{link}}" onclick="Scroll.SavePosition(event)" title="{{name}}"><h6>{{name}}</h6></a> 104 <div class="item-number dw-mod">{{number}}</div> 105 @if (!onlyPreview) 106 { 107 <div class="price dw-mod">{{price}}</div> 108 <div class="before-price {{onSale}} dw-mod">{{discount}}</div> 109 } 110 <input type="hidden" id="Quantity_{{id}}" name="Quantity" value="1" min="1"> 111 <input type="hidden" value="{{unitId}}" name="Unit" id="Unit_{{id}}" /> 112 <input type="hidden" value="{{variantid}}" name="VariantID" id="Variant_{{id}}" /> 113 </div> 114 115 <div class="product-list__grid-item__footer dw-mod"> 116 <div class="u-ta-center"> 117 <a href="{{link}}" id="CartButton_{{id}}" class="btn btn--secondary btn--full u-no-margin dw-mod">@Translate("View")</a> 118 </div> 119 </div> 120 </div> 121 {{/.}} 122 123 {{^.}} 124 <div class="grid__col-12"> 125 <h2 class="u-ta-center">@Translate("No products found")</h2> 126 </div> 127 {{/.}} 128 </script> 129 130 <script id="Sticker" type="text/x-template"> 131 <div class="stickers-container__tag {{className}} dw-mod">{{text}}</div> 132 </script>
Error executing template "/Designs/Rapido/Paragraph/PromotionProducts.cshtml"
System.NullReferenceException: Object reference not set to an instance of an object.
   at CompiledRazorTemplates.Dynamic.RazorEngine_a50f6fd0e36d4a03b79db1c375449d79.Execute() in E:\HJJ.Web\Files\Templates\Designs\Rapido\Paragraph\PromotionProducts.cshtml:line 43
   at RazorEngine.Templating.TemplateBase.RazorEngine.Templating.ITemplate.Run(ExecuteContext context, TextWriter reader)
   at RazorEngine.Templating.RazorEngineCore.RunTemplate(ICompiledTemplate template, TextWriter writer, Object model, DynamicViewBag viewBag)
   at RazorEngine.Templating.RazorEngineService.RunCompile(ITemplateKey key, TextWriter writer, Type modelType, Object model, DynamicViewBag viewBag)
   at RazorEngine.Templating.DynamicWrapperService.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 RazorEngine.Templating.RazorEngineServiceExtensions.RunCompile(IRazorEngineService service, String name, Type modelType, Object model, DynamicViewBag viewBag)
   at RazorEngine.Templating.RazorEngineServiceExtensions.RunCompile(IRazorEngineService service, ITemplateSource templateSource, String name, Type modelType, Object model, DynamicViewBag viewBag)
   at Dynamicweb.Rendering.Template.RenderRazorTemplate()

1 @inherits Dynamicweb.Rendering.ViewModelTemplate<Dynamicweb.Frontend.ParagraphViewModel> 2 @using Dynamicweb.Ecommerce.Frontend; 3 @using Dynamicweb.Core; 4 @using System.Linq; 5 6 @inherits Dynamicweb.Rendering.ViewModelTemplate<Dynamicweb.Frontend.ParagraphViewModel> 7 8 @functions { 9 public string columnClass() 10 { 11 if (Model.Item.GetList("WidthMobile").SelectedValue == "hide"){ 12 return "grid__col-lg-" + Model.Item.GetList("Width").SelectedValue + " grid__col-md-" + Model.Item.GetList("Width").SelectedValue + " grid__col-sm-" + Model.Item.GetList("Width").SelectedValue + " u-hidden-xs u-hidden-xxs"; 13 } else { 14 return "grid__col-lg-" + Model.Item.GetList("Width").SelectedValue + " grid__col-md-" + Model.Item.GetList("Width").SelectedValue + " grid__col-sm-" + Model.Item.GetList("Width").SelectedValue + " grid__col-xs-" + Model.Item.GetList("WidthMobile").SelectedValue; 15 } 16 } 17 } 18 19 20 @{ 21 int productCatalogId = GetPageIdByNavigationTag("PromotionFeed"); 22 string feedFullUrl = "/Default.aspx?ID=" + productCatalogId; 23 int paragraphId = Model.ID; 24 25 var products = Model.Item.GetValue("Products") as List<ProductViewModel>; 26 27 feedFullUrl += "&Combinations="; 28 bool onlyPreview = Converter.ToBoolean(Pageview.Area.Item["OnlyPreviewForAnonymous"]) && Pageview.User == null; 29 30 if (products != null) { 31 for (var i = 0; i < products.Count; i++) 32 { 33 feedFullUrl += products[i].Id; 34 feedFullUrl += products[i].VariantId != "" ? "%20" + products[i].VariantId : ""; 35 feedFullUrl += ","; 36 } 37 } else { 38 feedFullUrl = ""; 39 } 40 41 var columnSize = 3; 42 43 if (products.Count == 3) { 44 columnSize = 4; 45 } 46 47 if (products.Count == 2) 48 { 49 columnSize = 6; 50 } 51 52 if (products.Count == 1) 53 { 54 columnSize = 12; 55 } 56 57 switch (Model.Item.GetList("Width").SelectedValue) { 58 case "6": 59 case "4": 60 columnSize = 6; 61 break; 62 case "3": 63 columnSize = 12; 64 break; 65 } 66 } 67 68 <div class="@columnClass()"> 69 <div class="grid js-handlebars-root" id="PromotionProductList_@paragraphId" data-template="PromotionProducts" data-pre-render-template="ProductPreRenderContainer" data-json-feed="@feedFullUrl" data-preloader="minimal"></div> 70 </div> 71 72 <script id="ProductPreRenderContainer" type="text/x-template"> 73 <div class="grid__col-md-@columnSize"> 74 <div class="pre-render-element pre-render-element--md"></div> 75 </div> 76 <div class="grid__col-md-@columnSize"> 77 <div class="pre-render-element pre-render-element--md"></div> 78 </div> 79 <div class="grid__col-md-@columnSize"> 80 <div class="pre-render-element pre-render-element--md"></div> 81 </div> 82 <div class="grid__col-md-@columnSize"> 83 <div class="pre-render-element pre-render-element--md"></div> 84 </div> 85 </script> 86 87 88 @* Grid view *@ 89 90 <script id="PromotionProducts" type="text/x-template"> 91 {{#.}} 92 <div class="grid__col-lg-@columnSize grid__col-md-@columnSize grid__col-sm-@columnSize grid__col-xs-6"> 93 <div class="grid__cell product-list__grid-item__image dw-mod {{noImage}}"> 94 <div class="stickers-container dw-mod"> 95 {{#Stickers}} 96 {{>Sticker}} 97 {{/Stickers}} 98 </div> 99 <a href="{{link}}" onclick="Scroll.SavePosition(event)"><img class="grid__cell-img grid__cell-img--centered b-lazy" src="/Files/Images/placeholder.gif" data-src="/Admin/Public/GetImage.ashx?width=300&amp;height=300&amp;crop=5&amp;Compression=75&amp;image={{image}}" alt="{{name}}" /></a> 100 </div> 101 102 <div class="grid__cell product-list__grid-item__price-info {{shortGridInfo}} dw-mod"> 103 <a href="{{link}}" onclick="Scroll.SavePosition(event)" title="{{name}}"><h6>{{name}}</h6></a> 104 <div class="item-number dw-mod">{{number}}</div> 105 @if (!onlyPreview) 106 { 107 <div class="price dw-mod">{{price}}</div> 108 <div class="before-price {{onSale}} dw-mod">{{discount}}</div> 109 } 110 <input type="hidden" id="Quantity_{{id}}" name="Quantity" value="1" min="1"> 111 <input type="hidden" value="{{unitId}}" name="Unit" id="Unit_{{id}}" /> 112 <input type="hidden" value="{{variantid}}" name="VariantID" id="Variant_{{id}}" /> 113 </div> 114 115 <div class="product-list__grid-item__footer dw-mod"> 116 <div class="u-ta-center"> 117 <a href="{{link}}" id="CartButton_{{id}}" class="btn btn--secondary btn--full u-no-margin dw-mod">@Translate("View")</a> 118 </div> 119 </div> 120 </div> 121 {{/.}} 122 123 {{^.}} 124 <div class="grid__col-12"> 125 <h2 class="u-ta-center">@Translate("No products found")</h2> 126 </div> 127 {{/.}} 128 </script> 129 130 <script id="Sticker" type="text/x-template"> 131 <div class="stickers-container__tag {{className}} dw-mod">{{text}}</div> 132 </script>