From 0a6fd7c03bf0310d0169f912a9232b8a34ae3854 Mon Sep 17 00:00:00 2001 From: fBrignoli Date: Mon, 30 Jan 2012 10:15:57 +0000 Subject: [PATCH] [-] BO : Bug Fixed #PSTEST-477 - Attribute Generator : Price tax included should be displayed with 2 decimal --- .../template/controllers/attribute_generator/content.tpl | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/admin-dev/themes/default/template/controllers/attribute_generator/content.tpl b/admin-dev/themes/default/template/controllers/attribute_generator/content.tpl index 4047eb378..c81082581 100644 --- a/admin-dev/themes/default/template/controllers/attribute_generator/content.tpl +++ b/admin-dev/themes/default/template/controllers/attribute_generator/content.tpl @@ -33,7 +33,7 @@ { name = element.attr("name"); var element_price = element.val().replace(/,/g, "."); - var other_element_price = "0"; + var other_element_price = 0; if (!isNaN(element_price) && element_price > 0) { @@ -41,6 +41,8 @@ other_element_price = parseFloat(element_price / ((product_tax / 100) + 1)); else other_element_price = ps_round(parseFloat(element_price * ((product_tax / 100) + 1)), 2); + + other_element_price = other_element_price.toFixed(2); } $("#related_to_"+name).val(other_element_price);