- 상태
- 개발자가 해결함
- 해결된 버전
- 4.26.0
- 관련 플러그인/테마
- YITH WC Dynamic Pricing & Discounts
- 주제 태그
- Compatibility, WCML
문제 개요
WPML과 다중 통화가 활성화된 상태에서 YITH WooCommerce Dynamic Pricing & Discounts Premium을 사용할 때 AJAX 작업으로 인해 잘못된 동작이 발생할 수 있습니다. 보조 통화에서는 사은품이 장바구니에 추가되지 않으며 장바구니 가격이 기본 통화로 되돌아갑니다.
임시 해결 방법
계속 진행하기 전에 사이트의 전체 사이트 백업을 반드시 수행하세요.
- 테마의 functions.php 파일에 다음 코드를 추가하세요.
// WPML Workaround for compsupp-8147 add_filter( 'wcml_load_multi_currency_in_ajax', 'add_action_to_multi_currency_ajax', 10, 1 ); function add_action_to_multi_currency_ajax( $ajax_actions ) { $ywdpd_actions = array( 'ywdpd_add_gift_to_cart', 'ywdpd_add_bogo_to_cart', 'ywdpd_add_special_to_cart', 'ywdpd_add_last_deals', 'ywdpd_check_variable', 'ywdpd_valid_rule_in_checkout', 'ywdpd_update_cart_after_payment_method', ); return array_values( array_unique( array_merge( (array) $ajax_actions, $ywdpd_actions ) ) ); }