FOX - WooCommerce için Para Birimi Değiştirici Uzmanı

WooCommerce tarafından WooCommerce Abonelikleri

Eklenti bağlantısıhttps://woocommerce.com/products/woocommerce-subscriptions/

  • Dosyada functions.php mevcut wp temanızın bir sonraki kodunu ekleyin:
    add_filter('woocommerce_subscription_price_string_details', 'woocs_woocommerce_subscription_price_string_details', 100, 2); function woocs_woocommerce_subscription_price_string_details($arg, $_this) { if (class_exists('WOOCS')) { global $WOOCS; $order_currency = get_post_meta($_this->get_id(), '_order_currency', true); if ($order_currency AND $WOOCS->current_currency != $order_currency) { $WOOCS->set_currency($order_currency); } } $arg döndür; }
    
  • Dosyada wp-content\plugins\woocommerce-subscriptions\vendor\woocommerce\subscriptions-core\includes\wcs-order-functions.php sonraki kodu ekle:
    if (class_exists('WOOCS') AND 'renewal_order' == $type) { global $WOOCS; $_order_currency = get_post_meta($subscription->get_id(), '_order_currency', true); if ($_order_currency) { $WOOCS->set_currency($_order_currency); } }
    

  • Ve aynı dosyada sonraki kod:
    if (class_exists('WOOCS')) { global $WOOCS; $order_currency = get_post_meta($order_id, '_order_currency', true); if ($order_currency AND $WOOCS->current_currency != $order_currency) { $WOOCS->set_currency($order_currency); } }
    

  • Dosyada wp-content\plugins\woocommerce-subscriptions\vendor\woocommerce\subscriptions-core\includes\class-wcs-cart-renewal.php sonraki kodu ekle:
    if (class_exists('WOOCS')) { global $WOOCS; if ($WOOCS->is_multiple_allowed) { $curr = get_post_meta($subscription->get_id(), '_order_currency', true); $currencies = $WOOCS->get_currencies(); $oran = $para birimleri[$curr]['oran']; $fiyat = $fiyat / ($oran); } }
    

  • Dosyada wp-content\plugins\woocommerce-subscriptions\vendor\woocommerce\subscriptions-core\includes\class-wc-subscriptions-product.php sonraki kodu ekle:
    if (class_exists('WOOCS') AND $subscription_price) { global $WOOCS; if ($WOOCS->is_multiple_allowed) { $subscription_price = $WOOCS->woocs_exchange_value(floatval($subscription_price)); } }
    

  • dosyaya  wp-content\plugins\woocommerce-subscriptions\vendor\woocommerce\subscriptions-core\includes\class-wc-subscriptions-product.php sonraki kodu ekle:
    if (class_exists('WOOCS') VE $sign_up_fee) { global $WOOCS; if ($WOOCS->is_multiple_allowed) { $sign_up_fee = $WOOCS->woocs_exchange_value(floatval($sign_up_fee)); } }

  • Dosyada wp-content/plugins/woocommerce-subscriptions/vendor/woocommerce/subscriptions-core/includes/class-wc-product-variable-subscription.php sonraki kodu ekle:
    if (isset($fiyat['fiyat'][$min_price_variation_id])) { $fiyat = $fiyat['fiyat'][$min_price_variation_id]; }