Changeset 2270251
- Timestamp:
- 03/29/2020 04:56:51 PM (6 years ago)
- Location:
- postpay
- Files:
-
- 15 edited
- 13 copied
-
tags/0.1.2 (copied) (copied from postpay/trunk)
-
tags/0.1.2/LICENSE (copied) (copied from postpay/trunk/LICENSE)
-
tags/0.1.2/assets (copied) (copied from postpay/trunk/assets)
-
tags/0.1.2/includes (copied) (copied from postpay/trunk/includes)
-
tags/0.1.2/includes/class-wc-postpay-gateway.php (modified) (5 diffs)
-
tags/0.1.2/includes/http/class-wc-postpay-adapter.php (copied) (copied from postpay/trunk/includes/http/class-wc-postpay-adapter.php) (6 diffs)
-
tags/0.1.2/includes/wc-postpay-scripts.php (copied) (copied from postpay/trunk/includes/wc-postpay-scripts.php)
-
tags/0.1.2/languages (copied) (copied from postpay/trunk/languages)
-
tags/0.1.2/languages/postpay-es_ES.mo (modified) (previous)
-
tags/0.1.2/languages/postpay-es_ES.po (copied) (copied from postpay/trunk/languages/postpay-es_ES.po) (7 diffs)
-
tags/0.1.2/languages/postpay.pot (copied) (copied from postpay/trunk/languages/postpay.pot) (6 diffs)
-
tags/0.1.2/postpay.php (copied) (copied from postpay/trunk/postpay.php) (2 diffs)
-
tags/0.1.2/readme.txt (copied) (copied from postpay/trunk/readme.txt) (2 diffs)
-
tags/0.1.2/templates (copied) (copied from postpay/trunk/templates)
-
tags/0.1.2/vendor (copied) (copied from postpay/trunk/vendor)
-
tags/0.1.2/vendor/autoload.php (modified) (1 diff)
-
tags/0.1.2/vendor/composer/autoload_real.php (modified) (3 diffs)
-
tags/0.1.2/vendor/composer/autoload_static.php (modified) (2 diffs)
-
trunk/includes/class-wc-postpay-gateway.php (modified) (5 diffs)
-
trunk/includes/http/class-wc-postpay-adapter.php (modified) (6 diffs)
-
trunk/languages/postpay-es_ES.mo (modified) (previous)
-
trunk/languages/postpay-es_ES.po (modified) (7 diffs)
-
trunk/languages/postpay.pot (modified) (6 diffs)
-
trunk/postpay.php (modified) (2 diffs)
-
trunk/readme.txt (modified) (2 diffs)
-
trunk/vendor/autoload.php (modified) (1 diff)
-
trunk/vendor/composer/autoload_real.php (modified) (3 diffs)
-
trunk/vendor/composer/autoload_static.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
postpay/tags/0.1.2/includes/class-wc-postpay-gateway.php
r2267104 r2270251 54 54 55 55 /** 56 * Check if the gateway is available for use. 57 * 58 * @return bool 59 */ 60 public function is_available() { 61 return ( 62 parent::is_available() && 63 ! empty( $this->get_option( 'merchant_id' ) ) && 64 ! empty( $this->get_secret_key() ) 65 ); 66 } 67 68 /** 56 69 * Initialise settings form fields. 57 70 */ … … 61 74 62 75 /** 63 * Builds our payment fields area. 76 * Get secret key. 77 * 78 * @return string 79 */ 80 public function get_secret_key() { 81 return $this->sandbox ? $this->get_option( 'sandbox_secret_key' ) : $this->get_option( 'secret_key' ); 82 } 83 84 /** 85 * Build the payment fields area. 64 86 */ 65 87 public function payment_fields() { … … 169 191 $this->adapter->refund( $transaction_id, $refund_id, $amount, $reason ); 170 192 } catch ( ApiException $e ) { 171 $order->add_order_note( 193 return new WP_Error( 194 'refund_error', 172 195 sprintf( /* translators: %1$s: transaction id %2$s: error code */ 173 196 __( 'Postpay refund failed. ID: %1$s. Code: %2$s.', 'postpay' ), … … 176 199 ) 177 200 ); 178 return false; 201 } catch ( Exception $e ) { 202 return new WP_Error( 'refund_error', $e->getMessage() ); 179 203 } 180 204 return true; … … 185 209 */ 186 210 public function load_scripts() { 187 if ( ! $this->is_available() ) { 188 return; 189 } 190 191 if ( is_checkout() && ! empty( $_GET[ $this->token_param ] ) ) { 211 if ( $this->is_available() && is_checkout() && ! empty( $_GET[ $this->token_param ] ) ) { 192 212 wc_postpay_script( 193 213 'wc-postpay-checkout', -
postpay/tags/0.1.2/includes/http/class-wc-postpay-adapter.php
r2267312 r2270251 38 38 require_once WC_POSTPAY_DIR_PATH . 'includes/http/class-wc-postpay-client.php'; 39 39 40 $this->client = new Postpay( 41 array( 42 'sandbox' => $gateway->sandbox, 43 'merchant_id' => $gateway->get_option( 'merchant_id' ), 44 'secret_key' => $gateway->get_option( 'sandbox_secret_key' ), 45 'client_handler' => new WC_Postpay_Client(), 46 ) 47 ); 40 if ( $this->gateway->is_available() ) { 41 $this->client = new Postpay( 42 array( 43 'sandbox' => $gateway->sandbox, 44 'merchant_id' => $gateway->get_option( 'merchant_id' ), 45 'secret_key' => $gateway->get_secret_key(), 46 'client_handler' => new WC_Postpay_Client(), 47 ) 48 ); 49 } 48 50 } 49 51 … … 57 59 * @return array 58 60 * 61 * @throws Exception If payment method is not properly configured. 59 62 * @throws ApiException If response status code is invalid. 60 63 */ 61 64 public function request( $method, $path, $params = array() ) { 65 if ( ! $this->gateway->is_available() ) { 66 throw new Exception( __( 'Postpay is not properly configured.', 'postpay' ) ); 67 } 68 62 69 try { 63 70 $response = $this->client->request( $method, $path, $params ); … … 87 94 * @return array 88 95 * 96 * @throws Exception If payment method is not properly configured. 89 97 * @throws ApiException If response status code is invalid. 90 98 */ … … 100 108 * @return array 101 109 * 110 * @throws Exception If payment method is not properly configured. 102 111 * @throws ApiException If response status code is invalid. 103 112 */ … … 114 123 * @return array 115 124 * 125 * @throws Exception If payment method is not properly configured. 116 126 * @throws ApiException If response status code is invalid. 117 127 */ … … 130 140 * @return array 131 141 * 142 * @throws Exception If payment method is not properly configured. 132 143 * @throws ApiException If response status code is invalid. 133 144 */ -
postpay/tags/0.1.2/languages/postpay-es_ES.po
r2267312 r2270251 5 5 "Project-Id-Version: Postpay 0.1.1\n" 6 6 "Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/postpay\n" 7 "Language-Team: \n"7 "Language-Team: Spanish (Spain)\n" 8 8 "MIME-Version: 1.0\n" 9 9 "Content-Type: text/plain; charset=UTF-8\n" 10 10 "Content-Transfer-Encoding: 8bit\n" 11 "POT-Creation-Date: 2020-03-2 5T03:33:01+00:00\n"12 "PO-Revision-Date: 2020-03-2 5 11:40+0700\n"11 "POT-Creation-Date: 2020-03-29T16:27:19+00:00\n" 12 "PO-Revision-Date: 2020-03-29 16:45+0000\n" 13 13 "X-Generator: Poedit 2.3\n" 14 14 "X-Domain: postpay\n" 15 "Last-Translator: \n"15 "Last-Translator: mongkok <dani@postpay.io>\n" 16 16 "Plural-Forms: nplurals=2; plural=(n != 1);\n" 17 "Language: es \n"17 "Language: es_ES\n" 18 18 19 19 #. Plugin Name of the plugin 20 #. Author of the plugin 21 #: includes/class-wc-postpay-gateway.php:28 includes/wc-postpay-settings.php:19 22 msgid "Postpay" 20 msgid "WooCommerce Postpay Payment Gateway" 23 21 msgstr "" 24 22 … … 31 29 msgid "Buy now and pay later with zero interest and zero fees." 32 30 msgstr "Compra ahora y paga más tarde con cero interés y sin cargos." 31 32 #. Plugin Name of the plugin 33 #. Author of the plugin 34 #: includes/class-wc-postpay-gateway.php:28 includes/wc-postpay-settings.php:19 35 msgid "Postpay" 36 msgstr "" 33 37 34 38 #. Author URI of the plugin … … 45 49 46 50 #. translators: %1$s: transaction id %2$s: error code 47 #: includes/class-wc-postpay-gateway.php:1 1951 #: includes/class-wc-postpay-gateway.php:141 48 52 msgid "Postpay capture failed. ID: %1$s. Code: %2$s." 49 53 msgstr "La captura con Postpay falló. ID: %1$s. Código: %2$s." 50 54 51 #: includes/class-wc-postpay-gateway.php:1 2855 #: includes/class-wc-postpay-gateway.php:150 52 56 msgid "Postpay capture error." 53 57 msgstr "Postpay error de captura." 54 58 55 59 #. translators: %1$s: transaction id %2$s: order status 56 #: includes/class-wc-postpay-gateway.php:1 4460 #: includes/class-wc-postpay-gateway.php:166 57 61 msgid "Postpay order cancelled. ID: %1$s. Status: %2$s." 58 62 msgstr "Postpay pedido cancelado. ID: %1$s. Estado: %2$s." 59 63 60 #: includes/class-wc-postpay-gateway.php:1 5064 #: includes/class-wc-postpay-gateway.php:172 61 65 msgid "Postpay order cancelled." 62 66 msgstr "Postpay pedido cancelado." 63 67 64 68 #. translators: %1$s: transaction id %2$s: error code 65 #: includes/class-wc-postpay-gateway.php:1 7369 #: includes/class-wc-postpay-gateway.php:196 66 70 msgid "Postpay refund failed. ID: %1$s. Code: %2$s." 67 71 msgstr "La devolución con Postpay falló. ID: %1$s. Código: %2$s." 72 73 #: includes/http/class-wc-postpay-adapter.php:66 74 msgid "Postpay is not properly configured." 75 msgstr "Postpay no está configurado correctamente." 68 76 69 77 #: includes/wc-postpay-settings.php:10 … … 81 89 #: includes/wc-postpay-settings.php:18 82 90 msgid "This controls the title which the user sees during checkout." 83 msgstr "Esto controla el título que el usuario ve durante el proceso de compra." 91 msgstr "" 92 "Esto controla el título que el usuario ve durante el proceso de compra." 84 93 85 94 #: includes/wc-postpay-settings.php:23 … … 89 98 #: includes/wc-postpay-settings.php:26 90 99 msgid "This controls the description which the user sees during checkout." 91 msgstr "Esto controla la descripción que el usuario ve durante el proceso de compra." 100 msgstr "" 101 "Esto controla la descripción que el usuario ve durante el proceso de compra." 92 102 93 103 #: includes/wc-postpay-settings.php:30 … … 137 147 #: includes/wc-postpay-settings.php:62 138 148 msgid "Checkout flow that keeps customers local to your website." 139 msgstr "Proceso de checkout que mantiene a los clientes localizados en su sitio web." 149 msgstr "" 150 "Proceso de checkout que mantiene a los clientes localizados en su sitio web." 140 151 141 152 #: includes/wc-postpay-settings.php:65 … … 175 186 msgstr "Mostrar un mensaje promocional en la página del carrito." 176 187 177 #: postpay.php:1 09188 #: postpay.php:111 178 189 msgid "Settings" 179 190 msgstr "Configuración" -
postpay/tags/0.1.2/languages/postpay.pot
r2267312 r2270251 3 3 msgid "" 4 4 msgstr "" 5 "Project-Id-Version: Postpay 0.1.1\n"5 "Project-Id-Version: WooCommerce Postpay Payment Gateway 0.1.2\n" 6 6 "Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/postpay\n" 7 7 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" … … 10 10 "Content-Type: text/plain; charset=UTF-8\n" 11 11 "Content-Transfer-Encoding: 8bit\n" 12 "POT-Creation-Date: 2020-03-2 5T03:33:01+00:00\n"12 "POT-Creation-Date: 2020-03-29T16:27:19+00:00\n" 13 13 "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" 14 14 "X-Generator: WP-CLI 2.4.0\n" … … 16 16 17 17 #. Plugin Name of the plugin 18 #. Author of the plugin 19 #: includes/class-wc-postpay-gateway.php:28 20 #: includes/wc-postpay-settings.php:19 21 msgid "Postpay" 18 msgid "WooCommerce Postpay Payment Gateway" 22 19 msgstr "" 23 20 … … 30 27 #: includes/wc-postpay-settings.php:27 31 28 msgid "Buy now and pay later with zero interest and zero fees." 29 msgstr "" 30 31 #. Author of the plugin 32 #: includes/class-wc-postpay-gateway.php:28 33 #: includes/wc-postpay-settings.php:19 34 msgid "Postpay" 32 35 msgstr "" 33 36 … … 45 48 46 49 #. translators: %1$s: transaction id %2$s: error code 47 #: includes/class-wc-postpay-gateway.php:1 1950 #: includes/class-wc-postpay-gateway.php:141 48 51 msgid "Postpay capture failed. ID: %1$s. Code: %2$s." 49 52 msgstr "" 50 53 51 #: includes/class-wc-postpay-gateway.php:1 2854 #: includes/class-wc-postpay-gateway.php:150 52 55 msgid "Postpay capture error." 53 56 msgstr "" 54 57 55 58 #. translators: %1$s: transaction id %2$s: order status 56 #: includes/class-wc-postpay-gateway.php:1 4459 #: includes/class-wc-postpay-gateway.php:166 57 60 msgid "Postpay order cancelled. ID: %1$s. Status: %2$s." 58 61 msgstr "" 59 62 60 #: includes/class-wc-postpay-gateway.php:1 5063 #: includes/class-wc-postpay-gateway.php:172 61 64 msgid "Postpay order cancelled." 62 65 msgstr "" 63 66 64 67 #. translators: %1$s: transaction id %2$s: error code 65 #: includes/class-wc-postpay-gateway.php:1 7368 #: includes/class-wc-postpay-gateway.php:196 66 69 msgid "Postpay refund failed. ID: %1$s. Code: %2$s." 70 msgstr "" 71 72 #: includes/http/class-wc-postpay-adapter.php:66 73 msgid "Postpay is not properly configured." 67 74 msgstr "" 68 75 … … 175 182 msgstr "" 176 183 177 #: postpay.php:1 09184 #: postpay.php:111 178 185 msgid "Settings" 179 186 msgstr "" -
postpay/tags/0.1.2/postpay.php
r2267312 r2270251 2 2 /** 3 3 * Plugin Name: WooCommerce Postpay Payment Gateway 4 * Version: 0.1. 14 * Version: 0.1.2 5 5 * Plugin URI: https://github.com/postpayio/woocommerce 6 6 * Description: Buy now and pay later with zero interest and zero fees. … … 62 62 63 63 $this->settings = get_option( 'woocommerce_' . self::PAYMENT_GATEWAY_ID . '_settings' ); 64 $this->enabled = 'yes' === $this->settings['enabled'] ;64 $this->enabled = 'yes' === $this->settings['enabled'] && ! empty( $this->settings['merchant_id'] ); 65 65 66 66 if ( ! class_exists( '\\Postpay\\Postpay' ) ) { -
postpay/tags/0.1.2/readme.txt
r2267312 r2270251 4 4 Tested up to: 5.3.2 5 5 Requires PHP: 5.6 6 Stable tag: 0.1. 17 Version: 0.1. 16 Stable tag: 0.1.2 7 Version: 0.1.2 8 8 License: GPLv3 9 9 License URI: https://www.gnu.org/licenses/gpl-3.0.html … … 73 73 == Changelog == 74 74 75 = 0.1.2 - 2020-03-30 = 76 * Disabled module if merchantId is not defined 77 * Added is_available method to WC_Postpay_Gateway 78 * Returned WP_Error instance on refund errors 79 75 80 = 0.1.1 - 2020-03-25 = 76 81 * Renamed plugin -
postpay/tags/0.1.2/vendor/autoload.php
r2267104 r2270251 5 5 require_once __DIR__ . '/composer/autoload_real.php'; 6 6 7 return ComposerAutoloaderInit a7bb61d5401fdd5778720c8c3ee5ae83::getLoader();7 return ComposerAutoloaderInit35361e866813e1f773c8bd2a5ec3d227::getLoader(); -
postpay/tags/0.1.2/vendor/composer/autoload_real.php
r2267104 r2270251 3 3 // autoload_real.php @generated by Composer 4 4 5 class ComposerAutoloaderInit a7bb61d5401fdd5778720c8c3ee5ae835 class ComposerAutoloaderInit35361e866813e1f773c8bd2a5ec3d227 6 6 { 7 7 private static $loader; … … 20 20 } 21 21 22 spl_autoload_register(array('ComposerAutoloaderInit a7bb61d5401fdd5778720c8c3ee5ae83', 'loadClassLoader'), true, true);22 spl_autoload_register(array('ComposerAutoloaderInit35361e866813e1f773c8bd2a5ec3d227', 'loadClassLoader'), true, true); 23 23 self::$loader = $loader = new \Composer\Autoload\ClassLoader(); 24 spl_autoload_unregister(array('ComposerAutoloaderInit a7bb61d5401fdd5778720c8c3ee5ae83', 'loadClassLoader'));24 spl_autoload_unregister(array('ComposerAutoloaderInit35361e866813e1f773c8bd2a5ec3d227', 'loadClassLoader')); 25 25 26 26 $useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded()); … … 28 28 require_once __DIR__ . '/autoload_static.php'; 29 29 30 call_user_func(\Composer\Autoload\ComposerStaticInit a7bb61d5401fdd5778720c8c3ee5ae83::getInitializer($loader));30 call_user_func(\Composer\Autoload\ComposerStaticInit35361e866813e1f773c8bd2a5ec3d227::getInitializer($loader)); 31 31 } else { 32 32 $map = require __DIR__ . '/autoload_namespaces.php'; -
postpay/tags/0.1.2/vendor/composer/autoload_static.php
r2267104 r2270251 5 5 namespace Composer\Autoload; 6 6 7 class ComposerStaticInit a7bb61d5401fdd5778720c8c3ee5ae837 class ComposerStaticInit35361e866813e1f773c8bd2a5ec3d227 8 8 { 9 9 public static $prefixLengthsPsr4 = array ( … … 32 32 { 33 33 return \Closure::bind(function () use ($loader) { 34 $loader->prefixLengthsPsr4 = ComposerStaticInit a7bb61d5401fdd5778720c8c3ee5ae83::$prefixLengthsPsr4;35 $loader->prefixDirsPsr4 = ComposerStaticInit a7bb61d5401fdd5778720c8c3ee5ae83::$prefixDirsPsr4;34 $loader->prefixLengthsPsr4 = ComposerStaticInit35361e866813e1f773c8bd2a5ec3d227::$prefixLengthsPsr4; 35 $loader->prefixDirsPsr4 = ComposerStaticInit35361e866813e1f773c8bd2a5ec3d227::$prefixDirsPsr4; 36 36 37 37 }, null, ClassLoader::class); -
postpay/trunk/includes/class-wc-postpay-gateway.php
r2267104 r2270251 54 54 55 55 /** 56 * Check if the gateway is available for use. 57 * 58 * @return bool 59 */ 60 public function is_available() { 61 return ( 62 parent::is_available() && 63 ! empty( $this->get_option( 'merchant_id' ) ) && 64 ! empty( $this->get_secret_key() ) 65 ); 66 } 67 68 /** 56 69 * Initialise settings form fields. 57 70 */ … … 61 74 62 75 /** 63 * Builds our payment fields area. 76 * Get secret key. 77 * 78 * @return string 79 */ 80 public function get_secret_key() { 81 return $this->sandbox ? $this->get_option( 'sandbox_secret_key' ) : $this->get_option( 'secret_key' ); 82 } 83 84 /** 85 * Build the payment fields area. 64 86 */ 65 87 public function payment_fields() { … … 169 191 $this->adapter->refund( $transaction_id, $refund_id, $amount, $reason ); 170 192 } catch ( ApiException $e ) { 171 $order->add_order_note( 193 return new WP_Error( 194 'refund_error', 172 195 sprintf( /* translators: %1$s: transaction id %2$s: error code */ 173 196 __( 'Postpay refund failed. ID: %1$s. Code: %2$s.', 'postpay' ), … … 176 199 ) 177 200 ); 178 return false; 201 } catch ( Exception $e ) { 202 return new WP_Error( 'refund_error', $e->getMessage() ); 179 203 } 180 204 return true; … … 185 209 */ 186 210 public function load_scripts() { 187 if ( ! $this->is_available() ) { 188 return; 189 } 190 191 if ( is_checkout() && ! empty( $_GET[ $this->token_param ] ) ) { 211 if ( $this->is_available() && is_checkout() && ! empty( $_GET[ $this->token_param ] ) ) { 192 212 wc_postpay_script( 193 213 'wc-postpay-checkout', -
postpay/trunk/includes/http/class-wc-postpay-adapter.php
r2267312 r2270251 38 38 require_once WC_POSTPAY_DIR_PATH . 'includes/http/class-wc-postpay-client.php'; 39 39 40 $this->client = new Postpay( 41 array( 42 'sandbox' => $gateway->sandbox, 43 'merchant_id' => $gateway->get_option( 'merchant_id' ), 44 'secret_key' => $gateway->get_option( 'sandbox_secret_key' ), 45 'client_handler' => new WC_Postpay_Client(), 46 ) 47 ); 40 if ( $this->gateway->is_available() ) { 41 $this->client = new Postpay( 42 array( 43 'sandbox' => $gateway->sandbox, 44 'merchant_id' => $gateway->get_option( 'merchant_id' ), 45 'secret_key' => $gateway->get_secret_key(), 46 'client_handler' => new WC_Postpay_Client(), 47 ) 48 ); 49 } 48 50 } 49 51 … … 57 59 * @return array 58 60 * 61 * @throws Exception If payment method is not properly configured. 59 62 * @throws ApiException If response status code is invalid. 60 63 */ 61 64 public function request( $method, $path, $params = array() ) { 65 if ( ! $this->gateway->is_available() ) { 66 throw new Exception( __( 'Postpay is not properly configured.', 'postpay' ) ); 67 } 68 62 69 try { 63 70 $response = $this->client->request( $method, $path, $params ); … … 87 94 * @return array 88 95 * 96 * @throws Exception If payment method is not properly configured. 89 97 * @throws ApiException If response status code is invalid. 90 98 */ … … 100 108 * @return array 101 109 * 110 * @throws Exception If payment method is not properly configured. 102 111 * @throws ApiException If response status code is invalid. 103 112 */ … … 114 123 * @return array 115 124 * 125 * @throws Exception If payment method is not properly configured. 116 126 * @throws ApiException If response status code is invalid. 117 127 */ … … 130 140 * @return array 131 141 * 142 * @throws Exception If payment method is not properly configured. 132 143 * @throws ApiException If response status code is invalid. 133 144 */ -
postpay/trunk/languages/postpay-es_ES.po
r2267312 r2270251 5 5 "Project-Id-Version: Postpay 0.1.1\n" 6 6 "Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/postpay\n" 7 "Language-Team: \n"7 "Language-Team: Spanish (Spain)\n" 8 8 "MIME-Version: 1.0\n" 9 9 "Content-Type: text/plain; charset=UTF-8\n" 10 10 "Content-Transfer-Encoding: 8bit\n" 11 "POT-Creation-Date: 2020-03-2 5T03:33:01+00:00\n"12 "PO-Revision-Date: 2020-03-2 5 11:40+0700\n"11 "POT-Creation-Date: 2020-03-29T16:27:19+00:00\n" 12 "PO-Revision-Date: 2020-03-29 16:45+0000\n" 13 13 "X-Generator: Poedit 2.3\n" 14 14 "X-Domain: postpay\n" 15 "Last-Translator: \n"15 "Last-Translator: mongkok <dani@postpay.io>\n" 16 16 "Plural-Forms: nplurals=2; plural=(n != 1);\n" 17 "Language: es \n"17 "Language: es_ES\n" 18 18 19 19 #. Plugin Name of the plugin 20 #. Author of the plugin 21 #: includes/class-wc-postpay-gateway.php:28 includes/wc-postpay-settings.php:19 22 msgid "Postpay" 20 msgid "WooCommerce Postpay Payment Gateway" 23 21 msgstr "" 24 22 … … 31 29 msgid "Buy now and pay later with zero interest and zero fees." 32 30 msgstr "Compra ahora y paga más tarde con cero interés y sin cargos." 31 32 #. Plugin Name of the plugin 33 #. Author of the plugin 34 #: includes/class-wc-postpay-gateway.php:28 includes/wc-postpay-settings.php:19 35 msgid "Postpay" 36 msgstr "" 33 37 34 38 #. Author URI of the plugin … … 45 49 46 50 #. translators: %1$s: transaction id %2$s: error code 47 #: includes/class-wc-postpay-gateway.php:1 1951 #: includes/class-wc-postpay-gateway.php:141 48 52 msgid "Postpay capture failed. ID: %1$s. Code: %2$s." 49 53 msgstr "La captura con Postpay falló. ID: %1$s. Código: %2$s." 50 54 51 #: includes/class-wc-postpay-gateway.php:1 2855 #: includes/class-wc-postpay-gateway.php:150 52 56 msgid "Postpay capture error." 53 57 msgstr "Postpay error de captura." 54 58 55 59 #. translators: %1$s: transaction id %2$s: order status 56 #: includes/class-wc-postpay-gateway.php:1 4460 #: includes/class-wc-postpay-gateway.php:166 57 61 msgid "Postpay order cancelled. ID: %1$s. Status: %2$s." 58 62 msgstr "Postpay pedido cancelado. ID: %1$s. Estado: %2$s." 59 63 60 #: includes/class-wc-postpay-gateway.php:1 5064 #: includes/class-wc-postpay-gateway.php:172 61 65 msgid "Postpay order cancelled." 62 66 msgstr "Postpay pedido cancelado." 63 67 64 68 #. translators: %1$s: transaction id %2$s: error code 65 #: includes/class-wc-postpay-gateway.php:1 7369 #: includes/class-wc-postpay-gateway.php:196 66 70 msgid "Postpay refund failed. ID: %1$s. Code: %2$s." 67 71 msgstr "La devolución con Postpay falló. ID: %1$s. Código: %2$s." 72 73 #: includes/http/class-wc-postpay-adapter.php:66 74 msgid "Postpay is not properly configured." 75 msgstr "Postpay no está configurado correctamente." 68 76 69 77 #: includes/wc-postpay-settings.php:10 … … 81 89 #: includes/wc-postpay-settings.php:18 82 90 msgid "This controls the title which the user sees during checkout." 83 msgstr "Esto controla el título que el usuario ve durante el proceso de compra." 91 msgstr "" 92 "Esto controla el título que el usuario ve durante el proceso de compra." 84 93 85 94 #: includes/wc-postpay-settings.php:23 … … 89 98 #: includes/wc-postpay-settings.php:26 90 99 msgid "This controls the description which the user sees during checkout." 91 msgstr "Esto controla la descripción que el usuario ve durante el proceso de compra." 100 msgstr "" 101 "Esto controla la descripción que el usuario ve durante el proceso de compra." 92 102 93 103 #: includes/wc-postpay-settings.php:30 … … 137 147 #: includes/wc-postpay-settings.php:62 138 148 msgid "Checkout flow that keeps customers local to your website." 139 msgstr "Proceso de checkout que mantiene a los clientes localizados en su sitio web." 149 msgstr "" 150 "Proceso de checkout que mantiene a los clientes localizados en su sitio web." 140 151 141 152 #: includes/wc-postpay-settings.php:65 … … 175 186 msgstr "Mostrar un mensaje promocional en la página del carrito." 176 187 177 #: postpay.php:1 09188 #: postpay.php:111 178 189 msgid "Settings" 179 190 msgstr "Configuración" -
postpay/trunk/languages/postpay.pot
r2267312 r2270251 3 3 msgid "" 4 4 msgstr "" 5 "Project-Id-Version: Postpay 0.1.1\n"5 "Project-Id-Version: WooCommerce Postpay Payment Gateway 0.1.2\n" 6 6 "Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/postpay\n" 7 7 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" … … 10 10 "Content-Type: text/plain; charset=UTF-8\n" 11 11 "Content-Transfer-Encoding: 8bit\n" 12 "POT-Creation-Date: 2020-03-2 5T03:33:01+00:00\n"12 "POT-Creation-Date: 2020-03-29T16:27:19+00:00\n" 13 13 "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" 14 14 "X-Generator: WP-CLI 2.4.0\n" … … 16 16 17 17 #. Plugin Name of the plugin 18 #. Author of the plugin 19 #: includes/class-wc-postpay-gateway.php:28 20 #: includes/wc-postpay-settings.php:19 21 msgid "Postpay" 18 msgid "WooCommerce Postpay Payment Gateway" 22 19 msgstr "" 23 20 … … 30 27 #: includes/wc-postpay-settings.php:27 31 28 msgid "Buy now and pay later with zero interest and zero fees." 29 msgstr "" 30 31 #. Author of the plugin 32 #: includes/class-wc-postpay-gateway.php:28 33 #: includes/wc-postpay-settings.php:19 34 msgid "Postpay" 32 35 msgstr "" 33 36 … … 45 48 46 49 #. translators: %1$s: transaction id %2$s: error code 47 #: includes/class-wc-postpay-gateway.php:1 1950 #: includes/class-wc-postpay-gateway.php:141 48 51 msgid "Postpay capture failed. ID: %1$s. Code: %2$s." 49 52 msgstr "" 50 53 51 #: includes/class-wc-postpay-gateway.php:1 2854 #: includes/class-wc-postpay-gateway.php:150 52 55 msgid "Postpay capture error." 53 56 msgstr "" 54 57 55 58 #. translators: %1$s: transaction id %2$s: order status 56 #: includes/class-wc-postpay-gateway.php:1 4459 #: includes/class-wc-postpay-gateway.php:166 57 60 msgid "Postpay order cancelled. ID: %1$s. Status: %2$s." 58 61 msgstr "" 59 62 60 #: includes/class-wc-postpay-gateway.php:1 5063 #: includes/class-wc-postpay-gateway.php:172 61 64 msgid "Postpay order cancelled." 62 65 msgstr "" 63 66 64 67 #. translators: %1$s: transaction id %2$s: error code 65 #: includes/class-wc-postpay-gateway.php:1 7368 #: includes/class-wc-postpay-gateway.php:196 66 69 msgid "Postpay refund failed. ID: %1$s. Code: %2$s." 70 msgstr "" 71 72 #: includes/http/class-wc-postpay-adapter.php:66 73 msgid "Postpay is not properly configured." 67 74 msgstr "" 68 75 … … 175 182 msgstr "" 176 183 177 #: postpay.php:1 09184 #: postpay.php:111 178 185 msgid "Settings" 179 186 msgstr "" -
postpay/trunk/postpay.php
r2267312 r2270251 2 2 /** 3 3 * Plugin Name: WooCommerce Postpay Payment Gateway 4 * Version: 0.1. 14 * Version: 0.1.2 5 5 * Plugin URI: https://github.com/postpayio/woocommerce 6 6 * Description: Buy now and pay later with zero interest and zero fees. … … 62 62 63 63 $this->settings = get_option( 'woocommerce_' . self::PAYMENT_GATEWAY_ID . '_settings' ); 64 $this->enabled = 'yes' === $this->settings['enabled'] ;64 $this->enabled = 'yes' === $this->settings['enabled'] && ! empty( $this->settings['merchant_id'] ); 65 65 66 66 if ( ! class_exists( '\\Postpay\\Postpay' ) ) { -
postpay/trunk/readme.txt
r2267312 r2270251 4 4 Tested up to: 5.3.2 5 5 Requires PHP: 5.6 6 Stable tag: 0.1. 17 Version: 0.1. 16 Stable tag: 0.1.2 7 Version: 0.1.2 8 8 License: GPLv3 9 9 License URI: https://www.gnu.org/licenses/gpl-3.0.html … … 73 73 == Changelog == 74 74 75 = 0.1.2 - 2020-03-30 = 76 * Disabled module if merchantId is not defined 77 * Added is_available method to WC_Postpay_Gateway 78 * Returned WP_Error instance on refund errors 79 75 80 = 0.1.1 - 2020-03-25 = 76 81 * Renamed plugin -
postpay/trunk/vendor/autoload.php
r2267104 r2270251 5 5 require_once __DIR__ . '/composer/autoload_real.php'; 6 6 7 return ComposerAutoloaderInit a7bb61d5401fdd5778720c8c3ee5ae83::getLoader();7 return ComposerAutoloaderInit35361e866813e1f773c8bd2a5ec3d227::getLoader(); -
postpay/trunk/vendor/composer/autoload_real.php
r2267104 r2270251 3 3 // autoload_real.php @generated by Composer 4 4 5 class ComposerAutoloaderInit a7bb61d5401fdd5778720c8c3ee5ae835 class ComposerAutoloaderInit35361e866813e1f773c8bd2a5ec3d227 6 6 { 7 7 private static $loader; … … 20 20 } 21 21 22 spl_autoload_register(array('ComposerAutoloaderInit a7bb61d5401fdd5778720c8c3ee5ae83', 'loadClassLoader'), true, true);22 spl_autoload_register(array('ComposerAutoloaderInit35361e866813e1f773c8bd2a5ec3d227', 'loadClassLoader'), true, true); 23 23 self::$loader = $loader = new \Composer\Autoload\ClassLoader(); 24 spl_autoload_unregister(array('ComposerAutoloaderInit a7bb61d5401fdd5778720c8c3ee5ae83', 'loadClassLoader'));24 spl_autoload_unregister(array('ComposerAutoloaderInit35361e866813e1f773c8bd2a5ec3d227', 'loadClassLoader')); 25 25 26 26 $useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded()); … … 28 28 require_once __DIR__ . '/autoload_static.php'; 29 29 30 call_user_func(\Composer\Autoload\ComposerStaticInit a7bb61d5401fdd5778720c8c3ee5ae83::getInitializer($loader));30 call_user_func(\Composer\Autoload\ComposerStaticInit35361e866813e1f773c8bd2a5ec3d227::getInitializer($loader)); 31 31 } else { 32 32 $map = require __DIR__ . '/autoload_namespaces.php'; -
postpay/trunk/vendor/composer/autoload_static.php
r2267104 r2270251 5 5 namespace Composer\Autoload; 6 6 7 class ComposerStaticInit a7bb61d5401fdd5778720c8c3ee5ae837 class ComposerStaticInit35361e866813e1f773c8bd2a5ec3d227 8 8 { 9 9 public static $prefixLengthsPsr4 = array ( … … 32 32 { 33 33 return \Closure::bind(function () use ($loader) { 34 $loader->prefixLengthsPsr4 = ComposerStaticInit a7bb61d5401fdd5778720c8c3ee5ae83::$prefixLengthsPsr4;35 $loader->prefixDirsPsr4 = ComposerStaticInit a7bb61d5401fdd5778720c8c3ee5ae83::$prefixDirsPsr4;34 $loader->prefixLengthsPsr4 = ComposerStaticInit35361e866813e1f773c8bd2a5ec3d227::$prefixLengthsPsr4; 35 $loader->prefixDirsPsr4 = ComposerStaticInit35361e866813e1f773c8bd2a5ec3d227::$prefixDirsPsr4; 36 36 37 37 }, null, ClassLoader::class);
Note: See TracChangeset
for help on using the changeset viewer.