Changeset 3141395
- Timestamp:
- 08/26/2024 04:26:04 AM (20 months ago)
- Location:
- kiskadi
- Files:
-
- 11 edited
- 1 copied
-
tags/1.3.0 (copied) (copied from kiskadi/trunk)
-
tags/1.3.0/includes/class-kiskadi.php (modified) (1 diff)
-
tags/1.3.0/includes/integration/woocommerce/admin/class-kiskadi-integration-admin.php (modified) (3 diffs)
-
tags/1.3.0/includes/integration/woocommerce/class-order-status.php (modified) (1 diff)
-
tags/1.3.0/kiskadi.php (modified) (1 diff)
-
tags/1.3.0/readme.txt (modified) (2 diffs)
-
trunk/includes/class-kiskadi.php (modified) (1 diff)
-
trunk/includes/integration/woocommerce/admin/class-kiskadi-integration-admin.php (modified) (3 diffs)
-
trunk/includes/integration/woocommerce/class-order-status.php (modified) (1 diff)
-
trunk/includes/integration/woocommerce/order/class-order-consumer-extractor.php (modified) (1 diff)
-
trunk/kiskadi.php (modified) (1 diff)
-
trunk/readme.txt (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
kiskadi/tags/1.3.0/includes/class-kiskadi.php
r3103793 r3141395 12 12 13 13 /** @var string */ 14 public $version = '1. 2.6';14 public $version = '1.3.0'; 15 15 16 16 /** @var self */ -
kiskadi/tags/1.3.0/includes/integration/woocommerce/admin/class-kiskadi-integration-admin.php
r3095899 r3141395 26 26 /** @return array<string,array<string,mixed>> */ 27 27 private function form_fields() : array { 28 29 $gateways = WC()->payment_gateways->get_available_payment_gateways(); 30 $active_gateways = []; 31 foreach($gateways as $id => $gateway) { 32 $active_gateways[$id] = $gateway->get_title(); 33 } 34 28 35 return array( 29 36 'user' => array( … … 54 61 'default' => 'yes', 55 62 'description' => __( 'Enable the option to send transaction to Kiskadi', 'kiskadi' ), 63 ), 64 'enable_transaction_by_payment_methods' => array( 65 'title' => __( 'Transactions by Payment Methods', 'kiskadi' ), 66 'type' => 'multiselect', 67 'description' => __( 'Choose the Payment Methods.', 'kiskadi' ), 68 'default' => array_keys($active_gateways), 69 'desc_tip' => true, 70 'options' => $active_gateways 56 71 ), 57 72 'debug' => array( … … 95 110 return true; 96 111 } 112 113 public function payment_methods_enable() : array { 114 return $this->get_option( 'enable_transaction_by_payment_methods' ); 115 } 97 116 } -
kiskadi/tags/1.3.0/includes/integration/woocommerce/class-order-status.php
r3095899 r3141395 45 45 } 46 46 47 $payment_methods_enable = ( new Kiskadi_Integration_Admin() )->payment_methods_enable(); 48 if (!in_array($order->get_payment_method(),$payment_methods_enable)) { 49 return; 50 } 51 47 52 try { 48 53 $this->send_order_data( $order, $branch_data ); -
kiskadi/tags/1.3.0/kiskadi.php
r3103793 r3141395 8 8 * Text Domain: kiskadi 9 9 * Domain Path: /languages 10 * Version: 1. 2.610 * Version: 1.3.0 11 11 * 12 12 * @package Kiskadi -
kiskadi/tags/1.3.0/readme.txt
r3103793 r3141395 6 6 Tested up to: 6.5.3 7 7 Requires PHP: 7.2 8 Stable tag: 1. 2.68 Stable tag: 1.3.0 9 9 License: GPLv2 or later 10 10 License URI: https://www.gnu.org/licenses/gpl-2.0.html … … 34 34 35 35 == Changelog == 36 37 = 1.3.0 = 38 * Feature - add option transaction by payment method selected 36 39 37 40 = 1.2.6 = -
kiskadi/trunk/includes/class-kiskadi.php
r3103793 r3141395 12 12 13 13 /** @var string */ 14 public $version = '1. 2.6';14 public $version = '1.3.0'; 15 15 16 16 /** @var self */ -
kiskadi/trunk/includes/integration/woocommerce/admin/class-kiskadi-integration-admin.php
r3095899 r3141395 26 26 /** @return array<string,array<string,mixed>> */ 27 27 private function form_fields() : array { 28 29 $gateways = WC()->payment_gateways->get_available_payment_gateways(); 30 $active_gateways = []; 31 foreach($gateways as $id => $gateway) { 32 $active_gateways[$id] = $gateway->get_title(); 33 } 34 28 35 return array( 29 36 'user' => array( … … 54 61 'default' => 'yes', 55 62 'description' => __( 'Enable the option to send transaction to Kiskadi', 'kiskadi' ), 63 ), 64 'enable_transaction_by_payment_methods' => array( 65 'title' => __( 'Transactions by Payment Methods', 'kiskadi' ), 66 'type' => 'multiselect', 67 'description' => __( 'Choose the Payment Methods.', 'kiskadi' ), 68 'default' => array_keys($active_gateways), 69 'desc_tip' => true, 70 'options' => $active_gateways 56 71 ), 57 72 'debug' => array( … … 95 110 return true; 96 111 } 112 113 public function payment_methods_enable() : array { 114 return $this->get_option( 'enable_transaction_by_payment_methods' ); 115 } 97 116 } -
kiskadi/trunk/includes/integration/woocommerce/class-order-status.php
r3095899 r3141395 45 45 } 46 46 47 $payment_methods_enable = ( new Kiskadi_Integration_Admin() )->payment_methods_enable(); 48 if (!in_array($order->get_payment_method(),$payment_methods_enable)) { 49 return; 50 } 51 47 52 try { 48 53 $this->send_order_data( $order, $branch_data ); -
kiskadi/trunk/includes/integration/woocommerce/order/class-order-consumer-extractor.php
r2800910 r3141395 34 34 private function person() : Person_Data { 35 35 $email = $this->order_billing_data( 'email' ); 36 $cpf = $this->order_billing_data( 'cpf' );37 $phone = $this->order_billing_data( 'phone' );38 $cellphone = $this->order_billing_data( 'cellphone' );36 // $cpf = $this->order_billing_data( 'cpf' ); 37 // $phone = $this->order_billing_data( 'phone' ); 38 // $cellphone = $this->order_billing_data( 'cellphone' ); 39 39 40 40 $person_data = new Person_Data( -
kiskadi/trunk/kiskadi.php
r3103793 r3141395 8 8 * Text Domain: kiskadi 9 9 * Domain Path: /languages 10 * Version: 1. 2.610 * Version: 1.3.0 11 11 * 12 12 * @package Kiskadi -
kiskadi/trunk/readme.txt
r3103793 r3141395 6 6 Tested up to: 6.5.3 7 7 Requires PHP: 7.2 8 Stable tag: 1. 2.68 Stable tag: 1.3.0 9 9 License: GPLv2 or later 10 10 License URI: https://www.gnu.org/licenses/gpl-2.0.html … … 34 34 35 35 == Changelog == 36 37 = 1.3.0 = 38 * Feature - add option transaction by payment method selected 36 39 37 40 = 1.2.6 =
Note: See TracChangeset
for help on using the changeset viewer.