Rijpaard (springen en dressuur)














Tuigpaard





Gelders paard


Jong KWPN



Toepassen

KWPN-merchandise

De vernieuwde KWPN-merchandise zoals vesten, broeken en polo's shop je via onze aparte merchandise-webshop.

Bekijk de collectie
Error executing template "Designs/Kwpn/eCom/Product/Product.cshtml"
System.IO.IOException: The process cannot access the file 'D:\inetpub\wwwroot\www.kwpn.nl\Files\Templates\Designs\Kwpn\Translations.xml' because it is being used by another process.
at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost)
at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share)
at Dynamicweb.Rendering.Translation.Source.WriteDocument(XmlDocument document)
at Dynamicweb.Rendering.Translation.Source.Save()
at Dynamicweb.Rendering.Translation.Source.UpdateTranslationSource(Source source, IEnumerable`1 newKeys, String designName, IEnumerable`1 cultures)
at Dynamicweb.Rendering.Template.TranslateText(String text, String defaultValue, String cultureName)
at Dynamicweb.Rendering.TemplateBase`1.Translate(String text, String defaultValue)
at CompiledRazorTemplates.Dynamic.RazorEngine_38ec07dbd28b406096f7e1a302420eb8.Execute() in D:\inetpub\wwwroot\www.kwpn.nl\Files\Templates\Designs\Kwpn\eCom\Product\Product.cshtml:line 351
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.<RunCompile>b__0(TextWriter writer)
at RazorEngine.Templating.RazorEngineServiceExtensions.WithWriter(Action`1 withWriter)
at Dynamicweb.Rendering.RazorTemplateRenderingProvider.Render(Template template)
at Dynamicweb.Rendering.TemplateRenderingService.Render(Template template)
at Dynamicweb.Rendering.Template.RenderRazorTemplate()

