Changeset 2820918
- Timestamp:
- 11/19/2022 04:36:13 PM (3 years ago)
- Location:
- shipping-nova-poshta-for-woocommerce/trunk
- Files:
-
- 6 edited
-
readme.txt (modified) (2 diffs)
-
shipping-nova-poshta-for-woocommerce.php (modified) (2 diffs)
-
src/Api/Api.php (modified) (1 diff)
-
src/Main.php (modified) (1 diff)
-
src/WooCommerce/Cart.php (modified) (2 diffs)
-
templates/admin/page-options/license-form.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
shipping-nova-poshta-for-woocommerce/trunk/readme.txt
r2698030 r2820918 2 2 Contributors: wppunk 3 3 Tags: нова пошта, nova poshta, новая почта, nova pochta, інтеграція нової пошти та інтернет-магазину, плагін нової пошти для wordpress 4 Requires at least: 5. 65 Tested up to: 5.96 Stable tag: 1.5.4. 14 Requires at least: 5.8 5 Tested up to: 6.1 6 Stable tag: 1.5.4.3 7 7 Requires PHP: 7.0 8 8 License: GPLv2 or later … … 85 85 == Changelog == 86 86 87 = 1.5.4.3 = 88 * Added WordPress 6.1 compatibility 89 * Added PHP8.1 compatibility 90 * Added `shipping_nova_poshta_for_woocommerce_free_shipping` filter 91 * Added `shipping_nova_poshta_for_woocommerce_api_cities_limit` filter 92 * Minimal required WordPress version is 5.8 93 * Increased WordPress compatibility version 94 * Increased WooCommerce compatibility version 95 87 96 = 1.5.4.2 = 88 97 * Fixed license check -
shipping-nova-poshta-for-woocommerce/trunk/shipping-nova-poshta-for-woocommerce.php
r2698030 r2820918 6 6 * Plugin URI: http://wp-unit.com/ 7 7 * Description: Select a branch on the checkout page, the creation of electronic invoices, calculating shipping costs, COD payment, and much more ... 8 * Version: 1.5.4. 28 * Version: 1.5.4.3 9 9 * Author: WP Unit 10 10 * Author URI: http://wp-unit.com/ … … 15 15 * @author WP Punk 16 16 * 17 * Requires at least: 5. 617 * Requires at least: 5.8 18 18 * Requires PHP: 7.0 19 * WC requires at least: 3.320 * WC tested up to: 6.3.119 * WC requires at least: 4.6 20 * WC tested up to: 7.1 21 21 */ 22 22 -
shipping-nova-poshta-for-woocommerce/trunk/src/Api/Api.php
r2679493 r2820918 97 97 * @return array 98 98 */ 99 public function cities( string $search = '', int $limit = 10 ): array {99 public function cities( string $search = '', int $limit = 0 ): array { 100 100 101 101 if ( ! $this->settings->api_key() ) { 102 102 return []; 103 } 104 105 if ( empty( $limit ) ) { 106 $limit = (int) apply_filters( 'shipping_nova_poshta_for_woocommerce_api_cities_limit', 10 ); 103 107 } 104 108 -
shipping-nova-poshta-for-woocommerce/trunk/src/Main.php
r2698030 r2820918 37 37 * Plugin version 38 38 */ 39 const VERSION = '1.5.4. 2';39 const VERSION = '1.5.4.3'; 40 40 41 41 -
shipping-nova-poshta-for-woocommerce/trunk/src/WooCommerce/Cart.php
r2470822 r2820918 23 23 24 24 /** 25 * Plugin settings.26 *27 * @var Settings28 */29 private $settings;30 31 /**32 * Cart constructor.33 *34 * @param Settings $settings Settings.35 */36 public function __construct( Settings $settings ) {37 38 $this->settings = $settings;39 }40 41 /**42 25 * Add hooks 43 26 */ … … 56 39 public function cart_total( float $total ): float { 57 40 58 $is_free = apply_filters( 'shipping_nova_poshta_for_woocommerce_free_shipping', $this->settings->exclude_shipping_from_total() ); 41 $shipping_methods = wc_get_chosen_shipping_method_ids(); 42 $shipping_method = array_shift( $shipping_methods ); 43 44 if ( empty( $shipping_method ) ) { 45 return $total; 46 } 47 48 $is_free = apply_filters( 'shipping_nova_poshta_for_woocommerce_free_shipping', false, $shipping_method ); 59 49 60 50 if ( $is_free ) { -
shipping-nova-poshta-for-woocommerce/trunk/templates/admin/page-options/license-form.php
r2470822 r2820918 41 41 </div> 42 42 <div> 43 <input type="password" name="license_key" value="<?php echo esc_attr( $license_key ); ?>" <?php readonly( true, 'deactivate' === $method ); ?>>43 <input type="password" name="license_key" value="<?php echo esc_attr( $license_key ); ?>" <?php echo 'deactivate' === $method ? 'readonly' : ''; ?>> 44 44 <?php if ( 'activate' !== $method && ! $is_pro ) { ?> 45 45 <button
Note: See TracChangeset
for help on using the changeset viewer.