Home › Forums › Themes Support › Claue › Mayor issue with Product Bundle and ARS (Argentinian Pesos) currency
- This topic has 5 replies, 3 voices, and was last updated 5 years, 5 months ago by Harry.
-
AuthorPosts
-
-
June 7, 2019 at 2:50 am #316712playersSupport Expired
Hi! Different from others currencies ARS use “,” to separate decimals and “.” for thousand separator. Long-short: it’s backwards.
The issue: some regex is taking the “.” to only show 2 decimals in the price total in bundle productos.
<h2>Example:</h2>
- Product 1 $1.000,00; Product 2 $1.000,00
- Bundle = 10% discount
- REAL Final price: $1.800,00
- Final price Shown: $1.80 (Did you get it? The dot is the problem).
I tried to workaround this problem changing the decimal and thousand symbols from the currency menu. I mean i place “,” to separate thousand and “,” for decimals just as USD do. But the problem persist.
I I think you can give me a hand here to understand if the problem is the plug-in or the theme (?) and help me to fix it.
thanks.
-
June 7, 2019 at 9:17 am #31677HarrySupport Expired
Hi,
Sorry because inconvenience.
I’m sorry this issue cause by plugin. It doesn’t calculate the discount percent and discount number when you change “,” to separate decimals and “.” for thousand separator. Please revert to default “,” for thousand separator and “.” to separate decimals. http://prntscr.com/nynhzv
The function of code will work wrong when switch this, it doesn’t get correct value.
Kind regards
Harry
Premium Wordpress themes and plugins, Best WooCommerce theme https://themeforest.net/user/janstudio/portfolio?ref=janstudio-
June 18, 2019 at 6:59 am #31859bghazySupport Expired
I solved it by editing this function “wpa_wcpb_onchange_input_check_total_discount” at
“wp-content/plugins/wpa-woocommerce-product-bundle/assets/js/wcpb-frontend.js”
from this
jQuery(‘.px-product-bundles input[type=checkbox]:checked’).each(function(){
var parent = jQuery(this).parent().parent(),
price = parent.attr(‘data-item-price-with-filter’),
new_price = parseFloat( price ) – parseFloat( price ) * parseFloat( bundle_percent ) / 100;to this
jQuery(‘.px-product-bundles input[type=checkbox]:checked’).each(function(){
var parent = jQuery(this).parent().parent(),
price = parent.attr(‘data-item-price-with-filter’),
price=parseFloat( price.replace(‘,’, ”) ),
pricepercent=(price * parseFloat( bundle_percent ) / 100),
new_price = parseFloat( price ) – pricepercent;-
June 18, 2019 at 9:43 am #31864HarrySupport Expired
@bghazy thank you for share but i tried your function it show wrong number http://prntscr.com/o36ayn
Kind regards
Harry
Premium Wordpress themes and plugins, Best WooCommerce theme https://themeforest.net/user/janstudio/portfolio?ref=janstudio
-
-
-
June 7, 2019 at 11:23 am #316812playersSupport Expired
Please try with ARS, Argentinian Pesos (or Pesos Argentinos in Spanish). The problem is with THAT currency. Straight or backwards.
Would you upload a ticket to Bundle Plugin for me?
-
June 7, 2019 at 6:04 pm #31687HarrySupport Expired
Hi,
The issue with any Currency when you change change “,” to separate decimals and “.” for thousand separator. We reported this issue with WP Product Bundle plugin author but they can’t fix.
Kind regards
Harry
Premium Wordpress themes and plugins, Best WooCommerce theme https://themeforest.net/user/janstudio/portfolio?ref=janstudio
-
-
AuthorPosts
You must be logged in to reply to this topic.