1 @inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> 2 @using System 3 @using Kwpn.Repository.Helpers; 4 @using System.Globalization; 5 @using Kwpn.Models.Constants 6 @using Kwpn.Repository.Repositories; 7 @{ 8 var isAddToCart = System.Web.HttpContext.Current.Request.Form != null && 9 System.Web.HttpContext.Current.Request.Form.Get("CustomCartCmd") != null && 10 System.Web.HttpContext.Current.Request.Form.Get("CustomCartCmd").Equals("add"); 11 if (isAddToCart) 12 { 13 var result = OrderHelper.AddToCartWebshop(); 14 <p>@result</p> 15 } 16 else 17 { 18 var culture = GetGlobalValue("Global:Area.LongLang"); 19 var jsCulture = new CultureInfo("en-US"); 20 var language = GetGlobalValue("Global:Area.Lang"); 21 var isLoggedIn = LoginHelper.CurrentUserIsLoggedIn() && !Kwpn.Repository.Repositories.KwpnUsers.CurrentUser().IsBlocked; 22 string requestHost = AreaHelper.GetHost(); 23 var countries = Kwpn.Repository.EquisApi.Countries.GetCountries(); 24 var cartUrl = AreaHelper.CreateUrlBySystemName(StringConstants.PageIdSystemNames.CartPageId); 25 26 // product info 27 string productName = GetString("Ecom:Product.Name"); 28 string productId = GetString("Ecom:Product.ID"); 29 string productVariantId = GetString("Ecom:Product.VariantID"); 30 string productDescription = GetString("Ecom:Product.LongDescription"); 31 string productImage = GetString("Ecom:Product.ImageLarge.Default.Clean"); 32 double productPrice = GetDouble("Ecom:Product.DBPrice"); 33 double productMemberPrice = ProductHelper.GetWebshopProductCategoryField<Double>(StringConstants.ProductCategoryField.MemberPrice, productId, productVariantId, culture); 34 double productShipmentFeeBeNeLux = ProductHelper.GetWebshopProductCategoryField<Double>(StringConstants.ProductCategoryField.ShipmentFeeBeNeLux, productId, productVariantId, culture); 35 double productShipmentFeeWorldWide = ProductHelper.GetWebshopProductCategoryField<Double>(StringConstants.ProductCategoryField.ShipmentFeeWorldWide, productId, productVariantId, culture); 36 string productExtraFormFieldLabel = ProductHelper.GetWebshopProductCategoryField<string>(StringConstants.ProductCategoryField.WebshopExtraFormFieldLabel, productId, productVariantId, culture); 37 string productExtraFormFieldType = ProductHelper.GetWebshopProductCategoryField<string>(StringConstants.ProductCategoryField.WebshopExtraFormFieldType, productId, productVariantId, culture); 38 39 // member info 40 string membershipNumber = "", userId = "", userName = "", userAddress = "", userHouseNr = "", userPostalCode = "", userCity = "", userPhone = "", userEmail = "", userCountryCode = ""; 41 if (isLoggedIn) 42 { 43 var dwUser = KwpnUsers.CurrentUser().DwUser; 44 membershipNumber = dwUser.UserName; 45 userId = dwUser.ID.ToString(); 46 userName = dwUser.Name; 47 userAddress = dwUser.Address; 48 userHouseNr = dwUser.HouseNumber; 49 userPostalCode = dwUser.Zip; 50 userCity = dwUser.City; 51 userPhone = dwUser.Phone; 52 userEmail = dwUser.Email; 53 userCountryCode = dwUser.CountryCode; 54 if (string.IsNullOrWhiteSpace(userCountryCode)) 55 { 56 userCountryCode = dwUser.Country; 57 } 58 } 59 60 var defaultDeliveryCountryCode = !string.IsNullOrWhiteSpace(userCountryCode) ? userCountryCode : "NL"; // NL is het default geselecteerde land 61 62 <div class="break-grid content-container page-content-aside webshop"> 63 <div class="break-grid-background"> 64 <div class="in-grid"> 65 <div class="row"> 66 67 <div class="background-head-aside-xs"> 68 69 <div class="background-head-xs hidden-xs hidden-sm"> 70 <div class="page-header"> 71 <div class="col-xs-12"> 72 <div class="row"> 73 <div class="col-xs-12"> 74 <h1>@productName</h1> 75 </div> 76 </div> 77 </div> 78 </div> 79 </div> 80 81 <div class="background-aside-xs"> 82 83 <aside class="col-xs-12 col-md-4 col-md-push-8 page-aside"> 84 85 <h2 id="webshop-product-aside-info-header" data-childId="webshop-product-aside-info" class="notactive"><span>@Translate("Information", "Information")</span></h2> 86 <table id="webshop-product-aside-info" class="aside-content aside-content-info notactive"> 87 <colgroup> 88 <col width="30" /> 89 <col /> 90 </colgroup> 91 <tr class="head"> 92 <th><i class="fa fa-info"></i></th> 93 <th>@Translate("Product", "Product")</th> 94 </tr> 95 <tr> 96 <td>&nbsp;</td> 97 <td>@productName</td> 98 </tr> 99 <tr class="head"> 100 <th><i class="fa fa-cc"></i></th> 101 <th>@Translate("PaymentMethod", "Payment method")</th> 102 </tr> 103 <tr> 104 <td>&nbsp;</td> 105 <td>@Translate("PaymentMethod_Text_Online", "Pay directly online")</td> 106 </tr> 107 <tr class="head"> 108 <th><i class="fa fa-eur"></i></th> 109 <th>@Translate("Costs", "Costs")</th> 110 </tr> 111 <tr> 112 <td>&nbsp;</td> 113 <td> 114 <span id="webshop-product-subtotal"><!--value is set by javascript based on form selection--></span> 115 <span id="webshop-product-shipment"><!--value is set by javascript based on form selection--></span> 116 <span id="webshop-product-total"><!--value is set by javascript based on form selection--></span> (@Translate("VatIncluded", "VAT included")) 117 </td> 118 </tr> 119 </table> 120 121 @if (!isLoggedIn) 122 { 123 var memberhipPageId = AreaHelper.GetAreaItemStringValueBySystemName(Kwpn.Models.Constants.StringConstants.PageIdSystemNames.BecomeMemberPageId); 124 if (!string.IsNullOrWhiteSpace(memberhipPageId)) 125 { 126 var becomeMemberUrl = string.Format("/Default.aspx?ID={0}", memberhipPageId); 127 128 <div id="horse-detail-aside-become-member"> 129 <div class="info-wrapper"> 130 <h3>@Translate("NoMyKwpnAccount", "No My KWPN account?")</h3> 131 <p> 132 <br /><a href="@becomeMemberUrl" class="orange_balloon_link">@Translate("BecomeMemberNow", "Become member now")</a> 133 </p> 134 </div> 135 </div> 136 } 137 } 138 139 </aside> 140 </div> 141 </div> 142 143 <article class="col-xs-12 col-md-7 col-md-pull-4 page-content"> 144 145 <div class="w-section inverse"> 146 <div class="w-box sign-in-wr bg-5"> 147 <div id="WebshopProductDetail" class="form-body"> 148 <form name="ProductOrderForm" method="POST" class="js-cartForm"> 149 <input name="CustomCartCmd" id="CustomCartCmd" value="add" type="hidden"> 150 <input name="VariantID" id="VariantID" value="@productVariantId" type="hidden"> 151 <input name="ProductID" id="ProductID" value="@productId" type="hidden"> 152 <input name="Culture" id="Culture" value="@culture" type="hidden"> 153 <input name="Kwpn_Product_DeliveryAddress_CountryCode" id="Kwpn_Product_DeliveryAddress_CountryCode" value="@defaultDeliveryCountryCode" type="hidden"> @* wordt overschreven als de landselectie select wordt gebruikt *@ 154 <div class="row webshopProduct" 155 data-productid="@productId" 156 data-variantid="@productVariantId"> 157 158 @if (!string.IsNullOrWhiteSpace(productImage)) 159 { 160 <div class="col-xs-12 col-md-4"> 161 <img src="@string.Format("{0}{1}", requestHost, productImage)" /> 162 </div> 163 } 164 165 <div class="col-xs-12 @(string.IsNullOrWhiteSpace(productImage) ? "" : "col-md-7 col-md-push-1")"> 166 167 <h2 class="hidden-md hidden-lg">@productName</h2> 168 169 @if (productPrice.Equals(productMemberPrice) || productMemberPrice <= 0) 170 { 171 <div class="productPrice">@ProductHelper.FormatPrice(productPrice)</div> 172 } 173 else 174 { 175 if (LoginHelper.IsEntitledToWebshopDiscount() && isLoggedIn) 176 { 177 <div class="productPrice">@ProductHelper.FormatPrice(productMemberPrice)</div> 178 } 179 else 180 { 181 <div class="productPrice">@ProductHelper.FormatPrice(productPrice) <span class="memberProductPrice pull-right">@Translate("MemberPrice", "Members pay:") @ProductHelper.FormatPrice(productMemberPrice)</span></div> 182 } 183 } 184 185 @if (!string.IsNullOrWhiteSpace(productDescription)) 186 { 187 <div class="productDescription">@productDescription</div> 188 } 189 190 <div class="form-group"> 191 <div class="form-inline selectdiv"> 192 <label class="control-label col-sm-4" for="Kwpn_Product_Quantity">@Translate("ProductQuantity", "Quantity")</label> 193 <select id="Kwpn_Product_Quantity" name="Kwpn_Product_Quantity" class="form-control input-md" required> 194 @for (int i = 1; i <= 20; i++) 195 { 196 <option value="@i">@i</option> 197 } 198 </select> 199 </div> 200 </div> 201 202 </div> 203 </div> 204 205 <h3>@(isLoggedIn ? Translate("MembershipData", "Membership data") : Translate("YourData", "Your data"))</h3> 206 207 208 <div class="form-group"> 209 <div class="form-inline @(!isLoggedIn ? "hidden" : "")"> 210 <label class="control-label col-sm-4" for="Kwpn_Product_AccessUserName">@Translate("MembershipNumber")</label> 211 <input type="text" class="form-control" id="Kwpn_Product_AccessUserName" name="Kwpn_Product_AccessUserName" value="@membershipNumber" @(isLoggedIn ? "readonly required" : "") /> 212 </div> 213 <div class="form-inline"> 214 <label class="control-label col-sm-4" for="Kwpn_Product_Name">@(!isLoggedIn ? Translate("InitialsAndName", "Initials and Name") : Translate("Name", "Name"))</label> 215 <input type="text" class="form-control hide-hints" id="Kwpn_Product_Name" name="Kwpn_Product_Name" value="@userName" @(isLoggedIn ? "readonly" : "") required /> 216 </div> 217 <div class="form-inline"> 218 <label class="control-label col-sm-4" for="Kwpn_Product_Address">@Translate("Address")</label> 219 <input type="text" class="form-control hide-hints" id="Kwpn_Product_Address" name="Kwpn_Product_Address" value="@userAddress" @(isLoggedIn && !string.IsNullOrWhiteSpace(userAddress) ? "readonly" : "") required /> 220 </div> 221 <div class="form-inline"> 222 <label class="control-label col-sm-4" for="Kwpn_Product_HouseNumber">@Translate("HouseNumber")</label> 223 <input type="text" class="form-control hide-hints" id="Kwpn_Product_HouseNumber" maxlength="10" name="Kwpn_Product_HouseNumber" value="@userHouseNr" @(isLoggedIn && !string.IsNullOrWhiteSpace(userHouseNr) ? "readonly" : "") @if (culture.Equals("nl-NL", StringComparison.InvariantCultureIgnoreCase)) { <text> required</text>} /> 224 </div> 225 <div class="form-inline"> 226 <label class="control-label col-sm-4" for="Kwpn_Product_ZipCode">@Translate("PostalCode")</label> 227 <input type="text" class="form-control hide-hints" id="Kwpn_Product_ZipCode" maxlength="10" name="Kwpn_Product_ZipCode" value="@userPostalCode" @(isLoggedIn && !string.IsNullOrWhiteSpace(userPostalCode) ? "readonly" : "") required /> 228 </div> 229 <div class="form-inline"> 230 <label class="control-label col-sm-4" for="Kwpn_Product_City">@Translate("Place")</label> 231 <input type="text" class="form-control hide-hints" id="Kwpn_Product_City" name="Kwpn_Product_City" value="@userCity" @(isLoggedIn && !string.IsNullOrWhiteSpace(userCity) ? "readonly" : "") required /> 232 </div> 233 <div class="form-inline"> 234 <label class="control-label col-sm-4" for="Kwpn_Product_TelephoneNumber">@Translate("Phone")</label> 235 <input type="tel" class="form-control hide-hints" id="Kwpn_Product_TelephoneNumber" name="Kwpn_Product_TelephoneNumber" value="@userPhone" @(isLoggedIn && !string.IsNullOrWhiteSpace(userPhone) ? "readonly" : "") required /> 236 </div> 237 <div class="form-inline"> 238 <label class="control-label col-sm-4" for="Kwpn_Product_EmailAddress">@Translate("Email_address")</label> 239 <input type="email" class="form-control hide-hints" id="Kwpn_Product_EmailAddress" name="Kwpn_Product_EmailAddress" value="@userEmail" @(isLoggedIn && !string.IsNullOrWhiteSpace(userEmail) ? "readonly" : "") required /> 240 </div> 241 @if (!string.IsNullOrWhiteSpace(productExtraFormFieldLabel)) 242 { 243 <div class="form-inline"> 244 <label class="control-label col-sm-4" for="Kwpn_Product_ExtraFormField">@FormatHelpers.ReplaceNewlineWithBr(productExtraFormFieldLabel)</label> 245 <input type="hidden" id="Kwpn_Product_ExtraFormFieldLabel" name="Kwpn_Product_ExtraFormFieldLabel" value="@productExtraFormFieldLabel.HtmlRemove()" /> 246 @if (productExtraFormFieldType.Equals("LongText")) 247 { 248 <textarea class="form-control hide-hints" id="Kwpn_Product_ExtraFormField" name="Kwpn_Product_ExtraFormField" required></textarea> 249 } 250 else 251 { 252 <input type="text" class="form-control hide-hints" id="Kwpn_Product_ExtraFormField" name="Kwpn_Product_ExtraFormField" value="" required /> 253 } 254 </div> 255 } 256 </div> 257 258 <br /> 259 <br /> 260 261 <h3>@Translate("DeliveryAddress", "Delivery address")</h3> 262 263 <div class="form-group"> 264 265 @*COUNTRY*@ 266 <div class="form-inline selectdiv"> 267 <label class="control-label col-sm-4" for="Kwpn_Product_DeliveryAddress_Country">@Translate("Country", "Country")</label> 268 <select class="form-control hide-hints capitalize" name="Kwpn_Product_DeliveryAddress_Country" id="Kwpn_Product_DeliveryAddress_Country" required> 269 <option value="" data-code="" @(string.IsNullOrWhiteSpace(userCountryCode) ? "selected" : "")>@Translate("Select")</option> 270 @foreach (var country in countries.OrderBy(c => c.CountryName)) 271 { 272 <option value="@country.CountryName.ToUpper()" data-code="@country.CountryCode" class="capitalize" @(userCountryCode.Equals(country.CountryCode, StringComparison.InvariantCultureIgnoreCase) ? "selected" : "")>@country.CountryName</option> 273 } 274 </select> 275 </div> 276 277 @*ADDRESS*@ 278 <div class="form-inline"> 279 <label class="control-label col-sm-4" for="Kwpn_Product_DeliveryAddress_Address">@Translate("Address", "Address")</label> 280 <input type="text" class="form-control hide-hints" id="Kwpn_Product_DeliveryAddress_Address" name="Kwpn_Product_DeliveryAddress_Address" value="@userAddress" required /> 281 </div> 282 283 @*HOUSE NUMBER*@ 284 <div class="form-inline"> 285 <label class="control-label col-sm-4" for="Kwpn_Product_DeliveryAddress_HouseNumber">@Translate("HouseNumber", "House number") <small>(+@Translate("Addition", "Addition"))</small></label> 286 <input type="text" class="form-control input-md hide-hints" id="Kwpn_Product_DeliveryAddress_HouseNumber" maxlength="10" name="Kwpn_Product_DeliveryAddress_HouseNumber" value="@userHouseNr" @if (culture.Equals("nl-NL", StringComparison.InvariantCultureIgnoreCase)){<text> required</text>} /> 287 <input type="text" class="form-control input-sm" id="Kwpn_Product_DeliveryAddress_HouseNumber_Addition" name="Kwpn_Product_DeliveryAddress_HouseNumber_Addition" value="" style="width: 70px" /> 288 </div> 289 290 @*ZIP*@ 291 <div class="form-inline"> 292 <label class="control-label col-sm-4" for="Kwpn_Product_DeliveryAddress_ZIP">@Translate("PostalCode", "Postal code")</label> 293 <input type="text" class="form-control text-uppercase hide-hints" id="Kwpn_Product_DeliveryAddress_ZIP" maxlength="10" name="Kwpn_Product_DeliveryAddress_ZIP" value="@userPostalCode" required /> 294 </div> 295 296 @*CITY*@ 297 <div class="form-inline"> 298 <label class="control-label col-sm-4" for="Kwpn_Form_BecomeMember_City">@Translate("Place", "Place")</label> 299 <input type="text" class="form-control hide-hints" id="Kwpn_Product_DeliveryAddress_City" name="Kwpn_Product_DeliveryAddress_City" value="@userCity" required /> 300 </div> 301 302 </div> 303 304 <button class="hidden" type="submit" id="form-submitter">@Translate("Pay")</button> 305 306 <br /> 307 <br /> 308 309 <div class="row"> 310 <div class="col-xs-12 form-order-overview"> 311 <h2>@Translate("OrderOverview", "Order overview")</h2> 312 <table> 313 <colgroup> 314 <col width="30" /> 315 <col /> 316 </colgroup> 317 <tr class="head"> 318 <th><i class="fa fa-info"></i></th> 319 <th>@Translate("Product", "Product")</th> 320 </tr> 321 <tr> 322 <td>&nbsp;</td> 323 <td>@productName</td> 324 </tr> 325 <tr class="head"> 326 <th><i class="fa fa-cc"></i></th> 327 <th>@Translate("PaymentMethod", "Payment method")</th> 328 </tr> 329 <tr> 330 <td>&nbsp;</td> 331 <td>@Translate("PaymentMethod_Text_Online", "Pay directly online")</td> 332 </tr> 333 <tr class="head"> 334 <th><i class="fa fa-eur"></i></th> 335 <th>@Translate("Costs", "Costs")</th> 336 </tr> 337 <tr> 338 <td>&nbsp;</td> 339 <td> 340 <span id="webshop-product-footer-subtotal"><!--value is set by javascript based on form selection--></span> 341 <span id="webshop-product-footer-shipment"><!--value is set by javascript based on form selection--></span> 342 <span id="webshop-product-footer-total"><!--value is set by javascript based on form selection--></span> (@Translate("VatIncluded", "VAT included")) 343 </td> 344 </tr> 345 <tr class="conditions"> 346 <td><input type="checkbox" class="form-control agreement-checkbox" id="Kwpn_Product_AgreedWithConditions" name="Kwpn_Product_AgreedWithConditions" required /></td> 347 <td><label for="Kwpn_Product_AgreedWithConditions">@FormHelper.GetAgreeWithConditionsText(Kwpn.Models.Enumerations.FormType.WebshopProduct)</label></td> 348 </tr> 349 <tr class="conditions"> 350 <td><input type="checkbox" class="form-control agreement-checkbox" id="Kwpn_Product_AgreedWithPrivacy" name="Kwpn_Product_AgreedWithPrivacy" required /></td> 351 <td><label for="Kwpn_Product_AgreedWithPrivacy">@Translate("AgreeWithPrivacyStatement", "I agree with the conditions stated in the privacy statement page")</label></td> 352 </tr> 353 <tr> 354 <td colspan="2"><button class="submitBtn" type="button" onclick='$("#form-submitter").click();' data-default="@Translate("Pay")">@Translate("Pay")</button></td> 355 </tr> 356 </table> 357 </div> 358 </div> 359 360 </form> 361 362 </div> 363 </div> 364 </div> 365 366 </article> 367 368 </div> 369 </div> 370 </div> 371 </div> 372 373 <div class="modal fade" id="dialog-post-failed" tabindex="-1" role="dialog" aria-labelledby="dialog-post-failed-modal" aria-hidden="true"> 374 <div class="modal-dialog"> 375 <div class="modal-content"> 376 <div class="modal-body">@Translate("formPostAddToCartFailed", "The add to cart action failed. Please try again or contact Kwpn.")</div> 377 <div class="modal-footer"> 378 <a class="orange_arrow_link modal-ok" data-dismiss="modal" href="javascript:void(0);">@Translate("Ok", "Ok")</a> 379 </div> 380 </div> 381 </div> 382 </div> 383 384 <div id="dialog-post-failed" class="dialog"> 385 <p></p> 386 </div> 387 388 @SnippetStart("JavascriptsBottom") 389 <script> 390 //Place asterisks after required labels 391 $(document).ready(function() { 392 393 $('input,textarea,select') 394 .filter('[required]:visible') 395 .closest(".form-inline") 396 .children("label") 397 .append("<i class=\"fa fa-asterisk\" aria-hidden=\"true\"></i>"); 398 399 $("#Kwpn_Product_Quantity").change(function() { 400 ReCalculate(); 401 }); 402 403 $("#Kwpn_Product_DeliveryAddress_Country").change(function() { 404 ReCalculate(); 405 }); 406 407 // force orange borders 408 $(".hide-hints").change(function() { 409 $(this).removeClass("hide-hints"); 410 }); 411 412 // try to set country default to user country 413 if ("@userCountryCode" != "") { 414 var defaultValue = $("#Kwpn_Product_DeliveryAddress_Country").find("[data-code=@userCountryCode]").val(); 415 $("#Kwpn_Product_DeliveryAddress_Country").val(defaultValue); 416 } else { 417 var defaultValue = $("#Kwpn_Product_DeliveryAddress_Country").find("[data-code=NL]").val(); 418 $("#Kwpn_Product_DeliveryAddress_Country").val(defaultValue); 419 } 420 421 $("#form-submitter").click(function() { 422 423 //disable submit button 424 var submitButtonDefault = $(".submitBtn").attr("data-default"); 425 $(".submitBtn").html(submitButtonDefault + " <i class='fa fa-spinner fa-spin'></i>"); 426 $(".submitBtn").prop('disabled', true); 427 428 // set country code 429 $("#Kwpn_Product_DeliveryAddress_CountryCode").val($("#Kwpn_Product_DeliveryAddress_Country").find(':selected').attr('data-code')); 430 431 var $ProductOrderForm = $("#ProductOrderForm")[0]; 432 if (!ProductOrderForm.checkValidity()) { 433 434 //validate input 435 $(':input[required]', $ProductOrderForm).each(function () { 436 if (this.value.trim() === '') { 437 $(this).css('border', '2px solid #F77C00'); 438 validated = false; 439 } 440 }); 441 442 $(".submitBtn").html(submitButtonDefault); 443 $(".submitBtn").prop('disabled', false); 444 } 445 446 $(".hide-hints").removeClass("hide-hints"); 447 }); 448 449 ReCalculate(); 450 451 }); 452 453 function ReCalculate() { 454 455 // quantity 456 var quantity = parseInt($("#Kwpn_Product_Quantity").val()); 457 if (isNaN(quantity)) { 458 quantity = 1; 459 } 460 461 var price = 0.0; 462 @if (LoginHelper.IsEntitledToWebshopDiscount() && isLoggedIn && productMemberPrice > 0) 463 { 464 <text>price = @productMemberPrice.ToString().Replace(',', '.');</text> 465 } 466 else 467 { 468 <text>price = @productPrice.ToString().Replace(',', '.');</text> 469 } 470 471 var shipment = 0.0; 472 var selectedCountryCode = $("#Kwpn_Product_DeliveryAddress_Country").find(':selected').attr("data-code"); 473 var beNeLux = ["NL", "BE", "LU"]; 474 if (jQuery.inArray(selectedCountryCode, beNeLux) !== -1) { 475 shipment = @productShipmentFeeBeNeLux.ToString().Replace(',', '.'); 476 } else { 477 shipment = @productShipmentFeeWorldWide.ToString().Replace(',', '.'); 478 } 479 480 var subtotal = quantity * price; 481 var total = subtotal + shipment; 482 483 $("#webshop-product-subtotal").html('@Translate("Subtotal", "Sub total"): ' + CreatePrice(subtotal, '@culture') + '<br />'); 484 $("#webshop-product-shipment").html('@Translate("Shipment", "Shipment"): ' + CreatePrice(shipment, '@culture') + '<br />'); 485 $("#webshop-product-total").html('@Translate("Total", "Total"): ' + CreatePrice(total, '@culture')); 486 $("#webshop-product-footer-subtotal").html('@Translate("Subtotal", "Sub total"): ' + CreatePrice(subtotal, '@culture') + '<br />'); 487 $("#webshop-product-footer-shipment").html('@Translate("Shipment", "Shipment"): ' + CreatePrice(shipment, '@culture') + '<br />'); 488 $("#webshop-product-footer-total").html('@Translate("Total", "Total"): ' + CreatePrice(total, '@culture')); 489 } 490 491 492 function CreatePrice(price, culture) { 493 price = '€' + price.toFixed(2); 494 if (culture.toLowerCase() == 'nl-nl') { 495 price = price.replace(".", ","); 496 } 497 return price; 498 } 499 </script> 500 @SnippetEnd("JavascriptsBottom") 501 } 502 }

Lidmaatschap KWPN

  • Iedere maand het KWPN Magazine - In de Strengen
  • Onbeperkt toegang tot KWPN.tv
  • Gratis advertenties plaatsen op KWPN Horses for Sale
Word nu lid
€22,- per jaar

JongKWPN lidmaatschap

  • Ben jij tussen de 16 en 30 jaar?
  • Ben jij geïnteresseerd in fokkerij en sport? 

Dan is JongKWPN vast en zeker iets voor jou! JongKWPN biedt een gevarieerd programma. 

Word nu lid

Official Partners


Het KWPN maakt gebruik van cookies

Wij vragen uw akkoord voor het gebruik van cookies op onze website. Meer informatie is beschikbaar in ons cookiebeleid.

Cookiebeleid