diff --git a/templates/backOffice/default/categories.html b/templates/backOffice/default/categories.html index 2cd4e0309..4a8b69d37 100644 --- a/templates/backOffice/default/categories.html +++ b/templates/backOffice/default/categories.html @@ -794,10 +794,16 @@ captureLength: 1, wait : 300, callback : function () { + var price = $(this).val(); + $(this).val(sanitizeFloat(price)); update_price($(this).val(), $(this).data('price-type'), $(this).data('rel-price')); } }); + function sanitizeFloat(numVal) { + return numVal.replace(",", "."); + }; + }); {/block} diff --git a/templates/backOffice/default/product-edit.html b/templates/backOffice/default/product-edit.html index 72df5e344..253b99e60 100644 --- a/templates/backOffice/default/product-edit.html +++ b/templates/backOffice/default/product-edit.html @@ -363,10 +363,16 @@ $(function() { captureLength: 1, wait : 300, callback : function () { - update_price($(this).val(), $(this).data('price-type'), $(this).data('rel-price')); + var price = $(this).val(); + $(this).val(sanitizeFloat(price)); + update_price($(this).val(), $(this).data('price-type'), $(this).data('rel-price')); } }); + function sanitizeFloat(numVal) { + return numVal.replace(",", "."); + }; + // Count generated combinations in real time function countGeneratedCombinations() {