Changeset 2911632
- Timestamp:
- 05/12/2023 01:52:23 PM (3 years ago)
- Location:
- simple-cod-fee-for-woocommerce
- Files:
-
- 10 added
- 2 edited
-
tags/1.7.1 (added)
-
tags/1.7.1/custom-cod-payment.php (added)
-
tags/1.7.1/languages (added)
-
tags/1.7.1/languages/scffw-el.mo (added)
-
tags/1.7.1/languages/scffw-el.po (added)
-
tags/1.7.1/readme.txt (added)
-
tags/1.7.1/scffw-admin.min.js (added)
-
tags/1.7.1/scffw.css (added)
-
tags/1.7.1/scffw.min.js (added)
-
tags/1.7.1/simple-cod-fee-for-woocommerce.php (added)
-
trunk/readme.txt (modified) (2 diffs)
-
trunk/simple-cod-fee-for-woocommerce.php (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
simple-cod-fee-for-woocommerce/trunk/readme.txt
r2911263 r2911632 5 5 Tested up to: 6.2 6 6 Requires PHP: 7.0 7 Stable tag: 1.7 7 Stable tag: 1.7.1 8 8 License: GPLv2 or later 9 9 … … 31 31 Yes, you can configure this plugin to disable either COD or COD Fee depending on user's total amount in cart 32 32 == Changelog == 33 34 = 1.7.1 = 35 * Fix error when sometimes cod fee was never added 33 36 34 37 = 1.7 = -
simple-cod-fee-for-woocommerce/trunk/simple-cod-fee-for-woocommerce.php
r2911261 r2911632 3 3 Plugin Name: Simple COD Fee for WooCommerce 4 4 Description: Simply add extra fee for WooCommerce Cash On Delivery payment method 5 Version: 1.7 5 Version: 1.7.1 6 6 Author: Andreas Sofantzis 7 7 Author URI: https://83pixel.com … … 95 95 $chosen_shipping_method = WC()->session->get( 'chosen_shipping_methods' ); 96 96 $enabled_cod_shipping_methods = $payment_gateway->settings['enable_for_methods']; 97 97 98 98 // if COD is enabled for some shipping methods 99 if ( !empty( $enabled_cod_shipping_methods ) ) {99 if ( !empty( $enabled_cod_shipping_methods ) && !empty($chosen_shipping_method) ) { 100 100 if (!empty( array_intersect($chosen_shipping_method, $enabled_cod_shipping_methods) ) ) { 101 101 … … 190 190 $cod = WC()->payment_gateways->payment_gateways()['cod']; 191 191 $settings = get_option( 'woocommerce_' . $shipping_method_id . '_' . $index . '_settings' ); 192 $fee = $cod->settings['fee']; 192 193 193 194 // if wpml multicurrency is enabled … … 217 218 } 218 219 219 if ( $cod->settings['scffw_cod_fee_tax_status'] == 'taxable' && is_checkout() ) {220 if ( array_key_exists('scffw_cod_fee_tax_status', $cod->settings) && $cod->settings['scffw_cod_fee_tax_status'] == 'taxable' && is_checkout() ) { 220 221 221 222 $tax_percentage = $cod->settings['scffw_cod_fee_tax_rates'];
Note: See TracChangeset
for help on using the changeset viewer.