WOOCS - WooCommerce Currency Switcher

Wholesale Suite

Plugin link: https://wholesalesuiteplugin.com/

In file \wp-content\plugins\woocommerce-wholesale-prices\includes\class-wwp-wholesale-prices.php add next code:

$price = $cart_item['data']->get_price();
if (class_exists('WOOCS')) {
    global $WOOCS;
    $currrent = $WOOCS->current_currency;
    if ($currrent != $WOOCS->default_currency) {
        $currencies = $WOOCS->get_currencies();
        $rate = $currencies[$currrent]['rate'];
        $price = $price / ($rate);
    }
}

Also add next code to the same file:

$price = $cart_item['data']->get_price();
if (class_exists('WOOCS')) {
    global $WOOCS;
    $currrent = $WOOCS->current_currency;
    if ($currrent != $WOOCS->default_currency) {
        $currencies = $WOOCS->get_currencies();
        $rate = $currencies[$currrent]['rate'];
        $price = $price / ($rate);
    }
}

Next code should be changed – write there $price variable: