Currency Switcher Cannot Update Custom Fields Price Correctly
The support doesn work on Saturdays and Sundays, so some Friday requests can be answered on Monday. If you have problems with registration ask help on contact us page pleaseIf you not got email within 24~36 business hours, firstly check your spam box, and if no any email from the support there - back to the forum and read answer here. DO NOT ANSWER ON EMAILS [noreply@pluginus.net] FROM THE FORUM!! Emails are just for your info, all answers should be published only here.
The support doesn work on Saturdays and Sundays, so some Friday requests can be answered on Monday.
Quote from timtsui on November 27, 2019, 01:57Hi there,
I have purchased "WOOCS - WooCommerce Currency Switcher" and integrated it with an eCommerce website with "WooCommerce Product Add-Ons Ultimate" plugin together. This plugin is used for defining some calculation formula to calculate the product price according to the predefined rules/selection.
The problem is when the product has been added to the cart which price is calculated by using above mentioned plugin and I switched the currency, the product price cannot be updated correctly or updated twice in the cart.
May I know is this plugin not compatible with "WooCommerce Product Add-Ons Ultimate" plugin?
Please let me know if I need to deploy the website to the server for your investigation, as I am developing the website in my localhost at this moment.
Cheers
Tim
Hi there,
I have purchased"WOOCS - WooCommerce Currency Switcher" and integrated it with an eCommerce website with"WooCommerce Product Add-Ons Ultimate" plugin together. This plugin is used for defining some calculation formula to calculate the product price according to the predefined rules/selection.
The problem is when the product has been added to the cart which price is calculated by using above mentioned plugin and I switched the currency, the product price cannot be updated correctly or updated twice in the cart.
May I know is this plugin not compatible with"WooCommerce Product Add-Ons Ultimate" plugin?
Please let me know if I need to deploy the website to the server for your investigation, as I am developing the website in my localhost at this moment.
Cheers
Tim
Quote from Pablo Borysenco on November 27, 2019, 11:39Hello Tim
Read this please - https://currency-switcher.com/woocs-labs/
Paste your license key here - https://c2n.me/43SC6rb.png -> https://c2n.me/42HBIt7.png and wp-admin+FTP access - https://c2n.me/42BAoj4.png - I will add this plugin to the adaptation queue
Hello Tim
Read this please - https://currency-switcher.com/woocs-labs/
Paste your license key here - https://c2n.me/43SC6rb.png -> https://c2n.me/42HBIt7.png and wp-admin+FTP access - https://c2n.me/42BAoj4.png - I will add this plugin to the adaptation queue
Quote from timtsui on November 27, 2019, 13:49Hi Pablo,
I have attached required credential information in the private area already as well as some steps to reproduce the issue for your reference. Please have a look and advise. Thanks a lot
Hi Pablo,
I have attached required credential information in the private area already as well as some steps to reproduce the issue for your reference. Please have a look and advise. Thanks a lot
Quote from Pablo Borysenco on November 28, 2019, 10:30Hello
Thanks for the detailed description!
I added this plugin to the adaptation queue
Hello
Thanks for the detailed description!
I added this plugin to the adaptation queue
Quote from Pablo Borysenco on December 26, 2019, 17:24Hello
Please do test!
In file - plugins\product-extras-for-woocommerce\inc\functions-cart.php - add code - https://c2n.me/45i4VCu.png
if (class_exists('WOOCS')) {
global $WOOCS;
if ($WOOCS->is_multiple_allowed) {
$price = $WOOCS->woocs_exchange_value(floatval($price));
}
}AND - https://c2n.me/45i522m.png
if (class_exists('WOOCS') AND $price ) {
global $WOOCS;
if ($WOOCS->is_multiple_allowed) {
$currrent = $WOOCS->current_currency;
if ($currrent != $WOOCS->default_currency) {
$currencies = $WOOCS->get_currencies();
$rate = $currencies[$currrent]['rate'];
$price= $final_price / $price;
}
}
}AND - https://c2n.me/45i5832.png
if (class_exists('WOOCS')) {
global $WOOCS;
if ($WOOCS->is_multiple_allowed AND isset($cart_item_data['product_extras']['price_with_extras'])) {
$currrent = $WOOCS->current_currency;
if ($currrent != $WOOCS->default_currency) {
$currencies = $WOOCS->get_currencies();
$rate = $currencies[$currrent]['rate'];
$cart_item_data['product_extras']['price_with_extras'] = $cart_item_data['product_extras']['price_with_extras'] / $rate;
}
}
}
AND - https://c2n.me/45i5dEt.png
if (class_exists('WOOCS')) {
global $WOOCS;
if ($WOOCS->is_multiple_allowed ) {
$currrent = $WOOCS->current_currency;
if ($currrent != $WOOCS->default_currency) {
$currencies = $WOOCS->get_currencies();
$rate = $currencies[$currrent]['rate'];
$cart_item_data['product_extras']['price_with_extras_discounted'] = $cart_item_data['product_extras']['price_with_extras_discounted'] / $rate;
}
}
}
AND - https://c2n.me/45i5iDs.png
if(class_exists('WOOCS') AND $item['price']){
global $WOOCS;
if ($WOOCS->is_multiple_allowed) {
$currrent = $WOOCS->current_currency;
if ($currrent != $WOOCS->default_currency) {
$currencies = $WOOCS->get_currencies();
$rate = $currencies[$currrent]['rate'];
$item['price']= $rate * $item['price'];
}
}
$item['value']=preg_replace('/\((.+)\)/', "", $item['value']);
$item['value'].=sanitize_text_field("(".wc_price($item['price']).")");
}
Hello
Please do test!
In file - plugins\product-extras-for-woocommerce\inc\functions-cart.php - add code - https://c2n.me/45i4VCu.png
if (class_exists('WOOCS')) {
global $WOOCS;
if ($WOOCS->is_multiple_allowed) {
$price = $WOOCS->woocs_exchange_value(floatval($price));
}
}
AND - https://c2n.me/45i522m.png
if (class_exists('WOOCS') AND $price ) {
global $WOOCS;
if ($WOOCS->is_multiple_allowed) {
$currrent = $WOOCS->current_currency;
if ($currrent != $WOOCS->default_currency) {
$currencies = $WOOCS->get_currencies();
$rate = $currencies[$currrent]['rate'];
$price= $final_price / $price;
}
}
}
AND - https://c2n.me/45i5832.png
if (class_exists('WOOCS')) {
global $WOOCS;
if ($WOOCS->is_multiple_allowed AND isset($cart_item_data['product_extras']['price_with_extras'])) {
$currrent = $WOOCS->current_currency;
if ($currrent != $WOOCS->default_currency) {
$currencies = $WOOCS->get_currencies();
$rate = $currencies[$currrent]['rate'];
$cart_item_data['product_extras']['price_with_extras'] = $cart_item_data['product_extras']['price_with_extras'] / $rate;
}
}
}
AND - https://c2n.me/45i5dEt.png
if (class_exists('WOOCS')) {
global $WOOCS;
if ($WOOCS->is_multiple_allowed ) {
$currrent = $WOOCS->current_currency;
if ($currrent != $WOOCS->default_currency) {
$currencies = $WOOCS->get_currencies();
$rate = $currencies[$currrent]['rate'];
$cart_item_data['product_extras']['price_with_extras_discounted'] = $cart_item_data['product_extras']['price_with_extras_discounted'] / $rate;
}
}
}
AND - https://c2n.me/45i5iDs.png
if(class_exists('WOOCS') AND $item['price']){
global $WOOCS;
if ($WOOCS->is_multiple_allowed) {
$currrent = $WOOCS->current_currency;
if ($currrent != $WOOCS->default_currency) {
$currencies = $WOOCS->get_currencies();
$rate = $currencies[$currrent]['rate'];
$item['price']= $rate * $item['price'];
}
}
$item['value']=preg_replace('/\((.+)\)/',"", $item['value']);
$item['value'].=sanitize_text_field("(".wc_price($item['price']).")");
}