Changeset 3171498
- Timestamp:
- 10/18/2024 01:42:59 PM (18 months ago)
- Location:
- eshoplogisticru/trunk
- Files:
-
- 1 added
- 4 edited
-
Modules/AssetsLoader.php (modified) (2 diffs)
-
assets/js/checkout_frame_v2.js (modified) (5 diffs)
-
assets/js/object_hash.js (added)
-
readme.txt (modified) (1 diff)
-
wc-eshop-logistic.php (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
eshoplogisticru/trunk/Modules/AssetsLoader.php
r3032705 r3171498 113 113 ); 114 114 wp_enqueue_script( 115 'wc_esl_object_hash', 116 WC_ESL_PLUGIN_URL . 'assets/js/object_hash.js', 117 [], 118 WC_ESL_VERSION, 119 true 120 ); 121 wp_enqueue_script( 115 122 'wc_esl_checkout_frame_js_v2', 116 123 WC_ESL_PLUGIN_URL . 'assets/js/checkout_frame_v2.js', … … 119 126 true 120 127 ); 128 $this->injectGlobals('wc_esl_object_hash'); 121 129 $this->injectGlobals('wc_esl_checkout_frame_js_v2'); 122 130 }else{ -
eshoplogisticru/trunk/assets/js/checkout_frame_v2.js
r3164990 r3171498 10 10 let cityMain = false 11 11 let errorCity = 0 12 let hashSelectService = [] 12 13 13 14 function isHidden(el) { … … 850 851 851 852 }, 852 setTerminal: function (response ) {853 setTerminal: function (response, hide = true) { 853 854 _self = this 854 855 … … 866 867 jQuery('#wc_esl_billing_terminal, #wc_esl_shipping_terminal').val(address.address); 867 868 //jQuery(".wc-esl-terminals__button").text("Выбрать способ доставки и пункт самовывоза"); 868 modalEsl.style.display = "none"; 869 if(hide) 870 modalEsl.style.display = "none"; 869 871 } 870 872 }) … … 906 908 }); 907 909 910 root.addEventListener('eShopLogisticWidgetCart:onBalloonOpen', (event) => { 911 let data = event.detail 912 console.log('Событие onBalloonOpen', data) 913 let hash = objectHash.sha1(data); 914 hashSelectService = hash 915 916 if (typeof data.terminal == 'object') { 917 esl.setTerminal(data.terminal, false) 918 } else { 919 jQuery('#wc_esl_billing_terminal, #wc_esl_shipping_terminal').val(''); 920 window.keyDelivery = data.typeDelivery 921 let differentShippingAddress = jQuery('#ship-to-different-address-checkbox').is(':checked'); 922 let currentBillingCountry = (jQuery('#billing_country').val())?jQuery('#billing_country').val():'RU'; 923 let currentShippingCountry = (jQuery('#shipping_country').val())?jQuery('#shipping_country').val():'RU'; 924 if (window.keyDelivery === 'door') { 925 jQuery('#buttonModalDoor').show(); 926 } else { 927 jQuery('#buttonModalDoor').hide(); 928 } 929 930 changeVisibleElements( 931 differentShippingAddress, 932 window.keyDelivery, 933 currentBillingCountry, 934 currentShippingCountry 935 ); 936 937 } 938 }) 939 908 940 root.addEventListener('eShopLogisticWidgetCart:onSelectedService', (event) => { 909 941 let data = event.detail 910 942 console.log('Событие onSelectedService', data) 943 let hash = objectHash.sha1(event.detail); 944 console.log(hash) 945 console.log(hashSelectService) 946 911 947 if (typeof data.terminal == 'object') { 912 948 esl.setTerminal(data.terminal) … … 929 965 currentShippingCountry 930 966 ); 931 932 } 933 esl.confirm(data) 967 } 968 969 if(hash !== hashSelectService){ 970 esl.confirm(data) 971 } 934 972 }) 935 973 -
eshoplogisticru/trunk/readme.txt
r3169130 r3171498 3 3 Tags: доставка, eshoplogisticru, цена доставки, срок доставки, стоимость доставки, WooCommerce, сдэк, пэк, dostavista, picpoint, деловые линии, iml, boxberry, gtd, байкалсервис, сберлогистика, delivery, яндекс доставка 4 4 Requires at least: 5.3 5 Tested up to: 5.86 Stable tag: 2.1.3 25 Tested up to: 6.6 6 Stable tag: 2.1.33 7 7 License: GPLv2 8 8 License URI: http://www.gnu.org/licenses/gpl-2.0.html -
eshoplogisticru/trunk/wc-eshop-logistic.php
r3169130 r3171498 6 6 * 7 7 * @link https://wp.eshoplogistic.ru/ 8 * @since 2.1.3 28 * @since 2.1.33 9 9 * @package WC_Eshop_Logistic 10 10 * … … 13 13 * Plugin URI: https://wp.eshoplogistic.ru/ 14 14 * Description: Несколько служб доставки в одной интеграции: CDEK, DPD, Boxberry, IML, Почта России, Деловые Линии, ПЭК, Dostavista, GTD, Байкал Сервис и др. 15 * Version: 2.1.3 215 * Version: 2.1.33 16 16 * Author: eShopLogistic 17 17 * Author URI: https://eshoplogistic.ru/p747575 … … 41 41 define( 'WC_ESL_PLUGIN_DIR', plugin_dir_path(__FILE__) ); 42 42 43 define( 'WC_ESL_VERSION', '2.1.3 2' );43 define( 'WC_ESL_VERSION', '2.1.33' ); 44 44 45 45 define( 'WC_ESL_DOMAIN', 'wc-esl' );
Note: See TracChangeset
for help on using the changeset viewer.