Plugin Directory

Changeset 3108127


Ignore:
Timestamp:
06/26/2024 12:56:02 PM (20 months ago)
Author:
ventipay
Message:

Update to version 2.2.1 from GitHub

Location:
ventipay
Files:
8 added
6 edited
1 copied

Legend:

Unmodified
Added
Removed
  • ventipay/tags/2.2.1/includes/class-wc-gateway-ventipay.php

    r3077772 r3108127  
    333333      if (!empty($meta_payment_id)) {
    334334        if ('pending' === $order->get_status()) {
     335          ?>
     336            <script>
     337              setTimeout(() => {
     338                window.location.reload(true)
     339              }, 10000)
     340            </script>
     341          <?php
     342
    335343          $message = [
    336             '<script type="text/javascript">setTimeout(function() { window.location.reload(true); }, 10000);</script>',
    337344            '<div class="woocommerce-info">',
    338345            '<span>',
  • ventipay/tags/2.2.1/readme.txt

    r3077772 r3108127  
    33Tags: ventipay, transbank, webpay, bnpl, chile
    44Requires at least: 6.5
    5 Tested up to: 6.5.2
    6 Stable tag: 2.1.0
     5Tested up to: 6.5.3
     6Stable tag: 2.2.1
    77Requires PHP: 7.0
    88License: MIT
  • ventipay/tags/2.2.1/ventipay.php

    r3077772 r3108127  
    66 * Author: VentiPay
    77 * Author URI: https://www.ventipay.com/
    8  * Version: 2.1.0
     8 * Version: 2.2.1
    99 * Requires at least: 6.5
    10  * Tested up to: 6.5.2
     10 * Tested up to: 6.5.3
    1111 * WC requires at least: 8.0.0
    12  * WC tested up to: 8.8.2
     12 * WC tested up to: 8.9.1
    1313 * Text Domain: ventipay
    1414 * Domain Path: /languages
     
    4242add_action('plugins_loaded', 'ventipay_init_gateway_class');
    4343add_action('wp_enqueue_scripts', 'ventipay_setup_scripts');
     44add_action('before_woocommerce_init', 'ventipay_declare_features_util_compatibility');
     45add_action('woocommerce_blocks_loaded', 'ventipay_blocks_loaded');
    4446
    4547/**
     
    5961  require_once dirname( __FILE__ ) . '/includes/class-wc-gateway-ventipay.php';
    6062}
     63
     64function ventipay_declare_features_util_compatibility()
     65{
     66  if (!class_exists('\Automattic\WooCommerce\Utilities\FeaturesUtil')) {
     67    return;
     68  }
     69
     70  \Automattic\WooCommerce\Utilities\FeaturesUtil::declare_compatibility('cart_checkout_blocks', __FILE__, true);
     71
     72  // checking woocommerces version for hpos
     73  if (version_compare(WC_VERSION, '8.2', '>=')) {
     74    \Automattic\WooCommerce\Utilities\FeaturesUtil::declare_compatibility('custom_order_tables', __FILE__, true);
     75  }
     76}
     77
     78function ventipay_blocks_loaded()
     79{
     80  if (!class_exists('Automattic\WooCommerce\Blocks\Payments\Integrations\AbstractPaymentMethodType')) {
     81    return;
     82  }
     83
     84  require_once dirname( __FILE__ ) . '/blocks/wc-gateway-ventipay.php';
     85
     86  add_action(
     87    'woocommerce_blocks_payment_method_type_registration',
     88    function( Automattic\WooCommerce\Blocks\Payments\PaymentMethodRegistry $payment_method_registry ) {
     89      $payment_method_registry->register(new WC_Block_Gateway_VentiPay());
     90    }
     91  );
     92}
    6193?>
  • ventipay/trunk/includes/class-wc-gateway-ventipay.php

    r3077772 r3108127  
    333333      if (!empty($meta_payment_id)) {
    334334        if ('pending' === $order->get_status()) {
     335          ?>
     336            <script>
     337              setTimeout(() => {
     338                window.location.reload(true)
     339              }, 10000)
     340            </script>
     341          <?php
     342
    335343          $message = [
    336             '<script type="text/javascript">setTimeout(function() { window.location.reload(true); }, 10000);</script>',
    337344            '<div class="woocommerce-info">',
    338345            '<span>',
  • ventipay/trunk/readme.txt

    r3077772 r3108127  
    33Tags: ventipay, transbank, webpay, bnpl, chile
    44Requires at least: 6.5
    5 Tested up to: 6.5.2
    6 Stable tag: 2.1.0
     5Tested up to: 6.5.3
     6Stable tag: 2.2.1
    77Requires PHP: 7.0
    88License: MIT
  • ventipay/trunk/ventipay.php

    r3077772 r3108127  
    66 * Author: VentiPay
    77 * Author URI: https://www.ventipay.com/
    8  * Version: 2.1.0
     8 * Version: 2.2.1
    99 * Requires at least: 6.5
    10  * Tested up to: 6.5.2
     10 * Tested up to: 6.5.3
    1111 * WC requires at least: 8.0.0
    12  * WC tested up to: 8.8.2
     12 * WC tested up to: 8.9.1
    1313 * Text Domain: ventipay
    1414 * Domain Path: /languages
     
    4242add_action('plugins_loaded', 'ventipay_init_gateway_class');
    4343add_action('wp_enqueue_scripts', 'ventipay_setup_scripts');
     44add_action('before_woocommerce_init', 'ventipay_declare_features_util_compatibility');
     45add_action('woocommerce_blocks_loaded', 'ventipay_blocks_loaded');
    4446
    4547/**
     
    5961  require_once dirname( __FILE__ ) . '/includes/class-wc-gateway-ventipay.php';
    6062}
     63
     64function ventipay_declare_features_util_compatibility()
     65{
     66  if (!class_exists('\Automattic\WooCommerce\Utilities\FeaturesUtil')) {
     67    return;
     68  }
     69
     70  \Automattic\WooCommerce\Utilities\FeaturesUtil::declare_compatibility('cart_checkout_blocks', __FILE__, true);
     71
     72  // checking woocommerces version for hpos
     73  if (version_compare(WC_VERSION, '8.2', '>=')) {
     74    \Automattic\WooCommerce\Utilities\FeaturesUtil::declare_compatibility('custom_order_tables', __FILE__, true);
     75  }
     76}
     77
     78function ventipay_blocks_loaded()
     79{
     80  if (!class_exists('Automattic\WooCommerce\Blocks\Payments\Integrations\AbstractPaymentMethodType')) {
     81    return;
     82  }
     83
     84  require_once dirname( __FILE__ ) . '/blocks/wc-gateway-ventipay.php';
     85
     86  add_action(
     87    'woocommerce_blocks_payment_method_type_registration',
     88    function( Automattic\WooCommerce\Blocks\Payments\PaymentMethodRegistry $payment_method_registry ) {
     89      $payment_method_registry->register(new WC_Block_Gateway_VentiPay());
     90    }
     91  );
     92}
    6193?>
Note: See TracChangeset for help on using the changeset viewer.