Changeset 3043145
- Timestamp:
- 02/29/2024 12:31:53 PM (2 years ago)
- Location:
- wc-westpac-payway-with-recurring
- Files:
-
- 13 added
- 3 edited
-
tags/1.4 (added)
-
tags/1.4/classes (added)
-
tags/1.4/classes/payway-gateway-rest.php (added)
-
tags/1.4/errorlog.txt (added)
-
tags/1.4/includes (added)
-
tags/1.4/includes/checkout.js (added)
-
tags/1.4/includes/class-payway-woocommerce-block-checkout.php (added)
-
tags/1.4/includes/payway-rest-admin.php (added)
-
tags/1.4/readme.txt (added)
-
tags/1.4/uninstall.php (added)
-
tags/1.4/wc-westpac-payway-with-recurring.php (added)
-
trunk/classes/payway-gateway-rest.php (modified) (1 diff)
-
trunk/includes/checkout.js (added)
-
trunk/includes/class-payway-woocommerce-block-checkout.php (added)
-
trunk/readme.txt (modified) (1 diff)
-
trunk/wc-westpac-payway-with-recurring.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
wc-westpac-payway-with-recurring/trunk/classes/payway-gateway-rest.php
r2560321 r3043145 33 33 34 34 // Default values 35 $this->enabled = isset( $this->settings['enabled'] ) && $this->settings['enabled'] == 'yes' ? 'yes' : $this->default_enabled;35 $this->enabled = isset( $this->settings['enabled'] ) && $this->settings['enabled'] == 'yes' ? 'yes' : 'no'; 36 36 $this->title = sanitize_text_field($this->settings['title'], 'woo_payway_recurring_net' ); 37 37 $this->description = sanitize_text_field($this->settings['description'], 'woo_payway_recurring_net' ); -
wc-westpac-payway-with-recurring/trunk/readme.txt
r2803081 r3043145 5 5 Requires at least: 4.9 6 6 Tested up to: 6.0 7 Stable tag: 1. 37 Stable tag: 1.4 8 8 Requires PHP: 7.4 9 9 License: GPLv2 or later -
wc-westpac-payway-with-recurring/trunk/wc-westpac-payway-with-recurring.php
r2803082 r3043145 3 3 * Plugin Name: Payment gateway for Westpac PayWay NET on Woocommerce with Recurring Billing 4 4 * Description: The plugin gives the functionality of processing Credit and Debit Cards on WooCommerce using Westpac PayWay NET along with Recurring Payments. 5 * Version: 1. 35 * Version: 1.4 6 6 * Author: Spanrig Technologies 7 7 * Author URI: https://www.upwork.com/fl/hncvj … … 139 139 add_action( 'woocommerce_process_product_meta', 'payway_custom_fields_save' ); 140 140 141 142 /** 143 * Custom function to declare compatibility with cart_checkout_blocks feature 144 */ 145 function declare_cart_checkout_blocks_compatibility() { 146 // Check if the required class exists 147 if (class_exists('\Automattic\WooCommerce\Utilities\FeaturesUtil')) { 148 // Declare compatibility for 'cart_checkout_blocks' 149 \Automattic\WooCommerce\Utilities\FeaturesUtil::declare_compatibility('cart_checkout_blocks', __FILE__, true); 150 } 151 } 152 // Hook the custom function to the 'before_woocommerce_init' action 153 add_action('before_woocommerce_init', 'declare_cart_checkout_blocks_compatibility'); 154 155 // Hook the custom function to the 'woocommerce_blocks_loaded' action 156 add_action( 'woocommerce_blocks_loaded', 'register_paywaynetrecurring_payment_method_type' ); 157 158 /** 159 * Custom function to register a payment method type 160 161 */ 162 function register_paywaynetrecurring_payment_method_type() { 163 // Check if the required class exists 164 if ( ! class_exists( 'Automattic\WooCommerce\Blocks\Payments\Integrations\AbstractPaymentMethodType' ) ) { 165 return; 166 } 167 168 // Include the custom Blocks Checkout class 169 require_once PAYWAYRESTRECURRINGPLUGINPATH . 'includes/class-payway-woocommerce-block-checkout.php'; 170 171 // Hook the registration function to the 'woocommerce_blocks_payment_method_type_registration' action 172 add_action( 173 'woocommerce_blocks_payment_method_type_registration', 174 function( Automattic\WooCommerce\Blocks\Payments\PaymentMethodRegistry $payment_method_registry ) { 175 // Register an instance of WC_Payway_Blocks 176 $payment_method_registry->register( new WC_Payway_Blocks ); 177 } 178 ); 179 } 180 141 181 }
Note: See TracChangeset
for help on using the changeset viewer.