diff --git a/deploy.md b/deploy.md index d266509..2811887 100644 --- a/deploy.md +++ b/deploy.md @@ -4,6 +4,8 @@ Need to update version before update on Store. - kkiapay-woocommerce-plugin.php * line 10: **Version: 2.4.x** + - kkiapay-woocommerce-plugin.php + * line 20: **define('WC_KKIAPAY_VERSION', '2.4.x');** - readme.txt * line 7: **Stable tag: 2.4.x** diff --git a/includes/class-wc-kkiapay-gateway-blocks-support.php b/includes/class-wc-kkiapay-gateway-blocks-support.php index f7862ae..02d733e 100644 --- a/includes/class-wc-kkiapay-gateway-blocks-support.php +++ b/includes/class-wc-kkiapay-gateway-blocks-support.php @@ -83,7 +83,7 @@ public function get_payment_method_data() return array( 'title' => $this->get_setting('title'), 'description' => $this->get_setting('description'), - 'icon' => plugins_url('assets/img/kkiapay.svg', WC_KKIAPAY_MAIN_FILE), + 'icon' => plugins_url('assets/img/kkiapay.svg', WC_KKIAPAY_MAIN_FILE) . '?ver=' . WC_KKIAPAY_VERSION, 'supports' => array_filter($gateway->supports, array($gateway, 'supports')), ); } diff --git a/includes/class-wc-kkiapay-gateway.php b/includes/class-wc-kkiapay-gateway.php index eb2c5e4..0f4a2da 100644 --- a/includes/class-wc-kkiapay-gateway.php +++ b/includes/class-wc-kkiapay-gateway.php @@ -74,7 +74,7 @@ public function __construct() $this->id = 'kkiapay_woocommerce_plugin'; $this->icon = 'https://github.com/kkiapay/wordpress-plugin/assets/91498943/69fd580e-b43f-4a39-abc9-cba86ebfb74d'; $this->has_fields = true; - // $this->refund = $this->get_option('refund'); + // $this->refund = $this->get_option('refund'); $this->title = array_key_exists('title', $this->settings) ? $this->settings['title'] : ''; $this->method_title = 'Kkiapay'; $this->description = "
@@ -103,7 +103,7 @@ public function __construct() // if ($this->description === "") { - $this->description = "
+ $this->description = "
Moov Money, MTN Money, Orange Money, TMoney, FreeMoney, Wave, Visa, Mastercard
"; // } @@ -151,17 +151,21 @@ public function import_kkiapay() - wp_register_style('custom-kkiapay-style', plugins_url('../assets/css/style.css', __FILE__)); + wp_register_style('custom-kkiapay-style', plugins_url('../assets/css/style.css', __FILE__), [], $plugin_information['Version']); wp_enqueue_style('custom-kkiapay-style'); wp_enqueue_script('setup-kkiapay-script', "https://cdn.kkiapay.me/k.js", [], $plugin_information['Version'], true); - wp_register_script('init-kkiapay-script', plugins_url('../assets/js/invoke.js', __FILE__), ['setup-kkiapay-script'], 'v1', true); + wp_register_script('init-kkiapay-script', plugins_url('../assets/js/invoke.js', __FILE__), ['setup-kkiapay-script'], $plugin_information['Version'], true); } public function import_admin_scripts() { - wp_enqueue_script('jscolor', plugins_url('../assets/js/jscolor.js', __FILE__), [], 'v1', true); - wp_enqueue_script('setup-admin-script', plugins_url('../assets/js/admin.js', __FILE__), [], 'v1', true); + $filename = 'kkiapay-woocommerce-plugin.php'; + $path = plugin_dir_path(__DIR__) . $filename; + $plugin_information = get_plugin_data($path); + + wp_enqueue_script('jscolor', plugins_url('../assets/js/jscolor.js', __FILE__), [], $plugin_information['Version'], true); + wp_enqueue_script('setup-admin-script', plugins_url('../assets/js/admin.js', __FILE__), [], $plugin_information['Version'], true); } /** diff --git a/kkiapay-woocommerce-plugin.php b/kkiapay-woocommerce-plugin.php index 6b94128..58c30dc 100644 --- a/kkiapay-woocommerce-plugin.php +++ b/kkiapay-woocommerce-plugin.php @@ -17,7 +17,7 @@ */ define('WC_KKIAPAY_MAIN_FILE', __FILE__); -define('WC_KKIAPAY_VERSION', '2.4.5'); +define('WC_KKIAPAY_VERSION', '2.4.7'); // Make sure WooCommerce is active if (!in_array('woocommerce/woocommerce.php', apply_filters('active_plugins', get_option('active_plugins')))) diff --git a/kkiapay-woocommerce.zip b/kkiapay-woocommerce.zip index ca9e48f..e42f7bd 100644 Binary files a/kkiapay-woocommerce.zip and b/kkiapay-woocommerce.zip differ diff --git a/readme.txt b/readme.txt index 6bb2200..b4a296b 100644 --- a/readme.txt +++ b/readme.txt @@ -4,7 +4,7 @@ Tags: credit card, mobile money, africa payment,online payment, swift payment, b Requires at least: 6.0 Tested up to: 6.4.3 Requires PHP: 7.4 -Stable tag: 2.4.7 +Stable tag: 2.4.8 License: GPLv3 License URI: https://www.gnu.org/licenses/gpl-3.0.html