Error compiling template "Designs/Swift/Paragraph/DiscBuyXAmountAndGetYDiscountDescription.cshtml" Line 58: Cannot use local variable 'DiscBuyXAmountAndGetYDiscount_Text' before it is declared Line 66: The name 'deadlinestring' does not exist in the current context Line 53: The variable 'DiscBuyXAmountAndGetYDiscount' is assigned but its value is never used
1 //------------------------------------------------------------------------------ 2 // <auto-generated> 3 // This code was generated by a tool. 4 // Runtime Version:4.0.30319.42000 5 // 6 // Changes to this file may cause incorrect behavior and will be lost if 7 // the code is regenerated. 8 // </auto-generated> 9 //------------------------------------------------------------------------------ 10 11 namespace CompiledRazorTemplates.Dynamic { 12 using System; 13 using System.Collections.Generic; 14 using System.Linq; 15 16 #line 2 "D:\dynamicweb.net\Solutions\nextech\Superhome.swiftstaging.dynamicweb-cms.com\files\Templates\Designs\Swift\Paragraph\DiscBuyXAmountAndGetYDiscountDescription.cshtml" 17 using Dynamicweb.Ecommerce.ProductCatalog; 18 19 #line default 20 #line hidden 21 22 23 public class RazorEngine_c853e1fce0d94be8bde0cd680a30551f : Dynamicweb.Rendering.ViewModelTemplate<Dynamicweb.Frontend.ParagraphViewModel> { 24 25 #line hidden 26 27 public RazorEngine_c853e1fce0d94be8bde0cd680a30551f() { 28 } 29 30 public override void Execute() { 31 WriteLiteral("\r\n"); 32 33 34 #line 4 "D:\dynamicweb.net\Solutions\nextech\Superhome.swiftstaging.dynamicweb-cms.com\files\Templates\Designs\Swift\Paragraph\DiscBuyXAmountAndGetYDiscountDescription.cshtml" 35 36 ProductViewModel product = null; 37 if (Dynamicweb.Context.Current.Items.Contains("ProductDetails")) 38 { 39 product = (ProductViewModel)Dynamicweb.Context.Current.Items["ProductDetails"]; 40 } 41 else if (Pageview.Page.Item["DummyProduct"] != null && Pageview.IsVisualEditorMode) 42 { 43 var pageViewModel = Dynamicweb.Frontend.ContentViewModelFactory.CreatePageInfoViewModel(Pageview.Page); 44 ProductListViewModel productList = pageViewModel.Item.GetValue("DummyProduct") != null ? pageViewModel.Item.GetValue("DummyProduct") as ProductListViewModel : new ProductListViewModel(); 45 46 if (productList?.Products is object) 47 { 48 product = productList.Products[0]; 49 } 50 } 51 52 53 string DiscBuyXAmountAndGetYDiscount = ""; 54 foreach (var p in product.ProductFields) 55 { 56 if (p.Key == "DiscBuyXAmountAndGetYDiscount" && p.Value != null) 57 { 58 DiscBuyXAmountAndGetYDiscount_Text = p.Value.ToString(); 59 break; 60 } 61 } 62 63 //TODO split based on $ character DiscBuyXAmountAndGetYDiscount_Text 64 string DiscBuyXAmountAndGetYDiscount_Text = "Buy 30 euros worth of products and get this for"; 65 string DiscBuyXAmountAndGetYDiscount_percentage = "€ 5.25"; 66 var DiscBuyXAmountAndGetYDiscount_TextAndPercentage = deadlinestring.Split(":".ToCharArray()); 67 if (DiscBuyXAmountAndGetYDiscount_TextAndPercentage.Length == 2) 68 { 69 if (!string.IsNullOrWhiteSpace(DiscBuyXAmountAndGetYDiscount_TextAndPercentage[0])) 70 { 71 DiscBuyXAmountAndGetYDiscount_Text = DiscBuyXAmountAndGetYDiscount_TextAndPercentage[0]; 72 } 73 if (!string.IsNullOrWhiteSpace(DiscBuyXAmountAndGetYDiscount_TextAndPercentage[1])) 74 { 75 DiscBuyXAmountAndGetYDiscount_percentage = DiscBuyXAmountAndGetYDiscount_TextAndPercentage[1]; 76 } 77 } 78 79 80 #line default 81 #line hidden 82 WriteLiteral("\r\n\r\n\r\n"); 83 84 85 #line 50 "D:\dynamicweb.net\Solutions\nextech\Superhome.swiftstaging.dynamicweb-cms.com\files\Templates\Designs\Swift\Paragraph\DiscBuyXAmountAndGetYDiscountDescription.cshtml" 86 if (product is object) 87 { 88 89 string fontsize = Model.Item.GetRawValueString("Font_Size", "12px"); 90 91 92 93 94 #line default 95 #line hidden 96 WriteLiteral(" <div"); 97 98 WriteLiteral(" class=\"DiscBuyXAmountAndGetYDiscount_Container\""); 99 100 WriteLiteral(">\r\n"); 101 102 103 #line 57 "D:\dynamicweb.net\Solutions\nextech\Superhome.swiftstaging.dynamicweb-cms.com\files\Templates\Designs\Swift\Paragraph\DiscBuyXAmountAndGetYDiscountDescription.cshtml" 104 105 106 #line default 107 #line hidden 108 109 #line 57 "D:\dynamicweb.net\Solutions\nextech\Superhome.swiftstaging.dynamicweb-cms.com\files\Templates\Designs\Swift\Paragraph\DiscBuyXAmountAndGetYDiscountDescription.cshtml" 110 if(!string.IsNullOrWhiteSpace(DiscBuyXAmountAndGetYDiscount_Text) && !string.IsNullOrWhiteSpace(DiscBuyXAmountAndGetYDiscount_percentage)) 111 { 112 113 114 #line default 115 #line hidden 116 WriteLiteral(" <div"); 117 118 WriteLiteral(" style=\"width:100%\""); 119 120 WriteLiteral(" class=\"DiscBuyXAmountAndGetYDiscount\""); 121 122 WriteAttribute("style", Tuple.Create(" style=\"", 2384), Tuple.Create("\"", 2401) 123 124 #line 59 "D:\dynamicweb.net\Solutions\nextech\Superhome.swiftstaging.dynamicweb-cms.com\files\Templates\Designs\Swift\Paragraph\DiscBuyXAmountAndGetYDiscountDescription.cshtml" 125 , Tuple.Create(Tuple.Create("", 2392), Tuple.Create<System.Object, System.Int32>(fontsize 126 127 #line default 128 #line hidden 129 , 2392), false) 130 ); 131 132 WriteLiteral(">"); 133 134 135 #line 59 "D:\dynamicweb.net\Solutions\nextech\Superhome.swiftstaging.dynamicweb-cms.com\files\Templates\Designs\Swift\Paragraph\DiscBuyXAmountAndGetYDiscountDescription.cshtml" 136 Write(DiscBuyXAmountAndGetYDiscount_Text); 137 138 139 #line default 140 #line hidden 141 WriteLiteral(" "); 142 143 144 #line 59 "D:\dynamicweb.net\Solutions\nextech\Superhome.swiftstaging.dynamicweb-cms.com\files\Templates\Designs\Swift\Paragraph\DiscBuyXAmountAndGetYDiscountDescription.cshtml" 145 Write(DiscBuyXAmountAndGetYDiscount_percentage); 146 147 148 #line default 149 #line hidden 150 WriteLiteral("</div>\r\n"); 151 152 153 #line 60 "D:\dynamicweb.net\Solutions\nextech\Superhome.swiftstaging.dynamicweb-cms.com\files\Templates\Designs\Swift\Paragraph\DiscBuyXAmountAndGetYDiscountDescription.cshtml" 154 } 155 156 157 #line default 158 #line hidden 159 WriteLiteral(" </div>\r\n"); 160 161 162 #line 62 "D:\dynamicweb.net\Solutions\nextech\Superhome.swiftstaging.dynamicweb-cms.com\files\Templates\Designs\Swift\Paragraph\DiscBuyXAmountAndGetYDiscountDescription.cshtml" 163 } 164 else if (Pageview.IsVisualEditorMode) 165 { 166 167 168 #line default 169 #line hidden 170 WriteLiteral("\t<div"); 171 172 WriteLiteral(" class=\"alert alert-dark m-0\""); 173 174 WriteLiteral(" role=\"alert\""); 175 176 WriteLiteral(">\r\n\t\t<span>"); 177 178 179 #line 66 "D:\dynamicweb.net\Solutions\nextech\Superhome.swiftstaging.dynamicweb-cms.com\files\Templates\Designs\Swift\Paragraph\DiscBuyXAmountAndGetYDiscountDescription.cshtml" 180 Write(Translate("No products available")); 181 182 183 #line default 184 #line hidden 185 WriteLiteral("</span>\r\n\t</div>\r\n"); 186 187 188 #line 68 "D:\dynamicweb.net\Solutions\nextech\Superhome.swiftstaging.dynamicweb-cms.com\files\Templates\Designs\Swift\Paragraph\DiscBuyXAmountAndGetYDiscountDescription.cshtml" 189 } 190 191 #line default 192 #line hidden 193 } 194 } 195 } 196
1 @inherits Dynamicweb.Rendering.ViewModelTemplate<Dynamicweb.Frontend.ParagraphViewModel> 2 @using Dynamicweb.Ecommerce.ProductCatalog 3 4 @{ 5 ProductViewModel product = null; 6 if (Dynamicweb.Context.Current.Items.Contains("ProductDetails")) 7 { 8 product = (ProductViewModel)Dynamicweb.Context.Current.Items["ProductDetails"]; 9 } 10 else if (Pageview.Page.Item["DummyProduct"] != null && Pageview.IsVisualEditorMode) 11 { 12 var pageViewModel = Dynamicweb.Frontend.ContentViewModelFactory.CreatePageInfoViewModel(Pageview.Page); 13 ProductListViewModel productList = pageViewModel.Item.GetValue("DummyProduct") != null ? pageViewModel.Item.GetValue("DummyProduct") as ProductListViewModel : new ProductListViewModel(); 14 15 if (productList?.Products is object) 16 { 17 product = productList.Products[0]; 18 } 19 } 20 21 22 string DiscBuyXAmountAndGetYDiscount = ""; 23 foreach (var p in product.ProductFields) 24 { 25 if (p.Key == "DiscBuyXAmountAndGetYDiscount" && p.Value != null) 26 { 27 DiscBuyXAmountAndGetYDiscount_Text = p.Value.ToString(); 28 break; 29 } 30 } 31 32 //TODO split based on $ character DiscBuyXAmountAndGetYDiscount_Text 33 string DiscBuyXAmountAndGetYDiscount_Text = "Buy 30 euros worth of products and get this for"; 34 string DiscBuyXAmountAndGetYDiscount_percentage = "€ 5.25"; 35 var DiscBuyXAmountAndGetYDiscount_TextAndPercentage = deadlinestring.Split(":".ToCharArray()); 36 if (DiscBuyXAmountAndGetYDiscount_TextAndPercentage.Length == 2) 37 { 38 if (!string.IsNullOrWhiteSpace(DiscBuyXAmountAndGetYDiscount_TextAndPercentage[0])) 39 { 40 DiscBuyXAmountAndGetYDiscount_Text = DiscBuyXAmountAndGetYDiscount_TextAndPercentage[0]; 41 } 42 if (!string.IsNullOrWhiteSpace(DiscBuyXAmountAndGetYDiscount_TextAndPercentage[1])) 43 { 44 DiscBuyXAmountAndGetYDiscount_percentage = DiscBuyXAmountAndGetYDiscount_TextAndPercentage[1]; 45 } 46 } 47 } 48 49 50 @if (product is object) 51 { 52 53 string fontsize = Model.Item.GetRawValueString("Font_Size", "12px"); 54 55 56 <div class="DiscBuyXAmountAndGetYDiscount_Container"> 57 @if(!string.IsNullOrWhiteSpace(DiscBuyXAmountAndGetYDiscount_Text) && !string.IsNullOrWhiteSpace(DiscBuyXAmountAndGetYDiscount_percentage)) 58 { 59 <div style="width:100%" class="DiscBuyXAmountAndGetYDiscount" style="@fontsize">@DiscBuyXAmountAndGetYDiscount_Text @DiscBuyXAmountAndGetYDiscount_percentage</div> 60 } 61 </div> 62 } 63 else if (Pageview.IsVisualEditorMode) 64 { 65 <div class="alert alert-dark m-0" role="alert"> 66 <span>@Translate("No products available")</span> 67 </div> 68 }
PENTOOLS ΑΝΕΞΙΤΗΛΟΣ ΜΑΡΚΑΔΟΡΟΣ 1.0MM 4TMX
0251617
Ένας υψηλής ποιότητας μαρκαδόρος για όλες τις χρήσεις με στιβαρό άκρο που είναι εξαιρετικά ανθεκτικό, ακόμη και όταν χρησιμοποιείται σε τραχιές επιφάνειες. Το περίβλημα από αλουμίνιο είναι αρκετά ανθεκτικό ώστε να συσφίγγεται σε εργαλειομηχανές. Το στιβαρό και μακράς διαρκείας στυλό Pentel είναι η τέλεια επιλογή για όλες τις εργασίες όπου απαιτείται υψηλή απόδοση και αξιοπιστία. Η εξαιρετικά λεπτή στρογγυλή μύτη είναι ιδανική για ακριβή σήμανση και γραφή – είτε για ειδικευμένους επαγγελματίες είτε για έργα DIY και χόμπι. Το μελάνι στεγνώνει γρήγορα, αδιάβροχο και ανθεκτικό σε πολλούς διαλύτες και ιδανικό για χρήση σε λιπαρές, σκονισμένες, υγρές ή βρώμικες επιφάνειες, καθώς και σε μεγάλη γκάμα υλικών όπως γυαλί, μέταλλο, ξύλο και πλαστικό. Το blister περιέχει: 4x δείκτες (2x μαύρο, 1x κόκκινο, 1x μπλε).
Σε απόθεμα
Λεπτομέρειες
- Barcode
- 4016284345863
- Μάρκα
- PenTools
- Σε Προσφορά
- No
- Supplier Item
- N50S-PRO4ABCEU
- Κατηγορία
- Μαρκαδόροι, Πέννες και Μολύβια
- Βάρος
- 30g
Παρόμοια Προϊόντα
Άλλοι πελάτες επίσης αγοράζουν