Skip to content

Commit

Permalink
Merge pull request #596 from ebanx/staging/1.23.0
Browse files Browse the repository at this point in the history
Staging/1.23.0
  • Loading branch information
Anderson Campanha authored Dec 20, 2017
2 parents 41ade44 + f657aa8 commit 24d2f0a
Show file tree
Hide file tree
Showing 9 changed files with 59 additions and 12 deletions.
6 changes: 5 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,8 @@ node_modules
.vscode
apidocs/phpdoc-cache-*
.data
.phpintel
.phpintel

# Tests
/report/
/clover.xml
5 changes: 4 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
language: php
dist: trusty
sudo: false

script: echo 'OK';
script: phpunit

after_success: bash <(curl -s https://codecov.io/bash)

before_deploy: zip ebanx-payment-gateway-for-woocommerce ./**/*

Expand Down
8 changes: 7 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
# CHANGELOG

#1.22.0
# 1.23.0
* Feature - One click form can now be submitted using keyboard [#588](https://github.com/ebanx/woocommerce-gateway-ebanx/pull/588)
* Feature - Better payment origin identification on dashboard [#590](https://github.com/ebanx/woocommerce-gateway-ebanx/pull/590)
* Feature - Plugin approved for wordpress 4.9 [#593](https://github.com/ebanx/woocommerce-gateway-ebanx/pull/593)
* Feature - Change minimum instalment value to 5 BRL for brazilian credit card payments [#595](https://github.com/ebanx/woocommerce-gateway-ebanx/pull/595)

# 1.22.0
* Feature - Explicit capture button [#578](https://github.com/ebanx/woocommerce-gateway-ebanx/pull/578)
* Feature - Added new Mexico payment method SPEI [#581](https://github.com/ebanx/woocommerce-gateway-ebanx/pull/581)
* Fix - Adjusted iFrame display for Argentina cash payment methods [#580](https://github.com/ebanx/woocommerce-gateway-ebanx/pull/580)
Expand Down
15 changes: 11 additions & 4 deletions assets/js/one-click.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,15 @@ jQuery(document).ready(function ($) {

var removeError = function (el) {
$(el).removeClass('is-invalid');
}
};

tooltip.keypress(function(e) {
if (e.keyCode === 13) {
e.preventDefault();
form.submit();
}
return true;
});

button.on('click', function (e) {
e.preventDefault();
Expand All @@ -28,10 +36,9 @@ jQuery(document).ready(function ($) {
tooltip.removeClass('is-active');
});

payButton.on('click', function () {
form.on('submit', function () {
payButton.text(payButton.attr('data-processing-label')).attr('disabled', 'disabled');

form.submit();
return true;
});

cvv.on('keyup', function () {
Expand Down
19 changes: 19 additions & 0 deletions phpunit.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
<?xml version="1.0" encoding="UTF-8"?>
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/6.1/phpunit.xsd"
beStrictAboutOutputDuringTests="true"
beStrictAboutTodoAnnotatedTests="true"
colors="true"
verbose="true"
>
<testsuite>
<directory prefix="test-" suffix=".php">./tests</directory>
</testsuite>

<logging>
<log type="coverage-clover" target="clover.xml"/>
<log type="coverage-html" target="./report" charset="UTF-8"
yui="true" highlight="true"
lowUpperBound="50" highLowerBound="80" />
</logging>
</phpunit>
10 changes: 8 additions & 2 deletions readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
Contributors: ebanxwp
Tags: credit card, boleto, ebanx, woocommerce, approval rate, conversion rate, brazil, mexico, argentina, peru, colombia, chile, oxxo, baloto, cash payment, local payment one-click payment, installments, alternative payments, accept more payments
Requires at least: 4.0
Tested up to: 4.7
Stable tag: 1.22.0
Tested up to: 4.9
Stable tag: 1.23.0
License: Apache v2.0
License URI: http://www.apache.org/licenses/LICENSE-2.0

Expand Down Expand Up @@ -138,6 +138,12 @@ Yes, you can.

== Changelog ==

= 1.23.0 =
* Feature - One click form can now be submitted using keyboard [#588](https://github.com/ebanx/woocommerce-gateway-ebanx/pull/588)
* Feature - Better payment origin identification on dashboard [#590](https://github.com/ebanx/woocommerce-gateway-ebanx/pull/590)
* Feature - Plugin approved for wordpress 4.9 [#593](https://github.com/ebanx/woocommerce-gateway-ebanx/pull/593)
* Feature - Change minimum instalment value to 5 BRL for brazilian credit card payments [#595](https://github.com/ebanx/woocommerce-gateway-ebanx/pull/595)

= 1.22.0 =
* Feature - Explicit capture button [#578](https://github.com/ebanx/woocommerce-gateway-ebanx/pull/578)
* Feature - Added new Mexico payment method SPEI [#581](https://github.com/ebanx/woocommerce-gateway-ebanx/pull/581)
Expand Down
2 changes: 1 addition & 1 deletion services/class-wc-ebanx-constants.php
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ abstract class WC_EBANX_Constants
* Minimal instalment value for acquirers to approve based on currency
*/
const ACQUIRER_MIN_INSTALMENT_VALUE_MXN = 100;
const ACQUIRER_MIN_INSTALMENT_VALUE_BRL = 20;
const ACQUIRER_MIN_INSTALMENT_VALUE_BRL = 5;
const ACQUIRER_MIN_INSTALMENT_VALUE_COP = 0;

/**
Expand Down
4 changes: 3 additions & 1 deletion services/class-wc-ebanx-payment-by-link.php
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,9 @@ private static function send_request() {
'payment_type_code' => empty(self::$order->payment_method) ? '_all' : WC_EBANX_Constants::$GATEWAY_TO_PAYMENT_TYPE_CODE[self::$order->payment_method],
'merchant_payment_code' => substr(self::$order->id . '_' . md5(time()), 0, 40),
'currency_code' => strtoupper(get_woocommerce_currency()),
'amount' => self::$order->get_total()
'amount' => self::$order->get_total(),
'user_value_1' => 'from_woocommerce',
'user_value_3' => 'version=' . WC_EBANX::get_plugin_version(),
);

\Ebanx\Config::set(self::$config);
Expand Down
2 changes: 1 addition & 1 deletion woocommerce-gateway-ebanx.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
* Description: Offer Latin American local payment methods & increase your conversion rates with the solution used by AliExpress, AirBnB and Spotify in Brazil.
* Author: EBANX
* Author URI: https://www.ebanx.com/business/en
* Version: 1.22.0
* Version: 1.23.0
* License: MIT
* Text Domain: woocommerce-gateway-ebanx
* Domain Path: /languages
Expand Down

0 comments on commit 24d2f0a

Please sign in to comment.