Version Description
19-02-2019 =
New - Enable 'refunds' for Klarna and SEPA Direct Debit payments
New - Support refunds per order line for payments via the Orders API (used to be only amount refunds)
New - Updated "Tested up to" to WordPress 5.1
New - Automatically updating Mollie Orders from WooCommerce to "Ship and Capture" and "Cancel" now supports all payments via Orders API, not just Klarna payments
New - Add support for refunding full Mollie Orders when refunding the full WooCommerce order (Orders API)
New - Update order lines processing to use Order instead of Cart data (for Orders API and Klarna)
New - Orders API/Klarna: also send WooCommerce order item id to Mollie as metadata, to allow for individual order line refunding
New - Pro-actively check for required PHP JSON extension
New - Added filter so merchants can manipulate the payment object metadata, default filter id mollie-payments-for-woocommerce_payment_object_metadata, also see https://www.mollie/WooCommerce/wiki/Helpful-snippets#add-custom-information-to-mollie-payment-object-metadata
New - Add billing country to payment methods cache in checkout, for when customers change their country in checkout
New - Allow developers to hook into the subscription renewal payment before it's processed with mollie-payments-for-woocommerce_before_renewal_payment_created
New - Set Payment screen language setting to wp_locale by default
Fix - Temporary fix for PHP 7.3 with sporadic caching issues of methods, better fix is now being tested
Fix - Check if WooCommerce Subscriptions Failed Recurring Payment Retry System is in-use, if it is, don't update subscription status
Fix - Polylang: another fix for edge-case with URL parameter, please test and provide feedback is you use Polylang!
Fix - Too many customers redirected to "Pay now" after payment, add isAuthorized to status check in getReturnRedirectUrlForOrder()
Fix - Add extra warning to order note for orders that are completed at Mollie (not WooCommerce)
Fix - Improve onWebhookFailed for WooCommerce Subscriptions so failed payments at Mollie are failed orders at WooCommerce
Release Info
Developer | davdebcom |
Plugin | Mollie Payments for WooCommerce |
Version | 5.1.0 |
Comparing to | |
See all releases |
Code changes from version 5.0.7 to 5.1.0
- includes/mollie-api-php/README.md +5 -2
- includes/mollie-api-php/composer.lock +97 -35
- includes/mollie-api-php/examples/orders/webhook.php +7 -7
- includes/mollie-api-php/src/Endpoints/ChargebackEndpoint.php +50 -0
- includes/mollie-api-php/src/Endpoints/OrganizationEndpoint.php +0 -15
- includes/mollie-api-php/src/MollieApiClient.php +11 -2
- includes/mollie-api-php/src/Resources/CursorCollection.php +24 -2
- includes/mollie-api-php/src/Resources/Order.php +12 -9
- includes/mollie-api-php/src/Resources/OrderLine.php +2 -1
- includes/mollie-api-php/src/Resources/Payment.php +1 -1
- includes/mollie-api-php/src/Resources/Settlement.php +8 -0
- includes/mollie-api-php/src/Types/OrderLineStatus.php +2 -1
- includes/mollie-api-php/src/Types/OrderStatus.php +11 -5
- includes/mollie-api-php/src/Types/PaymentMethod.php +95 -92
- includes/mollie-api-php/vendor/autoload.php +1 -1
- includes/mollie-api-php/vendor/composer/autoload_real.php +7 -7
- includes/mollie-api-php/vendor/composer/autoload_static.php +3 -3
- includes/mollie-api-php/vendor/composer/ca-bundle/res/cacert.pem +185 -24
- includes/mollie-api-php/vendor/composer/installed.json +12 -12
- includes/mollie-api-php/vendor/guzzlehttp/psr7/CHANGELOG.md +17 -1
- includes/mollie-api-php/vendor/guzzlehttp/psr7/src/functions.php +6 -1
- includes/mollie/wc/gateway/abstract.php +60 -24
- includes/mollie/wc/gateway/abstractsubscription.php +10 -0
- includes/mollie/wc/gateway/directdebit.php +6 -0
- includes/mollie/wc/gateway/klarnapaylater.php +1 -1
- includes/mollie/wc/gateway/klarnasliceit.php +1 -1
- includes/mollie/wc/gateway/sofort.php +1 -1
- includes/mollie/wc/helper/data.php +5 -0
- includes/mollie/wc/helper/orderlines.php +61 -87
- includes/mollie/wc/helper/settings.php +1 -1
- includes/mollie/wc/helper/status.php +7 -0
- includes/mollie/wc/payment/object.php +7 -6
- includes/mollie/wc/payment/order.php +319 -37
- includes/mollie/wc/payment/payment.php +69 -28
- includes/mollie/wc/plugin.php +19 -23
- mollie-payments-for-woocommerce.php +32 -2
- readme.txt +25 -3
@@ -1,6 +1,9 @@
|
|
1 |
-
|
|
|
|
|
|
|
2 |
|
3 |
-
|
4 |
|
5 |
Accepting [iDEAL](https://www.mollie.com/en/payments/ideal/), [Bancontact](https://www.mollie.com/en/payments/bancontact/), [SOFORT Banking](https://www.mollie.com/en/payments/sofort/), [Creditcard](https://www.mollie.com/en/payments/credit-card/), [SEPA Bank transfer](https://www.mollie.com/en/payments/bank-transfer/), [SEPA Direct debit](https://www.mollie.com/en/payments/direct-debit/), [Bitcoin](https://www.mollie.com/en/payments/bitcoin/), [PayPal](https://www.mollie.com/en/payments/paypal/), [Belfius Direct Net](https://www.mollie.com/en/payments/belfius/), [KBC/CBC](https://www.mollie.com/en/payments/kbc-cbc/), [paysafecard](https://www.mollie.com/en/payments/paysafecard/), [ING Home'Pay](https://www.mollie.com/en/payments/ing-homepay/), [Giftcards](https://www.mollie.com/en/payments/gift-cards/), [Giropay](https://www.mollie.com/en/payments/giropay/) and [EPS](https://www.mollie.com/en/payments/eps/) online payments without fixed monthly costs or any punishing registration procedures. Just use the Mollie API to receive payments directly on your website or easily refund transactions to your customers.
|
6 |
|
1 |
+
<p align="center">
|
2 |
+
<img src="https://info.mollie.com/hubfs/github/php/logo.png" width="128" height="128"/>
|
3 |
+
</p>
|
4 |
+
<h1 align="center">Mollie API client for PHP</h1>
|
5 |
|
6 |
+
<img src="https://info.mollie.com/hubfs/github/php/editor.png" />
|
7 |
|
8 |
Accepting [iDEAL](https://www.mollie.com/en/payments/ideal/), [Bancontact](https://www.mollie.com/en/payments/bancontact/), [SOFORT Banking](https://www.mollie.com/en/payments/sofort/), [Creditcard](https://www.mollie.com/en/payments/credit-card/), [SEPA Bank transfer](https://www.mollie.com/en/payments/bank-transfer/), [SEPA Direct debit](https://www.mollie.com/en/payments/direct-debit/), [Bitcoin](https://www.mollie.com/en/payments/bitcoin/), [PayPal](https://www.mollie.com/en/payments/paypal/), [Belfius Direct Net](https://www.mollie.com/en/payments/belfius/), [KBC/CBC](https://www.mollie.com/en/payments/kbc-cbc/), [paysafecard](https://www.mollie.com/en/payments/paysafecard/), [ING Home'Pay](https://www.mollie.com/en/payments/ing-homepay/), [Giftcards](https://www.mollie.com/en/payments/gift-cards/), [Giropay](https://www.mollie.com/en/payments/giropay/) and [EPS](https://www.mollie.com/en/payments/eps/) online payments without fixed monthly costs or any punishing registration procedures. Just use the Mollie API to receive payments directly on your website or easily refund transactions to your customers.
|
9 |
|
@@ -8,16 +8,16 @@
|
|
8 |
"packages": [
|
9 |
{
|
10 |
"name": "composer/ca-bundle",
|
11 |
-
"version": "1.1.
|
12 |
"source": {
|
13 |
"type": "git",
|
14 |
"url": "https://github.com/composer/ca-bundle.git",
|
15 |
-
"reference": "
|
16 |
},
|
17 |
"dist": {
|
18 |
"type": "zip",
|
19 |
-
"url": "https://api.github.com/repos/composer/ca-bundle/zipball/
|
20 |
-
"reference": "
|
21 |
"shasum": ""
|
22 |
},
|
23 |
"require": {
|
@@ -60,7 +60,7 @@
|
|
60 |
"ssl",
|
61 |
"tls"
|
62 |
],
|
63 |
-
"time": "
|
64 |
},
|
65 |
{
|
66 |
"name": "guzzlehttp/guzzle",
|
@@ -180,16 +180,16 @@
|
|
180 |
},
|
181 |
{
|
182 |
"name": "guzzlehttp/psr7",
|
183 |
-
"version": "1.5.
|
184 |
"source": {
|
185 |
"type": "git",
|
186 |
"url": "https://github.com/guzzle/psr7.git",
|
187 |
-
"reference": "
|
188 |
},
|
189 |
"dist": {
|
190 |
"type": "zip",
|
191 |
-
"url": "https://api.github.com/repos/guzzle/psr7/zipball/
|
192 |
-
"reference": "
|
193 |
"shasum": ""
|
194 |
},
|
195 |
"require": {
|
@@ -243,7 +243,7 @@
|
|
243 |
"uri",
|
244 |
"url"
|
245 |
],
|
246 |
-
"time": "2018-12-
|
247 |
},
|
248 |
{
|
249 |
"name": "psr/http-message",
|
@@ -1108,16 +1108,16 @@
|
|
1108 |
},
|
1109 |
{
|
1110 |
"name": "phpunit/phpunit",
|
1111 |
-
"version": "7.
|
1112 |
"source": {
|
1113 |
"type": "git",
|
1114 |
"url": "https://github.com/sebastianbergmann/phpunit.git",
|
1115 |
-
"reference": "
|
1116 |
},
|
1117 |
"dist": {
|
1118 |
"type": "zip",
|
1119 |
-
"url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/
|
1120 |
-
"reference": "
|
1121 |
"shasum": ""
|
1122 |
},
|
1123 |
"require": {
|
@@ -1162,7 +1162,7 @@
|
|
1162 |
"type": "library",
|
1163 |
"extra": {
|
1164 |
"branch-alias": {
|
1165 |
-
"dev-master": "7.
|
1166 |
}
|
1167 |
},
|
1168 |
"autoload": {
|
@@ -1188,7 +1188,7 @@
|
|
1188 |
"testing",
|
1189 |
"xunit"
|
1190 |
],
|
1191 |
-
"time": "
|
1192 |
},
|
1193 |
{
|
1194 |
"name": "sebastian/code-unit-reverse-lookup",
|
@@ -1301,23 +1301,23 @@
|
|
1301 |
},
|
1302 |
{
|
1303 |
"name": "sebastian/diff",
|
1304 |
-
"version": "3.0.
|
1305 |
"source": {
|
1306 |
"type": "git",
|
1307 |
"url": "https://github.com/sebastianbergmann/diff.git",
|
1308 |
-
"reference": "
|
1309 |
},
|
1310 |
"dist": {
|
1311 |
"type": "zip",
|
1312 |
-
"url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/
|
1313 |
-
"reference": "
|
1314 |
"shasum": ""
|
1315 |
},
|
1316 |
"require": {
|
1317 |
"php": "^7.1"
|
1318 |
},
|
1319 |
"require-dev": {
|
1320 |
-
"phpunit/phpunit": "^7.0",
|
1321 |
"symfony/process": "^2 || ^3.3 || ^4"
|
1322 |
},
|
1323 |
"type": "library",
|
@@ -1353,32 +1353,35 @@
|
|
1353 |
"unidiff",
|
1354 |
"unified diff"
|
1355 |
],
|
1356 |
-
"time": "
|
1357 |
},
|
1358 |
{
|
1359 |
"name": "sebastian/environment",
|
1360 |
-
"version": "4.0
|
1361 |
"source": {
|
1362 |
"type": "git",
|
1363 |
"url": "https://github.com/sebastianbergmann/environment.git",
|
1364 |
-
"reference": "
|
1365 |
},
|
1366 |
"dist": {
|
1367 |
"type": "zip",
|
1368 |
-
"url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/
|
1369 |
-
"reference": "
|
1370 |
"shasum": ""
|
1371 |
},
|
1372 |
"require": {
|
1373 |
"php": "^7.1"
|
1374 |
},
|
1375 |
"require-dev": {
|
1376 |
-
"phpunit/phpunit": "^7.
|
|
|
|
|
|
|
1377 |
},
|
1378 |
"type": "library",
|
1379 |
"extra": {
|
1380 |
"branch-alias": {
|
1381 |
-
"dev-master": "4.
|
1382 |
}
|
1383 |
},
|
1384 |
"autoload": {
|
@@ -1403,7 +1406,7 @@
|
|
1403 |
"environment",
|
1404 |
"hhvm"
|
1405 |
],
|
1406 |
-
"time": "
|
1407 |
},
|
1408 |
{
|
1409 |
"name": "sebastian/exporter",
|
@@ -1753,6 +1756,64 @@
|
|
1753 |
"homepage": "https://github.com/sebastianbergmann/version",
|
1754 |
"time": "2016-10-03T07:35:21+00:00"
|
1755 |
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1756 |
{
|
1757 |
"name": "theseer/tokenizer",
|
1758 |
"version": "1.1.0",
|
@@ -1795,20 +1856,21 @@
|
|
1795 |
},
|
1796 |
{
|
1797 |
"name": "webmozart/assert",
|
1798 |
-
"version": "1.
|
1799 |
"source": {
|
1800 |
"type": "git",
|
1801 |
"url": "https://github.com/webmozart/assert.git",
|
1802 |
-
"reference": "
|
1803 |
},
|
1804 |
"dist": {
|
1805 |
"type": "zip",
|
1806 |
-
"url": "https://api.github.com/repos/webmozart/assert/zipball/
|
1807 |
-
"reference": "
|
1808 |
"shasum": ""
|
1809 |
},
|
1810 |
"require": {
|
1811 |
-
"php": "^5.3.3 || ^7.0"
|
|
|
1812 |
},
|
1813 |
"require-dev": {
|
1814 |
"phpunit/phpunit": "^4.6",
|
@@ -1841,7 +1903,7 @@
|
|
1841 |
"check",
|
1842 |
"validate"
|
1843 |
],
|
1844 |
-
"time": "2018-
|
1845 |
}
|
1846 |
],
|
1847 |
"aliases": [],
|
8 |
"packages": [
|
9 |
{
|
10 |
"name": "composer/ca-bundle",
|
11 |
+
"version": "1.1.4",
|
12 |
"source": {
|
13 |
"type": "git",
|
14 |
"url": "https://github.com/composer/ca-bundle.git",
|
15 |
+
"reference": "558f321c52faeb4828c03e7dc0cfe39a09e09a2d"
|
16 |
},
|
17 |
"dist": {
|
18 |
"type": "zip",
|
19 |
+
"url": "https://api.github.com/repos/composer/ca-bundle/zipball/558f321c52faeb4828c03e7dc0cfe39a09e09a2d",
|
20 |
+
"reference": "558f321c52faeb4828c03e7dc0cfe39a09e09a2d",
|
21 |
"shasum": ""
|
22 |
},
|
23 |
"require": {
|
60 |
"ssl",
|
61 |
"tls"
|
62 |
],
|
63 |
+
"time": "2019-01-28T09:30:10+00:00"
|
64 |
},
|
65 |
{
|
66 |
"name": "guzzlehttp/guzzle",
|
180 |
},
|
181 |
{
|
182 |
"name": "guzzlehttp/psr7",
|
183 |
+
"version": "1.5.2",
|
184 |
"source": {
|
185 |
"type": "git",
|
186 |
"url": "https://github.com/guzzle/psr7.git",
|
187 |
+
"reference": "9f83dded91781a01c63574e387eaa769be769115"
|
188 |
},
|
189 |
"dist": {
|
190 |
"type": "zip",
|
191 |
+
"url": "https://api.github.com/repos/guzzle/psr7/zipball/9f83dded91781a01c63574e387eaa769be769115",
|
192 |
+
"reference": "9f83dded91781a01c63574e387eaa769be769115",
|
193 |
"shasum": ""
|
194 |
},
|
195 |
"require": {
|
243 |
"uri",
|
244 |
"url"
|
245 |
],
|
246 |
+
"time": "2018-12-04T20:46:45+00:00"
|
247 |
},
|
248 |
{
|
249 |
"name": "psr/http-message",
|
1108 |
},
|
1109 |
{
|
1110 |
"name": "phpunit/phpunit",
|
1111 |
+
"version": "7.5.6",
|
1112 |
"source": {
|
1113 |
"type": "git",
|
1114 |
"url": "https://github.com/sebastianbergmann/phpunit.git",
|
1115 |
+
"reference": "09c85e14994df92e5ff1f5ec0b481bdb7d3d3df9"
|
1116 |
},
|
1117 |
"dist": {
|
1118 |
"type": "zip",
|
1119 |
+
"url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/09c85e14994df92e5ff1f5ec0b481bdb7d3d3df9",
|
1120 |
+
"reference": "09c85e14994df92e5ff1f5ec0b481bdb7d3d3df9",
|
1121 |
"shasum": ""
|
1122 |
},
|
1123 |
"require": {
|
1162 |
"type": "library",
|
1163 |
"extra": {
|
1164 |
"branch-alias": {
|
1165 |
+
"dev-master": "7.5-dev"
|
1166 |
}
|
1167 |
},
|
1168 |
"autoload": {
|
1188 |
"testing",
|
1189 |
"xunit"
|
1190 |
],
|
1191 |
+
"time": "2019-02-18T09:24:50+00:00"
|
1192 |
},
|
1193 |
{
|
1194 |
"name": "sebastian/code-unit-reverse-lookup",
|
1301 |
},
|
1302 |
{
|
1303 |
"name": "sebastian/diff",
|
1304 |
+
"version": "3.0.2",
|
1305 |
"source": {
|
1306 |
"type": "git",
|
1307 |
"url": "https://github.com/sebastianbergmann/diff.git",
|
1308 |
+
"reference": "720fcc7e9b5cf384ea68d9d930d480907a0c1a29"
|
1309 |
},
|
1310 |
"dist": {
|
1311 |
"type": "zip",
|
1312 |
+
"url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/720fcc7e9b5cf384ea68d9d930d480907a0c1a29",
|
1313 |
+
"reference": "720fcc7e9b5cf384ea68d9d930d480907a0c1a29",
|
1314 |
"shasum": ""
|
1315 |
},
|
1316 |
"require": {
|
1317 |
"php": "^7.1"
|
1318 |
},
|
1319 |
"require-dev": {
|
1320 |
+
"phpunit/phpunit": "^7.5 || ^8.0",
|
1321 |
"symfony/process": "^2 || ^3.3 || ^4"
|
1322 |
},
|
1323 |
"type": "library",
|
1353 |
"unidiff",
|
1354 |
"unified diff"
|
1355 |
],
|
1356 |
+
"time": "2019-02-04T06:01:07+00:00"
|
1357 |
},
|
1358 |
{
|
1359 |
"name": "sebastian/environment",
|
1360 |
+
"version": "4.1.0",
|
1361 |
"source": {
|
1362 |
"type": "git",
|
1363 |
"url": "https://github.com/sebastianbergmann/environment.git",
|
1364 |
+
"reference": "6fda8ce1974b62b14935adc02a9ed38252eca656"
|
1365 |
},
|
1366 |
"dist": {
|
1367 |
"type": "zip",
|
1368 |
+
"url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/6fda8ce1974b62b14935adc02a9ed38252eca656",
|
1369 |
+
"reference": "6fda8ce1974b62b14935adc02a9ed38252eca656",
|
1370 |
"shasum": ""
|
1371 |
},
|
1372 |
"require": {
|
1373 |
"php": "^7.1"
|
1374 |
},
|
1375 |
"require-dev": {
|
1376 |
+
"phpunit/phpunit": "^7.5"
|
1377 |
+
},
|
1378 |
+
"suggest": {
|
1379 |
+
"ext-posix": "*"
|
1380 |
},
|
1381 |
"type": "library",
|
1382 |
"extra": {
|
1383 |
"branch-alias": {
|
1384 |
+
"dev-master": "4.1-dev"
|
1385 |
}
|
1386 |
},
|
1387 |
"autoload": {
|
1406 |
"environment",
|
1407 |
"hhvm"
|
1408 |
],
|
1409 |
+
"time": "2019-02-01T05:27:49+00:00"
|
1410 |
},
|
1411 |
{
|
1412 |
"name": "sebastian/exporter",
|
1756 |
"homepage": "https://github.com/sebastianbergmann/version",
|
1757 |
"time": "2016-10-03T07:35:21+00:00"
|
1758 |
},
|
1759 |
+
{
|
1760 |
+
"name": "symfony/polyfill-ctype",
|
1761 |
+
"version": "v1.10.0",
|
1762 |
+
"source": {
|
1763 |
+
"type": "git",
|
1764 |
+
"url": "https://github.com/symfony/polyfill-ctype.git",
|
1765 |
+
"reference": "e3d826245268269cd66f8326bd8bc066687b4a19"
|
1766 |
+
},
|
1767 |
+
"dist": {
|
1768 |
+
"type": "zip",
|
1769 |
+
"url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/e3d826245268269cd66f8326bd8bc066687b4a19",
|
1770 |
+
"reference": "e3d826245268269cd66f8326bd8bc066687b4a19",
|
1771 |
+
"shasum": ""
|
1772 |
+
},
|
1773 |
+
"require": {
|
1774 |
+
"php": ">=5.3.3"
|
1775 |
+
},
|
1776 |
+
"suggest": {
|
1777 |
+
"ext-ctype": "For best performance"
|
1778 |
+
},
|
1779 |
+
"type": "library",
|
1780 |
+
"extra": {
|
1781 |
+
"branch-alias": {
|
1782 |
+
"dev-master": "1.9-dev"
|
1783 |
+
}
|
1784 |
+
},
|
1785 |
+
"autoload": {
|
1786 |
+
"psr-4": {
|
1787 |
+
"Symfony\\Polyfill\\Ctype\\": ""
|
1788 |
+
},
|
1789 |
+
"files": [
|
1790 |
+
"bootstrap.php"
|
1791 |
+
]
|
1792 |
+
},
|
1793 |
+
"notification-url": "https://packagist.org/downloads/",
|
1794 |
+
"license": [
|
1795 |
+
"MIT"
|
1796 |
+
],
|
1797 |
+
"authors": [
|
1798 |
+
{
|
1799 |
+
"name": "Symfony Community",
|
1800 |
+
"homepage": "https://symfony.com/contributors"
|
1801 |
+
},
|
1802 |
+
{
|
1803 |
+
"name": "Gert de Pagter",
|
1804 |
+
"email": "BackEndTea@gmail.com"
|
1805 |
+
}
|
1806 |
+
],
|
1807 |
+
"description": "Symfony polyfill for ctype functions",
|
1808 |
+
"homepage": "https://symfony.com",
|
1809 |
+
"keywords": [
|
1810 |
+
"compatibility",
|
1811 |
+
"ctype",
|
1812 |
+
"polyfill",
|
1813 |
+
"portable"
|
1814 |
+
],
|
1815 |
+
"time": "2018-08-06T14:22:27+00:00"
|
1816 |
+
},
|
1817 |
{
|
1818 |
"name": "theseer/tokenizer",
|
1819 |
"version": "1.1.0",
|
1856 |
},
|
1857 |
{
|
1858 |
"name": "webmozart/assert",
|
1859 |
+
"version": "1.4.0",
|
1860 |
"source": {
|
1861 |
"type": "git",
|
1862 |
"url": "https://github.com/webmozart/assert.git",
|
1863 |
+
"reference": "83e253c8e0be5b0257b881e1827274667c5c17a9"
|
1864 |
},
|
1865 |
"dist": {
|
1866 |
"type": "zip",
|
1867 |
+
"url": "https://api.github.com/repos/webmozart/assert/zipball/83e253c8e0be5b0257b881e1827274667c5c17a9",
|
1868 |
+
"reference": "83e253c8e0be5b0257b881e1827274667c5c17a9",
|
1869 |
"shasum": ""
|
1870 |
},
|
1871 |
"require": {
|
1872 |
+
"php": "^5.3.3 || ^7.0",
|
1873 |
+
"symfony/polyfill-ctype": "^1.8"
|
1874 |
},
|
1875 |
"require-dev": {
|
1876 |
"phpunit/phpunit": "^4.6",
|
1903 |
"check",
|
1904 |
"validate"
|
1905 |
],
|
1906 |
+
"time": "2018-12-25T11:19:39+00:00"
|
1907 |
}
|
1908 |
],
|
1909 |
"aliases": [],
|
@@ -16,12 +16,12 @@ try {
|
|
16 |
* See: https://docs.mollie.com/reference/v2/orders-api/get-order
|
17 |
*/
|
18 |
$order = $mollie->orders->get($_POST["id"]);
|
19 |
-
$orderId = $
|
20 |
|
21 |
/*
|
22 |
* Update the order in the database.
|
23 |
*/
|
24 |
-
database_write($orderId, $
|
25 |
|
26 |
if ($order->isPaid() || $order->isAuthorized()) {
|
27 |
/*
|
@@ -32,17 +32,17 @@ try {
|
|
32 |
/*
|
33 |
* The order is canceled.
|
34 |
*/
|
35 |
-
} elseif ($order->isRefunded()) {
|
36 |
-
/*
|
37 |
-
* The order is refunded.
|
38 |
-
*/
|
39 |
} elseif ($order->isExpired()) {
|
40 |
/*
|
41 |
* The order is expired.
|
42 |
*/
|
43 |
} elseif ($order->isCompleted()) {
|
44 |
/*
|
45 |
-
* The
|
|
|
|
|
|
|
|
|
46 |
*/
|
47 |
}
|
48 |
} catch (\Mollie\Api\Exceptions\ApiException $e) {
|
16 |
* See: https://docs.mollie.com/reference/v2/orders-api/get-order
|
17 |
*/
|
18 |
$order = $mollie->orders->get($_POST["id"]);
|
19 |
+
$orderId = $order->metadata->order_id;
|
20 |
|
21 |
/*
|
22 |
* Update the order in the database.
|
23 |
*/
|
24 |
+
database_write($orderId, $order->status);
|
25 |
|
26 |
if ($order->isPaid() || $order->isAuthorized()) {
|
27 |
/*
|
32 |
/*
|
33 |
* The order is canceled.
|
34 |
*/
|
|
|
|
|
|
|
|
|
35 |
} elseif ($order->isExpired()) {
|
36 |
/*
|
37 |
* The order is expired.
|
38 |
*/
|
39 |
} elseif ($order->isCompleted()) {
|
40 |
/*
|
41 |
+
* The order is completed.
|
42 |
+
*/
|
43 |
+
} elseif ($order->isPending()) {
|
44 |
+
/*
|
45 |
+
* The order is pending.
|
46 |
*/
|
47 |
}
|
48 |
} catch (\Mollie\Api\Exceptions\ApiException $e) {
|
@@ -0,0 +1,50 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
namespace Mollie\Api\Endpoints;
|
4 |
+
|
5 |
+
use Mollie\Api\Exceptions\ApiException;
|
6 |
+
use Mollie\Api\Resources\Chargeback;
|
7 |
+
use Mollie\Api\Resources\ChargebackCollection;
|
8 |
+
|
9 |
+
class ChargebackEndpoint extends EndpointAbstract
|
10 |
+
{
|
11 |
+
protected $resourcePath = "chargebacks";
|
12 |
+
|
13 |
+
/**
|
14 |
+
* Get the object that is used by this API endpoint. Every API endpoint uses one type of object.
|
15 |
+
*
|
16 |
+
* @return Chargeback
|
17 |
+
*/
|
18 |
+
protected function getResourceObject()
|
19 |
+
{
|
20 |
+
return new Chargeback($this->client);
|
21 |
+
}
|
22 |
+
|
23 |
+
/**
|
24 |
+
* Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object.
|
25 |
+
*
|
26 |
+
* @param int $count
|
27 |
+
* @param object[] $_links
|
28 |
+
*
|
29 |
+
* @return ChargebackCollection
|
30 |
+
*/
|
31 |
+
protected function getResourceCollectionObject($count, $_links)
|
32 |
+
{
|
33 |
+
return new ChargebackCollection($this->client, $count, $_links);
|
34 |
+
}
|
35 |
+
|
36 |
+
/**
|
37 |
+
* Retrieves a collection of Chargebacks from Mollie.
|
38 |
+
*
|
39 |
+
* @param string $from The first chargeback ID you want to include in your list.
|
40 |
+
* @param int $limit
|
41 |
+
* @param array $parameters
|
42 |
+
*
|
43 |
+
* @return ChargebackCollection
|
44 |
+
* @throws ApiException
|
45 |
+
*/
|
46 |
+
public function page($from = null, $limit = null, array $parameters = [])
|
47 |
+
{
|
48 |
+
return $this->rest_list($from, $limit, $parameters);
|
49 |
+
}
|
50 |
+
}
|
@@ -62,19 +62,4 @@ class OrganizationEndpoint extends EndpointAbstract
|
|
62 |
{
|
63 |
return parent::rest_read('me', $parameters);
|
64 |
}
|
65 |
-
|
66 |
-
/**
|
67 |
-
* Retrieves a collection of Organizations from Mollie.
|
68 |
-
*
|
69 |
-
* @param string $from The first organization ID you want to include in your list.
|
70 |
-
* @param int $limit
|
71 |
-
* @param array $parameters
|
72 |
-
*
|
73 |
-
* @return OrganizationCollection
|
74 |
-
* @throws ApiException
|
75 |
-
*/
|
76 |
-
public function page($from = null, $limit = null, array $parameters = [])
|
77 |
-
{
|
78 |
-
return $this->rest_list($from, $limit, $parameters);
|
79 |
-
}
|
80 |
}
|
62 |
{
|
63 |
return parent::rest_read('me', $parameters);
|
64 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
65 |
}
|
@@ -6,6 +6,7 @@ use GuzzleHttp\Client;
|
|
6 |
use GuzzleHttp\ClientInterface;
|
7 |
use GuzzleHttp\Exception\GuzzleException;
|
8 |
use GuzzleHttp\Psr7\Request;
|
|
|
9 |
use Mollie\Api\Endpoints\CustomerEndpoint;
|
10 |
use Mollie\Api\Endpoints\CustomerPaymentsEndpoint;
|
11 |
use Mollie\Api\Endpoints\InvoiceEndpoint;
|
@@ -35,7 +36,7 @@ class MollieApiClient
|
|
35 |
/**
|
36 |
* Version of our client.
|
37 |
*/
|
38 |
-
const CLIENT_VERSION = "2.1.
|
39 |
|
40 |
/**
|
41 |
* Endpoint of the remote API.
|
@@ -189,7 +190,14 @@ class MollieApiClient
|
|
189 |
* @var PaymentCaptureEndpoint
|
190 |
*/
|
191 |
public $paymentCaptures;
|
192 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
193 |
/**
|
194 |
* RESTful Payment Chargebacks resource.
|
195 |
*
|
@@ -270,6 +278,7 @@ class MollieApiClient
|
|
270 |
$this->refunds = new RefundEndpoint($this);
|
271 |
$this->paymentRefunds = new PaymentRefundEndpoint($this);
|
272 |
$this->paymentCaptures = new PaymentCaptureEndpoint($this);
|
|
|
273 |
$this->paymentChargebacks = new PaymentChargebackEndpoint($this);
|
274 |
}
|
275 |
|
6 |
use GuzzleHttp\ClientInterface;
|
7 |
use GuzzleHttp\Exception\GuzzleException;
|
8 |
use GuzzleHttp\Psr7\Request;
|
9 |
+
use Mollie\Api\Endpoints\ChargebackEndpoint;
|
10 |
use Mollie\Api\Endpoints\CustomerEndpoint;
|
11 |
use Mollie\Api\Endpoints\CustomerPaymentsEndpoint;
|
12 |
use Mollie\Api\Endpoints\InvoiceEndpoint;
|
36 |
/**
|
37 |
* Version of our client.
|
38 |
*/
|
39 |
+
const CLIENT_VERSION = "2.1.5";
|
40 |
|
41 |
/**
|
42 |
* Endpoint of the remote API.
|
190 |
* @var PaymentCaptureEndpoint
|
191 |
*/
|
192 |
public $paymentCaptures;
|
193 |
+
|
194 |
+
/**
|
195 |
+
* RESTful Chargebacks resource.
|
196 |
+
*
|
197 |
+
* @var ChargebacksEndpoint
|
198 |
+
*/
|
199 |
+
public $chargebacks;
|
200 |
+
|
201 |
/**
|
202 |
* RESTful Payment Chargebacks resource.
|
203 |
*
|
278 |
$this->refunds = new RefundEndpoint($this);
|
279 |
$this->paymentRefunds = new PaymentRefundEndpoint($this);
|
280 |
$this->paymentCaptures = new PaymentCaptureEndpoint($this);
|
281 |
+
$this->chargebacks = new ChargebackEndpoint($this);
|
282 |
$this->paymentChargebacks = new PaymentChargebackEndpoint($this);
|
283 |
}
|
284 |
|
@@ -32,10 +32,11 @@ abstract class CursorCollection extends BaseCollection
|
|
32 |
* Return the next set of resources when available
|
33 |
*
|
34 |
* @return CursorCollection|null
|
|
|
35 |
*/
|
36 |
final public function next()
|
37 |
{
|
38 |
-
if (
|
39 |
return null;
|
40 |
}
|
41 |
|
@@ -54,10 +55,11 @@ abstract class CursorCollection extends BaseCollection
|
|
54 |
* Return the previous set of resources when available
|
55 |
*
|
56 |
* @return CursorCollection|null
|
|
|
57 |
*/
|
58 |
final public function previous()
|
59 |
{
|
60 |
-
if (!
|
61 |
return null;
|
62 |
}
|
63 |
|
@@ -71,4 +73,24 @@ abstract class CursorCollection extends BaseCollection
|
|
71 |
|
72 |
return $collection;
|
73 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
74 |
}
|
32 |
* Return the next set of resources when available
|
33 |
*
|
34 |
* @return CursorCollection|null
|
35 |
+
* @throws \Mollie\Api\Exceptions\ApiException
|
36 |
*/
|
37 |
final public function next()
|
38 |
{
|
39 |
+
if ($this->hasNext()) {
|
40 |
return null;
|
41 |
}
|
42 |
|
55 |
* Return the previous set of resources when available
|
56 |
*
|
57 |
* @return CursorCollection|null
|
58 |
+
* @throws \Mollie\Api\Exceptions\ApiException
|
59 |
*/
|
60 |
final public function previous()
|
61 |
{
|
62 |
+
if (! $this->hasPrevious()) {
|
63 |
return null;
|
64 |
}
|
65 |
|
73 |
|
74 |
return $collection;
|
75 |
}
|
76 |
+
|
77 |
+
/**
|
78 |
+
* Determine whether the collection has a next page available.
|
79 |
+
*
|
80 |
+
* @return bool
|
81 |
+
*/
|
82 |
+
public function hasNext()
|
83 |
+
{
|
84 |
+
return isset($this->_links->next->href);
|
85 |
+
}
|
86 |
+
|
87 |
+
/**
|
88 |
+
* Determine whether the collection has a previous page available.
|
89 |
+
*
|
90 |
+
* @return bool
|
91 |
+
*/
|
92 |
+
public function hasPrevious()
|
93 |
+
{
|
94 |
+
return isset($this->_links->previous->href);
|
95 |
+
}
|
96 |
}
|
@@ -158,14 +158,6 @@ class Order extends BaseResource
|
|
158 |
*/
|
159 |
public $_links;
|
160 |
|
161 |
-
/**
|
162 |
-
* An organization name which can be provided by the shopper, if they do shopping for business purposes of their
|
163 |
-
* company.
|
164 |
-
*
|
165 |
-
* @var string|null
|
166 |
-
*/
|
167 |
-
public $organizationName;
|
168 |
-
|
169 |
/**
|
170 |
* Is this order created?
|
171 |
*
|
@@ -207,7 +199,8 @@ class Order extends BaseResource
|
|
207 |
}
|
208 |
|
209 |
/**
|
210 |
-
* Is this order refunded?
|
|
|
211 |
*
|
212 |
* @return bool
|
213 |
*/
|
@@ -246,6 +239,16 @@ class Order extends BaseResource
|
|
246 |
return $this->status === OrderStatus::STATUS_EXPIRED;
|
247 |
}
|
248 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
249 |
|
250 |
/**
|
251 |
* Cancels this order.
|
158 |
*/
|
159 |
public $_links;
|
160 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
161 |
/**
|
162 |
* Is this order created?
|
163 |
*
|
199 |
}
|
200 |
|
201 |
/**
|
202 |
+
* (Deprecated) Is this order refunded?
|
203 |
+
* @deprecated 2018-11-27
|
204 |
*
|
205 |
* @return bool
|
206 |
*/
|
239 |
return $this->status === OrderStatus::STATUS_EXPIRED;
|
240 |
}
|
241 |
|
242 |
+
/**
|
243 |
+
* Is this order completed?
|
244 |
+
*
|
245 |
+
* @return bool
|
246 |
+
*/
|
247 |
+
public function isPending()
|
248 |
+
{
|
249 |
+
return $this->status === OrderStatus::STATUS_PENDING;
|
250 |
+
}
|
251 |
+
|
252 |
|
253 |
/**
|
254 |
* Cancels this order.
|
@@ -175,7 +175,8 @@ class OrderLine extends BaseResource
|
|
175 |
}
|
176 |
|
177 |
/**
|
178 |
-
* Is this order line refunded?
|
|
|
179 |
*
|
180 |
* @return bool
|
181 |
*/
|
175 |
}
|
176 |
|
177 |
/**
|
178 |
+
* (Deprecated) Is this order line refunded?
|
179 |
+
* @deprecated 2018-11-27
|
180 |
*
|
181 |
* @return bool
|
182 |
*/
|
@@ -496,7 +496,7 @@ class Payment extends BaseResource
|
|
496 |
public function chargebacks()
|
497 |
{
|
498 |
if (!isset($this->_links->chargebacks->href)) {
|
499 |
-
return new ChargebackCollection(
|
500 |
}
|
501 |
|
502 |
$result = $this->client->performHttpCallToFullUrl(
|
496 |
public function chargebacks()
|
497 |
{
|
498 |
if (!isset($this->_links->chargebacks->href)) {
|
499 |
+
return new ChargebackCollection(0, null);
|
500 |
}
|
501 |
|
502 |
$result = $this->client->performHttpCallToFullUrl(
|
@@ -35,6 +35,14 @@ class Settlement extends BaseResource
|
|
35 |
*/
|
36 |
public $createdAt;
|
37 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
38 |
/**
|
39 |
* Status of the settlement.
|
40 |
*
|
35 |
*/
|
36 |
public $createdAt;
|
37 |
|
38 |
+
/**
|
39 |
+
* The date on which the settlement was settled, in ISO 8601 format. When requesting the open settlement or next settlement the return value is null.
|
40 |
+
*
|
41 |
+
* @example "2013-12-25T10:30:54+00:00"
|
42 |
+
* @var string|null
|
43 |
+
*/
|
44 |
+
public $settledAt;
|
45 |
+
|
46 |
/**
|
47 |
* Status of the settlement.
|
48 |
*
|
@@ -25,7 +25,8 @@ class OrderLineStatus
|
|
25 |
const STATUS_CANCELED = "canceled";
|
26 |
|
27 |
/**
|
28 |
-
* The order line has been refunded.
|
|
|
29 |
*/
|
30 |
const STATUS_REFUNDED = "refunded";
|
31 |
|
25 |
const STATUS_CANCELED = "canceled";
|
26 |
|
27 |
/**
|
28 |
+
* (Deprecated) The order line has been refunded.
|
29 |
+
* @deprecated
|
30 |
*/
|
31 |
const STATUS_REFUNDED = "refunded";
|
32 |
|
@@ -24,11 +24,6 @@ class OrderStatus
|
|
24 |
*/
|
25 |
const STATUS_CANCELED = "canceled";
|
26 |
|
27 |
-
/**
|
28 |
-
* The order has been refunded.
|
29 |
-
*/
|
30 |
-
const STATUS_REFUNDED = "refunded";
|
31 |
-
|
32 |
/**
|
33 |
* The order is shipping.
|
34 |
*/
|
@@ -43,4 +38,15 @@ class OrderStatus
|
|
43 |
* The order is expired.
|
44 |
*/
|
45 |
const STATUS_EXPIRED = "expired";
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
46 |
}
|
24 |
*/
|
25 |
const STATUS_CANCELED = "canceled";
|
26 |
|
|
|
|
|
|
|
|
|
|
|
27 |
/**
|
28 |
* The order is shipping.
|
29 |
*/
|
38 |
* The order is expired.
|
39 |
*/
|
40 |
const STATUS_EXPIRED = "expired";
|
41 |
+
|
42 |
+
/**
|
43 |
+
* The order is pending.
|
44 |
+
*/
|
45 |
+
const STATUS_PENDING = "pending";
|
46 |
+
|
47 |
+
/**
|
48 |
+
* (Deprecated) The order has been refunded.
|
49 |
+
* @deprecated 2018-11-27
|
50 |
+
*/
|
51 |
+
const STATUS_REFUNDED = "refunded";
|
52 |
}
|
@@ -2,96 +2,99 @@
|
|
2 |
|
3 |
namespace Mollie\Api\Types;
|
4 |
|
5 |
-
class PaymentMethod
|
6 |
-
|
7 |
-
|
8 |
-
|
9 |
-
|
10 |
-
|
11 |
-
|
12 |
-
|
13 |
-
|
14 |
-
|
15 |
-
|
16 |
-
|
17 |
-
|
18 |
-
|
19 |
-
|
20 |
-
|
21 |
-
|
22 |
-
|
23 |
-
|
24 |
-
|
25 |
-
|
26 |
-
|
27 |
-
|
28 |
-
|
29 |
-
|
30 |
-
|
31 |
-
|
32 |
-
|
33 |
-
|
34 |
-
|
35 |
-
|
36 |
-
|
37 |
-
|
38 |
-
|
39 |
-
|
40 |
-
|
41 |
-
|
42 |
-
|
43 |
-
|
44 |
-
|
45 |
-
|
46 |
-
|
47 |
-
|
48 |
-
|
49 |
-
|
50 |
-
|
51 |
-
|
52 |
-
|
53 |
-
|
54 |
-
|
55 |
-
|
56 |
-
|
57 |
-
|
58 |
-
|
59 |
-
|
60 |
-
|
61 |
-
|
62 |
-
|
63 |
-
|
64 |
-
|
65 |
-
|
66 |
-
|
67 |
-
|
68 |
-
|
69 |
-
|
70 |
-
|
71 |
-
|
72 |
-
|
73 |
-
|
74 |
-
|
75 |
-
|
76 |
-
|
77 |
-
|
78 |
-
|
79 |
-
|
80 |
-
|
81 |
-
|
82 |
-
|
83 |
-
|
84 |
-
|
85 |
-
|
86 |
-
|
87 |
-
|
88 |
-
|
89 |
-
|
90 |
-
|
91 |
-
|
92 |
-
|
93 |
-
|
94 |
-
|
95 |
-
|
96 |
-
|
|
|
|
|
|
|
97 |
}
|
2 |
|
3 |
namespace Mollie\Api\Types;
|
4 |
|
5 |
+
class PaymentMethod {
|
6 |
+
/**
|
7 |
+
* @link https://www.mollie.com/en/payments/bancontact
|
8 |
+
*/
|
9 |
+
const BANCONTACT = "bancontact";
|
10 |
+
|
11 |
+
/**
|
12 |
+
* @link https://www.mollie.com/en/payments/bank-transfer
|
13 |
+
*/
|
14 |
+
const BANKTRANSFER = "banktransfer";
|
15 |
+
|
16 |
+
/**
|
17 |
+
* @link https://www.mollie.com/en/payments/belfius
|
18 |
+
*/
|
19 |
+
const BELFIUS = "belfius";
|
20 |
+
|
21 |
+
/**
|
22 |
+
* @link https://www.mollie.com/en/payments/bitcoin
|
23 |
+
*/
|
24 |
+
const BITCOIN = "bitcoin";
|
25 |
+
|
26 |
+
/**
|
27 |
+
* @link https://www.mollie.com/en/payments/credit-card
|
28 |
+
*/
|
29 |
+
const CREDITCARD = "creditcard";
|
30 |
+
|
31 |
+
/**
|
32 |
+
* @link https://www.mollie.com/en/payments/direct-debit
|
33 |
+
*/
|
34 |
+
const DIRECTDEBIT = "directdebit";
|
35 |
+
|
36 |
+
/**
|
37 |
+
* @link https://www.mollie.com/en/payments/eps
|
38 |
+
*/
|
39 |
+
const EPS = "eps";
|
40 |
+
|
41 |
+
/**
|
42 |
+
* @link https://www.mollie.com/en/payments/gift-cards
|
43 |
+
*/
|
44 |
+
const GIFTCARD = "giftcard";
|
45 |
+
|
46 |
+
/**
|
47 |
+
* @link https://www.mollie.com/en/payments/giropay
|
48 |
+
*/
|
49 |
+
const GIROPAY = "giropay";
|
50 |
+
|
51 |
+
/**
|
52 |
+
* @link https://www.mollie.com/en/payments/ideal
|
53 |
+
*/
|
54 |
+
const IDEAL = "ideal";
|
55 |
+
|
56 |
+
/**
|
57 |
+
* @link https://www.mollie.com/en/payments/ing-homepay
|
58 |
+
*/
|
59 |
+
const INGHOMEPAY = "inghomepay";
|
60 |
+
|
61 |
+
/**
|
62 |
+
* @link https://www.mollie.com/en/payments/kbc-cbc
|
63 |
+
*/
|
64 |
+
const KBC = "kbc";
|
65 |
+
|
66 |
+
/**
|
67 |
+
* @link https://www.mollie.com/en/payments/paypal
|
68 |
+
*/
|
69 |
+
const PAYPAL = "paypal";
|
70 |
+
|
71 |
+
/**
|
72 |
+
* @link https://www.mollie.com/en/payments/paysafecard
|
73 |
+
*/
|
74 |
+
const PAYSAFECARD = "paysafecard";
|
75 |
+
|
76 |
+
/**
|
77 |
+
* @deprecated
|
78 |
+
* @link https://www.mollie.com/en/payments/gift-cards
|
79 |
+
*/
|
80 |
+
const PODIUMCADEAUKAART = "podiumcadeaukaart";
|
81 |
+
|
82 |
+
/**
|
83 |
+
* @link https://www.mollie.com/en/payments/sofort
|
84 |
+
*/
|
85 |
+
const SOFORT = "sofort";
|
86 |
+
|
87 |
+
/**
|
88 |
+
* @link https://www.mollie.com/en/payments/klarna-pay-later
|
89 |
+
*/
|
90 |
+
const KLARNA_PAY_LATER = "klarnapaylater";
|
91 |
+
|
92 |
+
/**
|
93 |
+
* @link https://www.mollie.com/en/payments/klarna-slice-it
|
94 |
+
*/
|
95 |
+
const KLARNA_SLICE_IT = "klarnasliceit";
|
96 |
+
|
97 |
+
|
98 |
+
const PRZELEWY24 = "przelewy24";
|
99 |
+
|
100 |
}
|
@@ -4,4 +4,4 @@
|
|
4 |
|
5 |
require_once __DIR__ . '/composer/autoload_real.php';
|
6 |
|
7 |
-
return
|
4 |
|
5 |
require_once __DIR__ . '/composer/autoload_real.php';
|
6 |
|
7 |
+
return ComposerAutoloaderInitdeb3904dfced6b71023154877c51be97::getLoader();
|
@@ -2,7 +2,7 @@
|
|
2 |
|
3 |
// autoload_real.php @generated by Composer
|
4 |
|
5 |
-
class
|
6 |
{
|
7 |
private static $loader;
|
8 |
|
@@ -19,15 +19,15 @@ class ComposerAutoloaderInitff51838293b10d1f9ba6a6fd550fd5e8
|
|
19 |
return self::$loader;
|
20 |
}
|
21 |
|
22 |
-
spl_autoload_register(array('
|
23 |
self::$loader = $loader = new \Composer\Autoload\ClassLoader();
|
24 |
-
spl_autoload_unregister(array('
|
25 |
|
26 |
$useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded());
|
27 |
if ($useStaticLoader) {
|
28 |
require_once __DIR__ . '/autoload_static.php';
|
29 |
|
30 |
-
call_user_func(\Composer\Autoload\
|
31 |
} else {
|
32 |
$map = require __DIR__ . '/autoload_namespaces.php';
|
33 |
foreach ($map as $namespace => $path) {
|
@@ -48,19 +48,19 @@ class ComposerAutoloaderInitff51838293b10d1f9ba6a6fd550fd5e8
|
|
48 |
$loader->register(true);
|
49 |
|
50 |
if ($useStaticLoader) {
|
51 |
-
$includeFiles = Composer\Autoload\
|
52 |
} else {
|
53 |
$includeFiles = require __DIR__ . '/autoload_files.php';
|
54 |
}
|
55 |
foreach ($includeFiles as $fileIdentifier => $file) {
|
56 |
-
|
57 |
}
|
58 |
|
59 |
return $loader;
|
60 |
}
|
61 |
}
|
62 |
|
63 |
-
function
|
64 |
{
|
65 |
if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) {
|
66 |
require $file;
|
2 |
|
3 |
// autoload_real.php @generated by Composer
|
4 |
|
5 |
+
class ComposerAutoloaderInitdeb3904dfced6b71023154877c51be97
|
6 |
{
|
7 |
private static $loader;
|
8 |
|
19 |
return self::$loader;
|
20 |
}
|
21 |
|
22 |
+
spl_autoload_register(array('ComposerAutoloaderInitdeb3904dfced6b71023154877c51be97', 'loadClassLoader'), true, true);
|
23 |
self::$loader = $loader = new \Composer\Autoload\ClassLoader();
|
24 |
+
spl_autoload_unregister(array('ComposerAutoloaderInitdeb3904dfced6b71023154877c51be97', 'loadClassLoader'));
|
25 |
|
26 |
$useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded());
|
27 |
if ($useStaticLoader) {
|
28 |
require_once __DIR__ . '/autoload_static.php';
|
29 |
|
30 |
+
call_user_func(\Composer\Autoload\ComposerStaticInitdeb3904dfced6b71023154877c51be97::getInitializer($loader));
|
31 |
} else {
|
32 |
$map = require __DIR__ . '/autoload_namespaces.php';
|
33 |
foreach ($map as $namespace => $path) {
|
48 |
$loader->register(true);
|
49 |
|
50 |
if ($useStaticLoader) {
|
51 |
+
$includeFiles = Composer\Autoload\ComposerStaticInitdeb3904dfced6b71023154877c51be97::$files;
|
52 |
} else {
|
53 |
$includeFiles = require __DIR__ . '/autoload_files.php';
|
54 |
}
|
55 |
foreach ($includeFiles as $fileIdentifier => $file) {
|
56 |
+
composerRequiredeb3904dfced6b71023154877c51be97($fileIdentifier, $file);
|
57 |
}
|
58 |
|
59 |
return $loader;
|
60 |
}
|
61 |
}
|
62 |
|
63 |
+
function composerRequiredeb3904dfced6b71023154877c51be97($fileIdentifier, $file)
|
64 |
{
|
65 |
if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) {
|
66 |
require $file;
|
@@ -4,7 +4,7 @@
|
|
4 |
|
5 |
namespace Composer\Autoload;
|
6 |
|
7 |
-
class
|
8 |
{
|
9 |
public static $files = array (
|
10 |
'7b11c4dc42b3b3023073cb14e519683c' => __DIR__ . '/..' . '/ralouphie/getallheaders/src/getallheaders.php',
|
@@ -64,8 +64,8 @@ class ComposerStaticInitff51838293b10d1f9ba6a6fd550fd5e8
|
|
64 |
public static function getInitializer(ClassLoader $loader)
|
65 |
{
|
66 |
return \Closure::bind(function () use ($loader) {
|
67 |
-
$loader->prefixLengthsPsr4 =
|
68 |
-
$loader->prefixDirsPsr4 =
|
69 |
|
70 |
}, null, ClassLoader::class);
|
71 |
}
|
4 |
|
5 |
namespace Composer\Autoload;
|
6 |
|
7 |
+
class ComposerStaticInitdeb3904dfced6b71023154877c51be97
|
8 |
{
|
9 |
public static $files = array (
|
10 |
'7b11c4dc42b3b3023073cb14e519683c' => __DIR__ . '/..' . '/ralouphie/getallheaders/src/getallheaders.php',
|
64 |
public static function getInitializer(ClassLoader $loader)
|
65 |
{
|
66 |
return \Closure::bind(function () use ($loader) {
|
67 |
+
$loader->prefixLengthsPsr4 = ComposerStaticInitdeb3904dfced6b71023154877c51be97::$prefixLengthsPsr4;
|
68 |
+
$loader->prefixDirsPsr4 = ComposerStaticInitdeb3904dfced6b71023154877c51be97::$prefixDirsPsr4;
|
69 |
|
70 |
}, null, ClassLoader::class);
|
71 |
}
|
@@ -1,7 +1,7 @@
|
|
1 |
##
|
2 |
## Bundle of CA Root Certificates
|
3 |
##
|
4 |
-
## Certificate data from Mozilla as of: Wed
|
5 |
##
|
6 |
## This is a bundle of X.509 certificates of public Certificate Authorities
|
7 |
## (CA). These were automatically extracted from Mozilla's root certificates
|
@@ -14,7 +14,7 @@
|
|
14 |
## Just configure this file as the SSLCACertificateFile.
|
15 |
##
|
16 |
## Conversion done with mk-ca-bundle.pl version 1.27.
|
17 |
-
## SHA256:
|
18 |
##
|
19 |
|
20 |
|
@@ -261,28 +261,6 @@ gn2Z9DH2canPLAEnpQW5qrJITirvn5NSUZU8UnOOVkwXQMAJKOSLakhT2+zNVVXxxvjpoixMptEm
|
|
261 |
X36vWkzaH6byHCx+rgIW0lbQL1dTR+iS
|
262 |
-----END CERTIFICATE-----
|
263 |
|
264 |
-
Visa eCommerce Root
|
265 |
-
===================
|
266 |
-
-----BEGIN CERTIFICATE-----
|
267 |
-
MIIDojCCAoqgAwIBAgIQE4Y1TR0/BvLB+WUF1ZAcYjANBgkqhkiG9w0BAQUFADBrMQswCQYDVQQG
|
268 |
-
EwJVUzENMAsGA1UEChMEVklTQTEvMC0GA1UECxMmVmlzYSBJbnRlcm5hdGlvbmFsIFNlcnZpY2Ug
|
269 |
-
QXNzb2NpYXRpb24xHDAaBgNVBAMTE1Zpc2EgZUNvbW1lcmNlIFJvb3QwHhcNMDIwNjI2MDIxODM2
|
270 |
-
WhcNMjIwNjI0MDAxNjEyWjBrMQswCQYDVQQGEwJVUzENMAsGA1UEChMEVklTQTEvMC0GA1UECxMm
|
271 |
-
VmlzYSBJbnRlcm5hdGlvbmFsIFNlcnZpY2UgQXNzb2NpYXRpb24xHDAaBgNVBAMTE1Zpc2EgZUNv
|
272 |
-
bW1lcmNlIFJvb3QwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQCvV95WHm6h2mCxlCfL
|
273 |
-
F9sHP4CFT8icttD0b0/Pmdjh28JIXDqsOTPHH2qLJj0rNfVIsZHBAk4ElpF7sDPwsRROEW+1QK8b
|
274 |
-
RaVK7362rPKgH1g/EkZgPI2h4H3PVz4zHvtH8aoVlwdVZqW1LS7YgFmypw23RuwhY/81q6UCzyr0
|
275 |
-
TP579ZRdhE2o8mCP2w4lPJ9zcc+U30rq299yOIzzlr3xF7zSujtFWsan9sYXiwGd/BmoKoMWuDpI
|
276 |
-
/k4+oKsGGelT84ATB+0tvz8KPFUgOSwsAGl0lUq8ILKpeeUYiZGo3BxN77t+Nwtd/jmliFKMAGzs
|
277 |
-
GHxBvfaLdXe6YJ2E5/4tAgMBAAGjQjBAMA8GA1UdEwEB/wQFMAMBAf8wDgYDVR0PAQH/BAQDAgEG
|
278 |
-
MB0GA1UdDgQWBBQVOIMPPyw/cDMezUb+B4wg4NfDtzANBgkqhkiG9w0BAQUFAAOCAQEAX/FBfXxc
|
279 |
-
CLkr4NWSR/pnXKUTwwMhmytMiUbPWU3J/qVAtmPN3XEolWcRzCSs00Rsca4BIGsDoo8Ytyk6feUW
|
280 |
-
YFN4PMCvFYP3j1IzJL1kk5fui/fbGKhtcbP3LBfQdCVp9/5rPJS+TUtBjE7ic9DjkCJzQ83z7+pz
|
281 |
-
zkWKsKZJ/0x9nXGIxHYdkFsd7v3M9+79YKWxehZx0RbQfBI8bGmX265fOZpwLwU8GUYEmSA20GBu
|
282 |
-
YQa7FkKMcPcw++DbZqMAAb3mLNqRX6BGi01qnD093QVG/na/oAo85ADmJ7f/hC3euiInlhBx6yLt
|
283 |
-
398znM/jra6O1I7mT1GvFpLgXPYHDw==
|
284 |
-
-----END CERTIFICATE-----
|
285 |
-
|
286 |
Comodo AAA Services root
|
287 |
========================
|
288 |
-----BEGIN CERTIFICATE-----
|
@@ -3238,3 +3216,186 @@ BgNVHQ4EFgQUSIcUrOPDnpBgOtfKie7TrYy0UGYwEAYJKwYBBAGCNxUBBAMCAQAwCgYIKoZIzj0E
|
|
3238 |
AwMDaAAwZQIwJsdpW9zV57LnyAyMjMPdeYwbY9XJUpROTYJKcx6ygISpJcBMWm1JKWB4E+J+SOtk
|
3239 |
AjEA2zQgMgj/mkkCtojeFK9dbJlxjRo/i9fgojaGHAeCOnZT/cKi7e97sIBPWA9LUzm9
|
3240 |
-----END CERTIFICATE-----
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
##
|
2 |
## Bundle of CA Root Certificates
|
3 |
##
|
4 |
+
## Certificate data from Mozilla as of: Wed Jan 23 04:12:09 2019 GMT
|
5 |
##
|
6 |
## This is a bundle of X.509 certificates of public Certificate Authorities
|
7 |
## (CA). These were automatically extracted from Mozilla's root certificates
|
14 |
## Just configure this file as the SSLCACertificateFile.
|
15 |
##
|
16 |
## Conversion done with mk-ca-bundle.pl version 1.27.
|
17 |
+
## SHA256: 18372117493b5b7ec006c31d966143fc95a9464a2b5f8d5188e23c5557b2292d
|
18 |
##
|
19 |
|
20 |
|
261 |
X36vWkzaH6byHCx+rgIW0lbQL1dTR+iS
|
262 |
-----END CERTIFICATE-----
|
263 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
264 |
Comodo AAA Services root
|
265 |
========================
|
266 |
-----BEGIN CERTIFICATE-----
|
3216 |
AwMDaAAwZQIwJsdpW9zV57LnyAyMjMPdeYwbY9XJUpROTYJKcx6ygISpJcBMWm1JKWB4E+J+SOtk
|
3217 |
AjEA2zQgMgj/mkkCtojeFK9dbJlxjRo/i9fgojaGHAeCOnZT/cKi7e97sIBPWA9LUzm9
|
3218 |
-----END CERTIFICATE-----
|
3219 |
+
|
3220 |
+
GTS Root R1
|
3221 |
+
===========
|
3222 |
+
-----BEGIN CERTIFICATE-----
|
3223 |
+
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
|
3247 |
+
CFF1pkgl
|
3248 |
+
-----END CERTIFICATE-----
|
3249 |
+
|
3250 |
+
GTS Root R2
|
3251 |
+
===========
|
3252 |
+
-----BEGIN CERTIFICATE-----
|
3253 |
+
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
|
3277 |
+
o/DUhgkC
|
3278 |
+
-----END CERTIFICATE-----
|
3279 |
+
|
3280 |
+
GTS Root R3
|
3281 |
+
===========
|
3282 |
+
-----BEGIN CERTIFICATE-----
|
3283 |
+
MIICDDCCAZGgAwIBAgIQbkepx2ypcyRAiQ8DVd2NHTAKBggqhkjOPQQDAzBHMQswCQYDVQQGEwJV
|
3284 |
+
UzEiMCAGA1UEChMZR29vZ2xlIFRydXN0IFNlcnZpY2VzIExMQzEUMBIGA1UEAxMLR1RTIFJvb3Qg
|
3285 |
+
UjMwHhcNMTYwNjIyMDAwMDAwWhcNMzYwNjIyMDAwMDAwWjBHMQswCQYDVQQGEwJVUzEiMCAGA1UE
|
3286 |
+
ChMZR29vZ2xlIFRydXN0IFNlcnZpY2VzIExMQzEUMBIGA1UEAxMLR1RTIFJvb3QgUjMwdjAQBgcq
|
3287 |
+
hkjOPQIBBgUrgQQAIgNiAAQfTzOHMymKoYTey8chWEGJ6ladK0uFxh1MJ7x/JlFyb+Kf1qPKzEUU
|
3288 |
+
Rout736GjOyxfi//qXGdGIRFBEFVbivqJn+7kAHjSxm65FSWRQmx1WyRRK2EE46ajA2ADDL24Cej
|
3289 |
+
QjBAMA4GA1UdDwEB/wQEAwIBBjAPBgNVHRMBAf8EBTADAQH/MB0GA1UdDgQWBBTB8Sa6oC2uhYHP
|
3290 |
+
0/EqEr24Cmf9vDAKBggqhkjOPQQDAwNpADBmAjEAgFukfCPAlaUs3L6JbyO5o91lAFJekazInXJ0
|
3291 |
+
glMLfalAvWhgxeG4VDvBNhcl2MG9AjEAnjWSdIUlUfUk7GRSJFClH9voy8l27OyCbvWFGFPouOOa
|
3292 |
+
KaqW04MjyaR7YbPMAuhd
|
3293 |
+
-----END CERTIFICATE-----
|
3294 |
+
|
3295 |
+
GTS Root R4
|
3296 |
+
===========
|
3297 |
+
-----BEGIN CERTIFICATE-----
|
3298 |
+
MIICCjCCAZGgAwIBAgIQbkepyIuUtui7OyrYorLBmTAKBggqhkjOPQQDAzBHMQswCQYDVQQGEwJV
|
3299 |
+
UzEiMCAGA1UEChMZR29vZ2xlIFRydXN0IFNlcnZpY2VzIExMQzEUMBIGA1UEAxMLR1RTIFJvb3Qg
|
3300 |
+
UjQwHhcNMTYwNjIyMDAwMDAwWhcNMzYwNjIyMDAwMDAwWjBHMQswCQYDVQQGEwJVUzEiMCAGA1UE
|
3301 |
+
ChMZR29vZ2xlIFRydXN0IFNlcnZpY2VzIExMQzEUMBIGA1UEAxMLR1RTIFJvb3QgUjQwdjAQBgcq
|
3302 |
+
hkjOPQIBBgUrgQQAIgNiAATzdHOnaItgrkO4NcWBMHtLSZ37wWHO5t5GvWvVYRg1rkDdc/eJkTBa
|
3303 |
+
6zzuhXyiQHY7qca4R9gq55KRanPpsXI5nymfopjTX15YhmUPoYRlBtHci8nHc8iMai/lxKvRHYqj
|
3304 |
+
QjBAMA4GA1UdDwEB/wQEAwIBBjAPBgNVHRMBAf8EBTADAQH/MB0GA1UdDgQWBBSATNbrdP9JNqPV
|
3305 |
+
2Py1PsVq8JQdjDAKBggqhkjOPQQDAwNnADBkAjBqUFJ0CMRw3J5QdCHojXohw0+WbhXRIjVhLfoI
|
3306 |
+
N+4Zba3bssx9BzT1YBkstTTZbyACMANxsbqjYAuG7ZoIapVon+Kz4ZNkfF6Tpt95LY2F45TPI11x
|
3307 |
+
zPKwTdb+mciUqXWi4w==
|
3308 |
+
-----END CERTIFICATE-----
|
3309 |
+
|
3310 |
+
UCA Global G2 Root
|
3311 |
+
==================
|
3312 |
+
-----BEGIN CERTIFICATE-----
|
3313 |
+
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
|
3337 |
+
-----END CERTIFICATE-----
|
3338 |
+
|
3339 |
+
UCA Extended Validation Root
|
3340 |
+
============================
|
3341 |
+
-----BEGIN CERTIFICATE-----
|
3342 |
+
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
|
3366 |
+
dhh2n1ax
|
3367 |
+
-----END CERTIFICATE-----
|
3368 |
+
|
3369 |
+
Certigna Root CA
|
3370 |
+
================
|
3371 |
+
-----BEGIN CERTIFICATE-----
|
3372 |
+
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
|
3401 |
+
-----END CERTIFICATE-----
|
@@ -1,17 +1,17 @@
|
|
1 |
[
|
2 |
{
|
3 |
"name": "composer/ca-bundle",
|
4 |
-
"version": "1.1.
|
5 |
-
"version_normalized": "1.1.
|
6 |
"source": {
|
7 |
"type": "git",
|
8 |
"url": "https://github.com/composer/ca-bundle.git",
|
9 |
-
"reference": "
|
10 |
},
|
11 |
"dist": {
|
12 |
"type": "zip",
|
13 |
-
"url": "https://api.github.com/repos/composer/ca-bundle/zipball/
|
14 |
-
"reference": "
|
15 |
"shasum": ""
|
16 |
},
|
17 |
"require": {
|
@@ -24,7 +24,7 @@
|
|
24 |
"psr/log": "^1.0",
|
25 |
"symfony/process": "^2.5 || ^3.0 || ^4.0"
|
26 |
},
|
27 |
-
"time": "
|
28 |
"type": "library",
|
29 |
"extra": {
|
30 |
"branch-alias": {
|
@@ -179,17 +179,17 @@
|
|
179 |
},
|
180 |
{
|
181 |
"name": "guzzlehttp/psr7",
|
182 |
-
"version": "1.5.
|
183 |
-
"version_normalized": "1.5.
|
184 |
"source": {
|
185 |
"type": "git",
|
186 |
"url": "https://github.com/guzzle/psr7.git",
|
187 |
-
"reference": "
|
188 |
},
|
189 |
"dist": {
|
190 |
"type": "zip",
|
191 |
-
"url": "https://api.github.com/repos/guzzle/psr7/zipball/
|
192 |
-
"reference": "
|
193 |
"shasum": ""
|
194 |
},
|
195 |
"require": {
|
@@ -203,7 +203,7 @@
|
|
203 |
"require-dev": {
|
204 |
"phpunit/phpunit": "~4.8.36 || ^5.7.27 || ^6.5.8"
|
205 |
},
|
206 |
-
"time": "2018-12-
|
207 |
"type": "library",
|
208 |
"extra": {
|
209 |
"branch-alias": {
|
1 |
[
|
2 |
{
|
3 |
"name": "composer/ca-bundle",
|
4 |
+
"version": "1.1.4",
|
5 |
+
"version_normalized": "1.1.4.0",
|
6 |
"source": {
|
7 |
"type": "git",
|
8 |
"url": "https://github.com/composer/ca-bundle.git",
|
9 |
+
"reference": "558f321c52faeb4828c03e7dc0cfe39a09e09a2d"
|
10 |
},
|
11 |
"dist": {
|
12 |
"type": "zip",
|
13 |
+
"url": "https://api.github.com/repos/composer/ca-bundle/zipball/558f321c52faeb4828c03e7dc0cfe39a09e09a2d",
|
14 |
+
"reference": "558f321c52faeb4828c03e7dc0cfe39a09e09a2d",
|
15 |
"shasum": ""
|
16 |
},
|
17 |
"require": {
|
24 |
"psr/log": "^1.0",
|
25 |
"symfony/process": "^2.5 || ^3.0 || ^4.0"
|
26 |
},
|
27 |
+
"time": "2019-01-28T09:30:10+00:00",
|
28 |
"type": "library",
|
29 |
"extra": {
|
30 |
"branch-alias": {
|
179 |
},
|
180 |
{
|
181 |
"name": "guzzlehttp/psr7",
|
182 |
+
"version": "1.5.2",
|
183 |
+
"version_normalized": "1.5.2.0",
|
184 |
"source": {
|
185 |
"type": "git",
|
186 |
"url": "https://github.com/guzzle/psr7.git",
|
187 |
+
"reference": "9f83dded91781a01c63574e387eaa769be769115"
|
188 |
},
|
189 |
"dist": {
|
190 |
"type": "zip",
|
191 |
+
"url": "https://api.github.com/repos/guzzle/psr7/zipball/9f83dded91781a01c63574e387eaa769be769115",
|
192 |
+
"reference": "9f83dded91781a01c63574e387eaa769be769115",
|
193 |
"shasum": ""
|
194 |
},
|
195 |
"require": {
|
203 |
"require-dev": {
|
204 |
"phpunit/phpunit": "~4.8.36 || ^5.7.27 || ^6.5.8"
|
205 |
},
|
206 |
+
"time": "2018-12-04T20:46:45+00:00",
|
207 |
"type": "library",
|
208 |
"extra": {
|
209 |
"branch-alias": {
|
@@ -10,6 +10,20 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
|
|
10 |
## [Unreleased]
|
11 |
|
12 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
13 |
## [1.5.0] - 2018-12-03
|
14 |
|
15 |
### Added
|
@@ -195,7 +209,9 @@ Currently unsupported:
|
|
195 |
|
196 |
|
197 |
|
198 |
-
[Unreleased]: https://github.com/guzzle/psr7/compare/1.5.
|
|
|
|
|
199 |
[1.5.0]: https://github.com/guzzle/psr7/compare/1.4.2...1.5.0
|
200 |
[1.4.2]: https://github.com/guzzle/psr7/compare/1.4.1...1.4.2
|
201 |
[1.4.1]: https://github.com/guzzle/psr7/compare/1.4.0...1.4.1
|
10 |
## [Unreleased]
|
11 |
|
12 |
|
13 |
+
## [1.5.2] - 2018-12-04
|
14 |
+
|
15 |
+
### Fixed
|
16 |
+
|
17 |
+
- Check body size when getting the message summary
|
18 |
+
|
19 |
+
|
20 |
+
## [1.5.1] - 2018-12-04
|
21 |
+
|
22 |
+
### Fixed
|
23 |
+
|
24 |
+
- Get the summary of a body only if it is readable
|
25 |
+
|
26 |
+
|
27 |
## [1.5.0] - 2018-12-03
|
28 |
|
29 |
### Added
|
209 |
|
210 |
|
211 |
|
212 |
+
[Unreleased]: https://github.com/guzzle/psr7/compare/1.5.2...HEAD
|
213 |
+
[1.5.2]: https://github.com/guzzle/psr7/compare/1.5.1...1.5.2
|
214 |
+
[1.5.1]: https://github.com/guzzle/psr7/compare/1.5.0...1.5.1
|
215 |
[1.5.0]: https://github.com/guzzle/psr7/compare/1.4.2...1.5.0
|
216 |
[1.4.2]: https://github.com/guzzle/psr7/compare/1.4.1...1.4.2
|
217 |
[1.4.1]: https://github.com/guzzle/psr7/compare/1.4.0...1.4.1
|
@@ -853,11 +853,16 @@ function get_message_body_summary(MessageInterface $message, $truncateAt = 120)
|
|
853 |
{
|
854 |
$body = $message->getBody();
|
855 |
|
856 |
-
if (!$body->isSeekable()) {
|
857 |
return null;
|
858 |
}
|
859 |
|
860 |
$size = $body->getSize();
|
|
|
|
|
|
|
|
|
|
|
861 |
$summary = $body->read($truncateAt);
|
862 |
$body->rewind();
|
863 |
|
853 |
{
|
854 |
$body = $message->getBody();
|
855 |
|
856 |
+
if (!$body->isSeekable() || !$body->isReadable()) {
|
857 |
return null;
|
858 |
}
|
859 |
|
860 |
$size = $body->getSize();
|
861 |
+
|
862 |
+
if ($size === 0) {
|
863 |
+
return null;
|
864 |
+
}
|
865 |
+
|
866 |
$summary = $body->read($truncateAt);
|
867 |
$body->rewind();
|
868 |
|
@@ -892,9 +892,9 @@ abstract class Mollie_WC_Gateway_Abstract extends WC_Payment_Gateway
|
|
892 |
|
893 |
// Add message to log
|
894 |
Mollie_WC_Plugin::debug( __METHOD__ . ' called for ' . $log_id );
|
895 |
-
|
896 |
// Make sure there are refunds to process at all
|
897 |
-
if (
|
898 |
Mollie_WC_Plugin::debug( __METHOD__ . ": No refunds to process for {$log_id}", true );
|
899 |
|
900 |
return;
|
@@ -992,7 +992,7 @@ abstract class Mollie_WC_Gateway_Abstract extends WC_Payment_Gateway
|
|
992 |
Mollie_WC_Plugin::debug( __METHOD__ . ' called for ' . $log_id );
|
993 |
|
994 |
// Make sure there are chargebacks to process at all
|
995 |
-
if (
|
996 |
Mollie_WC_Plugin::debug( __METHOD__ . ": No chargebacks to process for {$log_id}", true );
|
997 |
|
998 |
return;
|
@@ -1205,7 +1205,7 @@ abstract class Mollie_WC_Gateway_Abstract extends WC_Payment_Gateway
|
|
1205 |
|
1206 |
$payment = Mollie_WC_Plugin::getPaymentObject()->getActiveMolliePayment($order_id, false );
|
1207 |
|
1208 |
-
if ( ! $payment->isOpen() && ! $payment->isPending() && ! $payment->isPaid() ) {
|
1209 |
Mollie_WC_Plugin::addNotice( __( 'Your payment was not successful. Please complete your order with a different payment method.', 'mollie-payments-for-woocommerce' ) );
|
1210 |
// Return to order payment page
|
1211 |
if ( method_exists( $order, 'get_checkout_payment_url' ) ) {
|
@@ -1234,29 +1234,50 @@ abstract class Mollie_WC_Gateway_Abstract extends WC_Payment_Gateway
|
|
1234 |
* @since WooCommerce 2.2
|
1235 |
*/
|
1236 |
public function process_refund( $order_id, $amount = null, $reason = '' ) {
|
|
|
|
|
1237 |
$order = Mollie_WC_Plugin::getDataHelper()->getWcOrder( $order_id );
|
1238 |
|
1239 |
-
//
|
1240 |
if ( ! $order ) {
|
1241 |
-
|
1242 |
|
1243 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1244 |
}
|
1245 |
|
1246 |
-
//
|
1247 |
-
|
1248 |
|
1249 |
-
|
1250 |
-
if ( ! $payment ) {
|
1251 |
-
Mollie_WC_Plugin::debug( __METHOD__ . ' - Mollie payment object not found for order ' . $order_id );
|
1252 |
|
1253 |
-
|
|
|
|
|
1254 |
}
|
1255 |
|
1256 |
-
//
|
1257 |
-
$payment_object = Mollie_WC_Plugin::getPaymentFactoryHelper()->getPaymentObject( $
|
|
|
|
|
|
|
|
|
1258 |
|
1259 |
-
|
|
|
|
|
|
|
|
|
|
|
1260 |
|
1261 |
}
|
1262 |
|
@@ -1512,27 +1533,27 @@ abstract class Mollie_WC_Gateway_Abstract extends WC_Payment_Gateway
|
|
1512 |
|
1513 |
// Check whether the order is processed and paid via another gateway
|
1514 |
if ( $this->isOrderPaidByOtherGateway( $order ) ) {
|
1515 |
-
Mollie_WC_Plugin::debug( $this->id . ': Order ' . $order_id . ' orderNeedsPayment check: no, previously processed by other (non-Mollie) gateway.', true );
|
1516 |
|
1517 |
return false;
|
1518 |
}
|
1519 |
|
1520 |
// Check whether the order is processed and paid via Mollie
|
1521 |
if ( ! $this->isOrderPaidAndProcessed( $order ) ) {
|
1522 |
-
Mollie_WC_Plugin::debug( $this->id . ': Order ' . $order_id . ' orderNeedsPayment check: yes, order not previously processed by Mollie gateway.', true );
|
1523 |
|
1524 |
return true;
|
1525 |
}
|
1526 |
|
1527 |
if ( $order->needs_payment() ) {
|
1528 |
-
Mollie_WC_Plugin::debug( $this->id . ': Order ' . $order_id . ' orderNeedsPayment check: yes, WooCommerce thinks order needs payment.', true );
|
1529 |
|
1530 |
return true;
|
1531 |
}
|
1532 |
|
1533 |
// Has initial order status 'on-hold'
|
1534 |
if ( $this->getInitialOrderStatus() === self::STATUS_ON_HOLD && Mollie_WC_Plugin::getDataHelper()->hasOrderStatus( $order, self::STATUS_ON_HOLD ) ) {
|
1535 |
-
Mollie_WC_Plugin::debug( $this->id . ': Order ' . $order_id . ' orderNeedsPayment check: yes, has status On-Hold. ', true );
|
1536 |
|
1537 |
return true;
|
1538 |
}
|
@@ -1589,8 +1610,14 @@ abstract class Mollie_WC_Gateway_Abstract extends WC_Payment_Gateway
|
|
1589 |
'key' => $order->get_order_key(),
|
1590 |
), $return_url);
|
1591 |
}
|
|
|
1592 |
|
1593 |
$lang_url = $this->getSiteUrlWithLanguage();
|
|
|
|
|
|
|
|
|
|
|
1594 |
$return_url = str_replace($site_url, $lang_url, $return_url);
|
1595 |
|
1596 |
return apply_filters(Mollie_WC_Plugin::PLUGIN_ID . '_return_url', $return_url, $order);
|
@@ -1620,6 +1647,11 @@ abstract class Mollie_WC_Gateway_Abstract extends WC_Payment_Gateway
|
|
1620 |
}
|
1621 |
|
1622 |
$lang_url = $this->getSiteUrlWithLanguage();
|
|
|
|
|
|
|
|
|
|
|
1623 |
$webhook_url = str_replace($site_url, $lang_url, $webhook_url);
|
1624 |
|
1625 |
// Some (multilanguage) plugins will add a extra slash to the url (/nl//) causing the URL to redirect and lose it's data.
|
@@ -1849,18 +1881,22 @@ abstract class Mollie_WC_Gateway_Abstract extends WC_Payment_Gateway
|
|
1849 |
*/
|
1850 |
protected function isAvailableMethodInCheckout( $filters ) {
|
1851 |
|
|
|
|
|
1852 |
$settings_helper = Mollie_WC_Plugin::getSettingsHelper();
|
1853 |
$test_mode = $settings_helper->isTestModeEnabled();
|
1854 |
|
1855 |
try {
|
1856 |
|
1857 |
-
$filters_key = $filters['amount']['currency'] . '_' . str_replace( '.', '', $filters['amount']['value'] ) . '_' . $filters['locale'] . '_' . $filters['sequenceType'];
|
1858 |
$transient_id = Mollie_WC_Plugin::getDataHelper()->getTransientId( 'api_methods_' . ( $test_mode ? 'test' : 'live' ) . '_' . $filters_key );
|
1859 |
|
1860 |
-
|
|
|
1861 |
|
1862 |
-
|
1863 |
-
|
|
|
1864 |
}
|
1865 |
|
1866 |
if ( empty ( $methods ) ) {
|
892 |
|
893 |
// Add message to log
|
894 |
Mollie_WC_Plugin::debug( __METHOD__ . ' called for ' . $log_id );
|
895 |
+
|
896 |
// Make sure there are refunds to process at all
|
897 |
+
if ( empty($payment->_links->refunds) ) {
|
898 |
Mollie_WC_Plugin::debug( __METHOD__ . ": No refunds to process for {$log_id}", true );
|
899 |
|
900 |
return;
|
992 |
Mollie_WC_Plugin::debug( __METHOD__ . ' called for ' . $log_id );
|
993 |
|
994 |
// Make sure there are chargebacks to process at all
|
995 |
+
if ( empty($payment->_links->chargebacks) ) {
|
996 |
Mollie_WC_Plugin::debug( __METHOD__ . ": No chargebacks to process for {$log_id}", true );
|
997 |
|
998 |
return;
|
1205 |
|
1206 |
$payment = Mollie_WC_Plugin::getPaymentObject()->getActiveMolliePayment($order_id, false );
|
1207 |
|
1208 |
+
if ( ! $payment->isOpen() && ! $payment->isPending() && ! $payment->isPaid() && ! $payment->isAuthorized() ) {
|
1209 |
Mollie_WC_Plugin::addNotice( __( 'Your payment was not successful. Please complete your order with a different payment method.', 'mollie-payments-for-woocommerce' ) );
|
1210 |
// Return to order payment page
|
1211 |
if ( method_exists( $order, 'get_checkout_payment_url' ) ) {
|
1234 |
* @since WooCommerce 2.2
|
1235 |
*/
|
1236 |
public function process_refund( $order_id, $amount = null, $reason = '' ) {
|
1237 |
+
|
1238 |
+
// Get the WooCommerce order
|
1239 |
$order = Mollie_WC_Plugin::getDataHelper()->getWcOrder( $order_id );
|
1240 |
|
1241 |
+
// WooCommerce order not found
|
1242 |
if ( ! $order ) {
|
1243 |
+
$error_message = "Could not find WooCommerce order $order_id.";
|
1244 |
|
1245 |
+
Mollie_WC_Plugin::debug( __METHOD__ . ' - ' . $error_message);
|
1246 |
+
|
1247 |
+
return new WP_Error( '1', $error_message );
|
1248 |
+
}
|
1249 |
+
|
1250 |
+
// Check if there is a Mollie Payment Order object connected to this WooCommerce order
|
1251 |
+
$payment_object_id = Mollie_WC_Plugin::getPaymentObject()->getActiveMollieOrderId( $order_id);
|
1252 |
+
|
1253 |
+
// If there is no Mollie Payment Order object, try getting a Mollie Payment Payment object
|
1254 |
+
if ( $payment_object_id == null ) {
|
1255 |
+
$payment_object_id = Mollie_WC_Plugin::getPaymentObject()->getActiveMolliePaymentId( $order_id);
|
1256 |
}
|
1257 |
|
1258 |
+
// Mollie Payment object not found
|
1259 |
+
if ( ! $payment_object_id ) {
|
1260 |
|
1261 |
+
$error_message = "Can\'t process refund. Could not find Mollie Payment object id for order $order_id.";
|
|
|
|
|
1262 |
|
1263 |
+
Mollie_WC_Plugin::debug( __METHOD__ . ' - ' . $error_message );
|
1264 |
+
|
1265 |
+
return new WP_Error( '1', $error_message );
|
1266 |
}
|
1267 |
|
1268 |
+
// Load payment object from Mollie, don't use cache
|
1269 |
+
$payment_object = Mollie_WC_Plugin::getPaymentFactoryHelper()->getPaymentObject( $payment_object_id );
|
1270 |
+
|
1271 |
+
if ( ! $payment_object ) {
|
1272 |
+
|
1273 |
+
$error_message = "Can\'t process refund. Could not find Mollie Payment object data for order $order_id.";
|
1274 |
|
1275 |
+
Mollie_WC_Plugin::debug( __METHOD__ . ' - ' . $error_message);
|
1276 |
+
|
1277 |
+
return new WP_Error( '1', $error_message);
|
1278 |
+
}
|
1279 |
+
|
1280 |
+
return $payment_object->refund( $order, $order_id, $payment_object, $amount, $reason );
|
1281 |
|
1282 |
}
|
1283 |
|
1533 |
|
1534 |
// Check whether the order is processed and paid via another gateway
|
1535 |
if ( $this->isOrderPaidByOtherGateway( $order ) ) {
|
1536 |
+
Mollie_WC_Plugin::debug( __METHOD__ . ' ' . $this->id . ': Order ' . $order_id . ' orderNeedsPayment check: no, previously processed by other (non-Mollie) gateway.', true );
|
1537 |
|
1538 |
return false;
|
1539 |
}
|
1540 |
|
1541 |
// Check whether the order is processed and paid via Mollie
|
1542 |
if ( ! $this->isOrderPaidAndProcessed( $order ) ) {
|
1543 |
+
Mollie_WC_Plugin::debug( __METHOD__ . ' ' . $this->id . ': Order ' . $order_id . ' orderNeedsPayment check: yes, order not previously processed by Mollie gateway.', true );
|
1544 |
|
1545 |
return true;
|
1546 |
}
|
1547 |
|
1548 |
if ( $order->needs_payment() ) {
|
1549 |
+
Mollie_WC_Plugin::debug( __METHOD__ . ' ' . $this->id . ': Order ' . $order_id . ' orderNeedsPayment check: yes, WooCommerce thinks order needs payment.', true );
|
1550 |
|
1551 |
return true;
|
1552 |
}
|
1553 |
|
1554 |
// Has initial order status 'on-hold'
|
1555 |
if ( $this->getInitialOrderStatus() === self::STATUS_ON_HOLD && Mollie_WC_Plugin::getDataHelper()->hasOrderStatus( $order, self::STATUS_ON_HOLD ) ) {
|
1556 |
+
Mollie_WC_Plugin::debug( __METHOD__ . ' ' . $this->id . ': Order ' . $order_id . ' orderNeedsPayment check: yes, has status On-Hold. ', true );
|
1557 |
|
1558 |
return true;
|
1559 |
}
|
1610 |
'key' => $order->get_order_key(),
|
1611 |
), $return_url);
|
1612 |
}
|
1613 |
+
$return_url = $this->removeTrailingSlashAfterParamater( $return_url );
|
1614 |
|
1615 |
$lang_url = $this->getSiteUrlWithLanguage();
|
1616 |
+
|
1617 |
+
if ( strpos( $lang_url, '/?') !== FALSE ) {
|
1618 |
+
$return_url = str_replace( '/?', '&', $return_url);
|
1619 |
+
}
|
1620 |
+
|
1621 |
$return_url = str_replace($site_url, $lang_url, $return_url);
|
1622 |
|
1623 |
return apply_filters(Mollie_WC_Plugin::PLUGIN_ID . '_return_url', $return_url, $order);
|
1647 |
}
|
1648 |
|
1649 |
$lang_url = $this->getSiteUrlWithLanguage();
|
1650 |
+
|
1651 |
+
if ( strpos( $lang_url, '/?') !== FALSE ) {
|
1652 |
+
$webhook_url = str_replace( '/?', '&', $webhook_url);
|
1653 |
+
}
|
1654 |
+
|
1655 |
$webhook_url = str_replace($site_url, $lang_url, $webhook_url);
|
1656 |
|
1657 |
// Some (multilanguage) plugins will add a extra slash to the url (/nl//) causing the URL to redirect and lose it's data.
|
1881 |
*/
|
1882 |
protected function isAvailableMethodInCheckout( $filters ) {
|
1883 |
|
1884 |
+
$methods = array ();
|
1885 |
+
|
1886 |
$settings_helper = Mollie_WC_Plugin::getSettingsHelper();
|
1887 |
$test_mode = $settings_helper->isTestModeEnabled();
|
1888 |
|
1889 |
try {
|
1890 |
|
1891 |
+
$filters_key = $filters['amount']['currency'] . '_' . str_replace( '.', '', $filters['amount']['value'] ) . '_' . $filters['billingCountry'] . '_' . $filters['locale'] . '_' . $filters['sequenceType'];
|
1892 |
$transient_id = Mollie_WC_Plugin::getDataHelper()->getTransientId( 'api_methods_' . ( $test_mode ? 'test' : 'live' ) . '_' . $filters_key );
|
1893 |
|
1894 |
+
if ( version_compare( PHP_VERSION, '7.3.0' >= 0 ) ) {
|
1895 |
+
$cached = unserialize( get_transient( $transient_id ) );
|
1896 |
|
1897 |
+
if ( $cached && $cached instanceof \Mollie\Api\Resources\MethodCollection ) {
|
1898 |
+
$methods = $cached;
|
1899 |
+
}
|
1900 |
}
|
1901 |
|
1902 |
if ( empty ( $methods ) ) {
|
@@ -162,6 +162,13 @@ abstract class Mollie_WC_Gateway_AbstractSubscription extends Mollie_WC_Gateway_
|
|
162 |
return;
|
163 |
}
|
164 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
165 |
// Check that a new payment is made for renewal order
|
166 |
if ( $mollie_payment_id == null ) {
|
167 |
return;
|
@@ -207,6 +214,9 @@ abstract class Mollie_WC_Gateway_AbstractSubscription extends Mollie_WC_Gateway_
|
|
207 |
|
208 |
$renewal_order_id = ( version_compare( WC_VERSION, '3.0', '<' ) ) ? $renewal_order->id : $renewal_order->get_id();
|
209 |
|
|
|
|
|
|
|
210 |
Mollie_WC_Plugin::debug($this->id . ': Try to create renewal payment for renewal order ' . $renewal_order_id);
|
211 |
$initial_order_status = $this->getInitialOrderStatus();
|
212 |
|
162 |
return;
|
163 |
}
|
164 |
|
165 |
+
// Check if WooCommerce Subscriptions Failed Recurring Payment Retry System is in-use, if it is, don't update subscription status
|
166 |
+
if ( class_exists('WCS_Retry_Manager') && WCS_Retry_Manager::is_retry_enabled() && $subscription->get_date( 'payment_retry' ) > 0 ) {
|
167 |
+
Mollie_WC_Plugin::debug( __METHOD__ . ' - WooCommerce Subscriptions Failed Recurring Payment Retry System in use, not updating subscription status to Active!' );
|
168 |
+
|
169 |
+
return;
|
170 |
+
}
|
171 |
+
|
172 |
// Check that a new payment is made for renewal order
|
173 |
if ( $mollie_payment_id == null ) {
|
174 |
return;
|
214 |
|
215 |
$renewal_order_id = ( version_compare( WC_VERSION, '3.0', '<' ) ) ? $renewal_order->id : $renewal_order->get_id();
|
216 |
|
217 |
+
// Allow developers to hook into the subscription renewal payment before it processed
|
218 |
+
do_action(Mollie_WC_Plugin::PLUGIN_ID . '_before_renewal_payment_created', $renewal_order);
|
219 |
+
|
220 |
Mollie_WC_Plugin::debug($this->id . ': Try to create renewal payment for renewal order ' . $renewal_order_id);
|
221 |
$initial_order_status = $this->getInitialOrderStatus();
|
222 |
|
@@ -8,6 +8,12 @@ class Mollie_WC_Gateway_DirectDebit extends Mollie_WC_Gateway_Abstract {
|
|
8 |
*/
|
9 |
public function __construct ()
|
10 |
{
|
|
|
|
|
|
|
|
|
|
|
|
|
11 |
parent::__construct();
|
12 |
}
|
13 |
|
8 |
*/
|
9 |
public function __construct ()
|
10 |
{
|
11 |
+
|
12 |
+
$this->supports = array(
|
13 |
+
'products',
|
14 |
+
'refunds',
|
15 |
+
);
|
16 |
+
|
17 |
parent::__construct();
|
18 |
}
|
19 |
|
@@ -11,7 +11,7 @@ class Mollie_WC_Gateway_KlarnaPayLater extends Mollie_WC_Gateway_Abstract
|
|
11 |
{
|
12 |
$this->supports = array(
|
13 |
'products',
|
14 |
-
|
15 |
);
|
16 |
|
17 |
parent::__construct();
|
11 |
{
|
12 |
$this->supports = array(
|
13 |
'products',
|
14 |
+
'refunds',
|
15 |
);
|
16 |
|
17 |
parent::__construct();
|
@@ -11,7 +11,7 @@ class Mollie_WC_Gateway_KlarnaSliceIt extends Mollie_WC_Gateway_Abstract
|
|
11 |
{
|
12 |
$this->supports = array(
|
13 |
'products',
|
14 |
-
|
15 |
);
|
16 |
|
17 |
parent::__construct();
|
11 |
{
|
12 |
$this->supports = array(
|
13 |
'products',
|
14 |
+
'refunds',
|
15 |
);
|
16 |
|
17 |
parent::__construct();
|
@@ -63,7 +63,7 @@ class Mollie_WC_Gateway_Sofort extends Mollie_WC_Gateway_AbstractSepaRecurring
|
|
63 |
/* translators: Placeholder 1: consumer name, placeholder 2: consumer IBAN, placeholder 3: consumer BIC */
|
64 |
__('Payment completed by <strong>%s</strong> (IBAN (last 4 digits): %s, BIC: %s)', 'mollie-payments-for-woocommerce'),
|
65 |
$payment->details->consumerName,
|
66 |
-
|
67 |
$payment->details->consumerBic
|
68 |
);
|
69 |
}
|
63 |
/* translators: Placeholder 1: consumer name, placeholder 2: consumer IBAN, placeholder 3: consumer BIC */
|
64 |
__('Payment completed by <strong>%s</strong> (IBAN (last 4 digits): %s, BIC: %s)', 'mollie-payments-for-woocommerce'),
|
65 |
$payment->details->consumerName,
|
66 |
+
substr($payment->details->consumerAccount, -4),
|
67 |
$payment->details->consumerBic
|
68 |
);
|
69 |
}
|
@@ -309,8 +309,13 @@ class Mollie_WC_Helper_Data
|
|
309 |
}
|
310 |
|
311 |
protected function getApiPaymentMethods( $test_mode = false, $use_cache = true, $filters = array () ) {
|
|
|
312 |
$methods = array ();
|
313 |
|
|
|
|
|
|
|
|
|
314 |
try {
|
315 |
|
316 |
$filters_key = ( ! empty ( $filters['sequenceType'] ) ) ? '_' . $filters['sequenceType'] : '';
|
309 |
}
|
310 |
|
311 |
protected function getApiPaymentMethods( $test_mode = false, $use_cache = true, $filters = array () ) {
|
312 |
+
|
313 |
$methods = array ();
|
314 |
|
315 |
+
if ( version_compare( PHP_VERSION, '7.3.0' >= 0 ) ) {
|
316 |
+
$use_cache = false;
|
317 |
+
}
|
318 |
+
|
319 |
try {
|
320 |
|
321 |
$filters_key = ( ! empty ( $filters['sequenceType'] ) ) ? '_' . $filters['sequenceType'] : '';
|
@@ -44,15 +44,14 @@ class Mollie_WC_Helper_OrderLines {
|
|
44 |
}
|
45 |
|
46 |
/**
|
47 |
-
* Gets formatted order lines from WooCommerce
|
48 |
*
|
49 |
* @return array
|
50 |
*/
|
51 |
public function order_lines() {
|
52 |
-
$this->process_cart();
|
53 |
-
$this->process_shipping();
|
54 |
|
55 |
-
$this->
|
|
|
56 |
$this->process_fees();
|
57 |
|
58 |
return array (
|
@@ -71,12 +70,13 @@ class Mollie_WC_Helper_OrderLines {
|
|
71 |
}
|
72 |
|
73 |
/**
|
74 |
-
* Process WooCommerce
|
75 |
*
|
76 |
* @access private
|
77 |
*/
|
78 |
-
private function
|
79 |
-
foreach (
|
|
|
80 |
if ( $cart_item['quantity'] ) {
|
81 |
if ( $cart_item['variation_id'] ) {
|
82 |
$product = wc_get_product( $cart_item['variation_id'] );
|
@@ -109,6 +109,10 @@ class Mollie_WC_Helper_OrderLines {
|
|
109 |
'currency' => $this->currency,
|
110 |
'value' => Mollie_WC_Plugin::getDataHelper()->formatCurrencyValue( $this->get_item_discount_amount( $cart_item ), $this->currency ),
|
111 |
),
|
|
|
|
|
|
|
|
|
112 |
);
|
113 |
|
114 |
// TODO David: Continue testing adding WooCommerce images to Mollie Orders
|
@@ -124,7 +128,8 @@ class Mollie_WC_Helper_OrderLines {
|
|
124 |
* @access private
|
125 |
*/
|
126 |
private function process_shipping() {
|
127 |
-
if (
|
|
|
128 |
$shipping = array (
|
129 |
'type' => 'shipping_fee',
|
130 |
'name' => $this->get_shipping_name(),
|
@@ -141,84 +146,31 @@ class Mollie_WC_Helper_OrderLines {
|
|
141 |
'vatAmount' => array (
|
142 |
'currency' => $this->currency,
|
143 |
'value' => Mollie_WC_Plugin::getDataHelper()->formatCurrencyValue( $this->get_shipping_tax_amount(), $this->currency ),
|
144 |
-
)
|
|
|
|
|
|
|
145 |
);
|
146 |
|
147 |
$this->order_lines[] = $shipping;
|
148 |
}
|
149 |
}
|
150 |
|
151 |
-
/**
|
152 |
-
* Process smart coupons.
|
153 |
-
*
|
154 |
-
* @access private
|
155 |
-
*/
|
156 |
-
private function process_coupons() {
|
157 |
-
if ( ! empty( WC()->cart->get_coupons() ) ) {
|
158 |
-
foreach ( WC()->cart->get_coupons() as $coupon_key => $coupon ) {
|
159 |
-
$coupon_amount = 0;
|
160 |
-
$coupon_tax_amount = '';
|
161 |
-
|
162 |
-
// Smart coupons are processed as real line items, cart and product discounts sent for reference only.
|
163 |
-
if ( 'smart_coupon' === $coupon->get_discount_type() ) {
|
164 |
-
$coupon_amount = - WC()->cart->get_coupon_discount_amount( $coupon_key );
|
165 |
-
$coupon_tax_amount = - WC()->cart->get_coupon_discount_tax_amount( $coupon_key );
|
166 |
-
} else {
|
167 |
-
if ( 'US' === $this->shop_country ) {
|
168 |
-
$coupon_amount = 0;
|
169 |
-
$coupon_tax_amount = 0;
|
170 |
-
|
171 |
-
if ( $coupon->is_type( 'fixed_cart' ) || $coupon->is_type( 'percent' ) ) {
|
172 |
-
$coupon_type = 'Cart discount';
|
173 |
-
} elseif ( $coupon->is_type( 'fixed_product' ) || $coupon->is_type( 'percent_product' ) ) {
|
174 |
-
$coupon_type = 'Product discount';
|
175 |
-
} else {
|
176 |
-
$coupon_type = 'Discount';
|
177 |
-
}
|
178 |
-
|
179 |
-
$coupon_key = $coupon_type . ' (amount: ' . WC()->cart->get_coupon_discount_amount( $coupon_key ) . ', tax amount: ' . WC()->cart->get_coupon_discount_tax_amount( $coupon_key ) . ')';
|
180 |
-
}
|
181 |
-
}
|
182 |
-
|
183 |
-
// Add separate discount line item, but only if it's a smart coupon or country is US.
|
184 |
-
if ( 'smart_coupon' === $coupon->get_discount_type() || 'US' === $this->shop_country ) {
|
185 |
-
$discount = array (
|
186 |
-
'name' => $coupon_key,
|
187 |
-
'quantity' => 1,
|
188 |
-
'unitPrice' => array (
|
189 |
-
'currency' => $this->currency,
|
190 |
-
'value' => Mollie_WC_Plugin::getDataHelper()->formatCurrencyValue( $coupon_amount, $this->currency ),
|
191 |
-
),
|
192 |
-
'vatRate' => 0,
|
193 |
-
'totalAmount' => array (
|
194 |
-
'currency' => $this->currency,
|
195 |
-
'value' => Mollie_WC_Plugin::getDataHelper()->formatCurrencyValue( $coupon_amount, $this->currency ),
|
196 |
-
),
|
197 |
-
'vatAmount' => array (
|
198 |
-
'currency' => $this->currency,
|
199 |
-
'value' => Mollie_WC_Plugin::getDataHelper()->formatCurrencyValue( $coupon_tax_amount, $this->currency ),
|
200 |
-
),
|
201 |
-
);
|
202 |
-
|
203 |
-
$this->order_lines[] = $discount;
|
204 |
-
}
|
205 |
-
} // End foreach().
|
206 |
-
} // End if().
|
207 |
-
}
|
208 |
-
|
209 |
/**
|
210 |
* Process fees.
|
211 |
*
|
212 |
* @access private
|
213 |
*/
|
214 |
private function process_fees() {
|
215 |
-
|
216 |
-
|
217 |
-
|
|
|
|
|
218 |
|
219 |
// Calculate tax rate.
|
220 |
$_tax = new WC_Tax();
|
221 |
-
$tmp_rates = $_tax::get_rates( $cart_fee
|
222 |
$vat = array_shift( $tmp_rates );
|
223 |
|
224 |
if ( isset( $vat['rate'] ) ) {
|
@@ -227,18 +179,18 @@ class Mollie_WC_Helper_OrderLines {
|
|
227 |
$cart_fee_vat_rate = 0;
|
228 |
}
|
229 |
|
230 |
-
$cart_fee_tax_amount = $cart_fee
|
231 |
-
$cart_fee_total = ( $cart_fee
|
232 |
|
233 |
} else {
|
234 |
$cart_fee_vat_rate = 0;
|
235 |
$cart_fee_tax_amount = 0;
|
236 |
-
$cart_fee_total = $cart_fee
|
237 |
}
|
238 |
|
239 |
$fee = array (
|
240 |
'type' => 'surcharge',
|
241 |
-
'name' => $cart_fee
|
242 |
'quantity' => 1,
|
243 |
'vatRate' => Mollie_WC_Plugin::getDataHelper()->formatCurrencyValue( $cart_fee_vat_rate, $this->currency ),
|
244 |
'unitPrice' => array (
|
@@ -253,6 +205,9 @@ class Mollie_WC_Helper_OrderLines {
|
|
253 |
'currency' => $this->currency,
|
254 |
'value' => Mollie_WC_Plugin::getDataHelper()->formatCurrencyValue( $cart_fee_tax_amount, $this->currency ),
|
255 |
),
|
|
|
|
|
|
|
256 |
);
|
257 |
|
258 |
$this->order_lines[] = $fee;
|
@@ -268,13 +223,12 @@ class Mollie_WC_Helper_OrderLines {
|
|
268 |
* @since 1.0
|
269 |
* @access private
|
270 |
*
|
271 |
-
* @param
|
272 |
*
|
273 |
* @return string $item_name Cart item name.
|
274 |
*/
|
275 |
private function get_item_name( $cart_item ) {
|
276 |
-
$
|
277 |
-
$item_name = $cart_item_data->get_name();
|
278 |
|
279 |
return html_entity_decode(strip_tags($item_name) );
|
280 |
}
|
@@ -285,7 +239,7 @@ class Mollie_WC_Helper_OrderLines {
|
|
285 |
* @since 1.0
|
286 |
* @access private
|
287 |
*
|
288 |
-
* @param
|
289 |
*
|
290 |
* @return integer $item_tax_amount Item tax amount.
|
291 |
*/
|
@@ -301,7 +255,7 @@ class Mollie_WC_Helper_OrderLines {
|
|
301 |
* @since 1.0
|
302 |
* @access private
|
303 |
*
|
304 |
-
* @param
|
305 |
* @param object $product Product object.
|
306 |
*
|
307 |
* @return integer $item_vatRate Item tax percentage formatted for Mollie Orders API.
|
@@ -333,7 +287,7 @@ class Mollie_WC_Helper_OrderLines {
|
|
333 |
* @since 1.0
|
334 |
* @access private
|
335 |
*
|
336 |
-
* @param
|
337 |
*
|
338 |
* @return integer $item_price Cart item price.
|
339 |
*/
|
@@ -351,7 +305,7 @@ class Mollie_WC_Helper_OrderLines {
|
|
351 |
* @since 1.0
|
352 |
* @access private
|
353 |
*
|
354 |
-
* @param
|
355 |
*
|
356 |
* @return integer $item_quantity Cart item quantity.
|
357 |
*/
|
@@ -360,7 +314,7 @@ class Mollie_WC_Helper_OrderLines {
|
|
360 |
}
|
361 |
|
362 |
/**
|
363 |
-
* Get cart item
|
364 |
*
|
365 |
* Returns SKU or product ID.
|
366 |
*
|
@@ -387,7 +341,7 @@ class Mollie_WC_Helper_OrderLines {
|
|
387 |
* @since 1.0
|
388 |
* @access private
|
389 |
*
|
390 |
-
* @param
|
391 |
*
|
392 |
* @return integer $item_discount_amount Cart item discount.
|
393 |
*/
|
@@ -409,7 +363,7 @@ class Mollie_WC_Helper_OrderLines {
|
|
409 |
* @since 1.0
|
410 |
* @access private
|
411 |
*
|
412 |
-
* @param
|
413 |
*
|
414 |
* @return integer $item_total_amount Cart item total amount.
|
415 |
*/
|
@@ -429,9 +383,8 @@ class Mollie_WC_Helper_OrderLines {
|
|
429 |
* @return string $shipping_name Name for selected shipping method.
|
430 |
*/
|
431 |
private function get_shipping_name() {
|
432 |
-
$shipping_packages = WC()->shipping->get_packages();
|
433 |
|
434 |
-
foreach ( $
|
435 |
$chosen_method = isset( WC()->session->chosen_shipping_methods[ $i ] ) ? WC()->session->chosen_shipping_methods[ $i ] : '';
|
436 |
if ( '' !== $chosen_method ) {
|
437 |
$package_rates = $package['rates'];
|
@@ -450,6 +403,27 @@ class Mollie_WC_Helper_OrderLines {
|
|
450 |
return (string) $shipping_name;
|
451 |
}
|
452 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
453 |
/**
|
454 |
* Get shipping method amount.
|
455 |
*
|
44 |
}
|
45 |
|
46 |
/**
|
47 |
+
* Gets formatted order lines from WooCommerce order.
|
48 |
*
|
49 |
* @return array
|
50 |
*/
|
51 |
public function order_lines() {
|
|
|
|
|
52 |
|
53 |
+
$this->process_items();
|
54 |
+
$this->process_shipping();
|
55 |
$this->process_fees();
|
56 |
|
57 |
return array (
|
70 |
}
|
71 |
|
72 |
/**
|
73 |
+
* Process WooCommerce order items to Mollie Orders API - order lines.
|
74 |
*
|
75 |
* @access private
|
76 |
*/
|
77 |
+
private function process_items() {
|
78 |
+
foreach ( $this->order->get_items() as $cart_item ) {
|
79 |
+
|
80 |
if ( $cart_item['quantity'] ) {
|
81 |
if ( $cart_item['variation_id'] ) {
|
82 |
$product = wc_get_product( $cart_item['variation_id'] );
|
109 |
'currency' => $this->currency,
|
110 |
'value' => Mollie_WC_Plugin::getDataHelper()->formatCurrencyValue( $this->get_item_discount_amount( $cart_item ), $this->currency ),
|
111 |
),
|
112 |
+
'metadata' =>
|
113 |
+
array(
|
114 |
+
'order_item_id' => $cart_item->get_id(),
|
115 |
+
),
|
116 |
);
|
117 |
|
118 |
// TODO David: Continue testing adding WooCommerce images to Mollie Orders
|
128 |
* @access private
|
129 |
*/
|
130 |
private function process_shipping() {
|
131 |
+
if ( $this->order->get_shipping_methods() && WC()->session->get( 'chosen_shipping_methods' ) ) {
|
132 |
+
|
133 |
$shipping = array (
|
134 |
'type' => 'shipping_fee',
|
135 |
'name' => $this->get_shipping_name(),
|
146 |
'vatAmount' => array (
|
147 |
'currency' => $this->currency,
|
148 |
'value' => Mollie_WC_Plugin::getDataHelper()->formatCurrencyValue( $this->get_shipping_tax_amount(), $this->currency ),
|
149 |
+
),
|
150 |
+
'metadata' => array (
|
151 |
+
'order_item_id' => $this->get_shipping_id(),
|
152 |
+
),
|
153 |
);
|
154 |
|
155 |
$this->order_lines[] = $shipping;
|
156 |
}
|
157 |
}
|
158 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
159 |
/**
|
160 |
* Process fees.
|
161 |
*
|
162 |
* @access private
|
163 |
*/
|
164 |
private function process_fees() {
|
165 |
+
|
166 |
+
if ( ! empty( $this->order->get_items( 'fee' ) ) ) {
|
167 |
+
foreach ( $this->order->get_items( 'fee' ) as $cart_fee ) {
|
168 |
+
|
169 |
+
if ( $cart_fee['tax_status'] == 'taxable' && $cart_fee['total_tax'] > 0 ) {
|
170 |
|
171 |
// Calculate tax rate.
|
172 |
$_tax = new WC_Tax();
|
173 |
+
$tmp_rates = $_tax::get_rates( $cart_fee['tax_class'] );
|
174 |
$vat = array_shift( $tmp_rates );
|
175 |
|
176 |
if ( isset( $vat['rate'] ) ) {
|
179 |
$cart_fee_vat_rate = 0;
|
180 |
}
|
181 |
|
182 |
+
$cart_fee_tax_amount = $cart_fee['total_tax'];
|
183 |
+
$cart_fee_total = ( $cart_fee['total'] + $cart_fee['total_tax'] );
|
184 |
|
185 |
} else {
|
186 |
$cart_fee_vat_rate = 0;
|
187 |
$cart_fee_tax_amount = 0;
|
188 |
+
$cart_fee_total = $cart_fee['total'];
|
189 |
}
|
190 |
|
191 |
$fee = array (
|
192 |
'type' => 'surcharge',
|
193 |
+
'name' => $cart_fee['name'],
|
194 |
'quantity' => 1,
|
195 |
'vatRate' => Mollie_WC_Plugin::getDataHelper()->formatCurrencyValue( $cart_fee_vat_rate, $this->currency ),
|
196 |
'unitPrice' => array (
|
205 |
'currency' => $this->currency,
|
206 |
'value' => Mollie_WC_Plugin::getDataHelper()->formatCurrencyValue( $cart_fee_tax_amount, $this->currency ),
|
207 |
),
|
208 |
+
'metadata' => array (
|
209 |
+
'order_item_id' => $cart_fee->get_id(),
|
210 |
+
),
|
211 |
);
|
212 |
|
213 |
$this->order_lines[] = $fee;
|
223 |
* @since 1.0
|
224 |
* @access private
|
225 |
*
|
226 |
+
* @param WC_Order_Item $cart_item Cart item.
|
227 |
*
|
228 |
* @return string $item_name Cart item name.
|
229 |
*/
|
230 |
private function get_item_name( $cart_item ) {
|
231 |
+
$item_name = $cart_item->get_name();
|
|
|
232 |
|
233 |
return html_entity_decode(strip_tags($item_name) );
|
234 |
}
|
239 |
* @since 1.0
|
240 |
* @access private
|
241 |
*
|
242 |
+
* @param WC_Order_Item $cart_item Cart item.
|
243 |
*
|
244 |
* @return integer $item_tax_amount Item tax amount.
|
245 |
*/
|
255 |
* @since 1.0
|
256 |
* @access private
|
257 |
*
|
258 |
+
* @param WC_Order_Item $cart_item Cart item.
|
259 |
* @param object $product Product object.
|
260 |
*
|
261 |
* @return integer $item_vatRate Item tax percentage formatted for Mollie Orders API.
|
287 |
* @since 1.0
|
288 |
* @access private
|
289 |
*
|
290 |
+
* @param WC_Order_Item $cart_item Cart item.
|
291 |
*
|
292 |
* @return integer $item_price Cart item price.
|
293 |
*/
|
305 |
* @since 1.0
|
306 |
* @access private
|
307 |
*
|
308 |
+
* @param WC_Order_Item $cart_item Cart item.
|
309 |
*
|
310 |
* @return integer $item_quantity Cart item quantity.
|
311 |
*/
|
314 |
}
|
315 |
|
316 |
/**
|
317 |
+
* Get cart item SKU.
|
318 |
*
|
319 |
* Returns SKU or product ID.
|
320 |
*
|
341 |
* @since 1.0
|
342 |
* @access private
|
343 |
*
|
344 |
+
* @param WC_Order_Item $cart_item Cart item.
|
345 |
*
|
346 |
* @return integer $item_discount_amount Cart item discount.
|
347 |
*/
|
363 |
* @since 1.0
|
364 |
* @access private
|
365 |
*
|
366 |
+
* @param WC_Order_Item $cart_item Cart item.
|
367 |
*
|
368 |
* @return integer $item_total_amount Cart item total amount.
|
369 |
*/
|
383 |
* @return string $shipping_name Name for selected shipping method.
|
384 |
*/
|
385 |
private function get_shipping_name() {
|
|
|
386 |
|
387 |
+
foreach ( $this->order->get_items( 'shipping' ) as $i => $package ) {
|
388 |
$chosen_method = isset( WC()->session->chosen_shipping_methods[ $i ] ) ? WC()->session->chosen_shipping_methods[ $i ] : '';
|
389 |
if ( '' !== $chosen_method ) {
|
390 |
$package_rates = $package['rates'];
|
403 |
return (string) $shipping_name;
|
404 |
}
|
405 |
|
406 |
+
|
407 |
+
/**
|
408 |
+
* Get shipping method name.
|
409 |
+
*
|
410 |
+
* @since 1.0
|
411 |
+
* @access private
|
412 |
+
*
|
413 |
+
* @return string $shipping_name Name for selected shipping method.
|
414 |
+
*/
|
415 |
+
private function get_shipping_id() {
|
416 |
+
$shipping_id = '';
|
417 |
+
|
418 |
+
foreach ( $this->order->get_items( 'shipping' ) as $i => $package ) {
|
419 |
+
|
420 |
+
$shipping_id = $package->get_id();
|
421 |
+
|
422 |
+
}
|
423 |
+
|
424 |
+
return (string) $shipping_id;
|
425 |
+
}
|
426 |
+
|
427 |
/**
|
428 |
* Get shipping method amount.
|
429 |
*
|
@@ -430,7 +430,7 @@ class Mollie_WC_Helper_Settings
|
|
430 |
'<a href="https://www.mollie.com/nl/docs/reference/payments/create" target="_blank">',
|
431 |
'</a>'
|
432 |
),
|
433 |
-
'default' => '',
|
434 |
),
|
435 |
array(
|
436 |
'id' => $this->getSettingId('customer_details'),
|
430 |
'<a href="https://www.mollie.com/nl/docs/reference/payments/create" target="_blank">',
|
431 |
'</a>'
|
432 |
),
|
433 |
+
'default' => 'wp_locale',
|
434 |
),
|
435 |
array(
|
436 |
'id' => $this->getSettingId('customer_details'),
|
@@ -66,6 +66,13 @@ class Mollie_WC_Helper_Status
|
|
66 |
return $is_compatible = false;
|
67 |
}
|
68 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
69 |
try
|
70 |
{
|
71 |
$checker = $this->getApiClientCompatibilityChecker();
|
66 |
return $is_compatible = false;
|
67 |
}
|
68 |
|
69 |
+
if ( function_exists( 'extension_loaded' ) && ! extension_loaded( 'json' ) ) {
|
70 |
+
|
71 |
+
$this->errors[] = __('Mollie Payments for WooCommerce requires the JSON extension for PHP. Enable it in your server or ask your webhoster to enable it for you.', 'mollie-payments-for-woocommerce');
|
72 |
+
|
73 |
+
return $is_compatible = false;
|
74 |
+
}
|
75 |
+
|
76 |
try
|
77 |
{
|
78 |
$checker = $this->getApiClientCompatibilityChecker();
|
@@ -25,7 +25,7 @@ class Mollie_WC_Payment_Object {
|
|
25 |
* @param bool $test_mode (default: false)
|
26 |
* @param bool $use_cache (default: true)
|
27 |
*
|
28 |
-
* @return Mollie\Api\Resources\Payment|null
|
29 |
*/
|
30 |
public function getPaymentObject( $payment_id, $test_mode = false, $use_cache = true ) {
|
31 |
return static::$payment;
|
@@ -558,14 +558,15 @@ class Mollie_WC_Payment_Object {
|
|
558 |
}
|
559 |
|
560 |
/**
|
561 |
-
* Process a
|
|
|
|
|
562 |
* @param int $order_id
|
563 |
-
* @param
|
|
|
564 |
* @param string $reason
|
565 |
-
|
566 |
-
* @since WooCommerce 2.2
|
567 |
*/
|
568 |
-
public function refund( $order, $order_id, $amount = null, $reason = '' ) {
|
569 |
|
570 |
}
|
571 |
|
25 |
* @param bool $test_mode (default: false)
|
26 |
* @param bool $use_cache (default: true)
|
27 |
*
|
28 |
+
* @return Mollie\Api\Resources\Payment|Mollie\Api\Resources\Order|null
|
29 |
*/
|
30 |
public function getPaymentObject( $payment_id, $test_mode = false, $use_cache = true ) {
|
31 |
return static::$payment;
|
558 |
}
|
559 |
|
560 |
/**
|
561 |
+
* Process a payment object refund
|
562 |
+
*
|
563 |
+
* @param object $order
|
564 |
* @param int $order_id
|
565 |
+
* @param object $payment_object
|
566 |
+
* @param null $amount
|
567 |
* @param string $reason
|
|
|
|
|
568 |
*/
|
569 |
+
public function refund( WC_Order $order, $order_id, $payment_object, $amount = null, $reason = '' ) {
|
570 |
|
571 |
}
|
572 |
|
@@ -121,24 +121,24 @@ class Mollie_WC_Payment_Order extends Mollie_WC_Payment_Object {
|
|
121 |
|
122 |
// Build the Mollie order data
|
123 |
$paymentRequestData = array (
|
124 |
-
'amount'
|
125 |
'currency' => Mollie_WC_Plugin::getDataHelper()->getOrderCurrency( $order ),
|
126 |
'value' => Mollie_WC_Plugin::getDataHelper()->formatCurrencyValue( $order->get_total(), Mollie_WC_Plugin::getDataHelper()->getOrderCurrency( $order ) )
|
127 |
),
|
128 |
-
'redirectUrl'
|
129 |
-
'webhookUrl'
|
130 |
-
'method'
|
131 |
-
'payment'
|
132 |
'issuer' => $selected_issuer
|
133 |
),
|
134 |
-
'locale'
|
135 |
-
'billingAddress'
|
136 |
-
'metadata'
|
137 |
'order_id' => $order->get_id(),
|
138 |
-
'order_number' => $order->get_order_number()
|
139 |
-
),
|
140 |
-
'lines'
|
141 |
-
'orderNumber'
|
142 |
);
|
143 |
|
144 |
// Add sequenceType for subscriptions first payments
|
@@ -431,11 +431,13 @@ class Mollie_WC_Payment_Order extends Mollie_WC_Payment_Object {
|
|
431 |
|
432 |
$order->add_order_note( sprintf(
|
433 |
/* translators: Placeholder 1: payment method title, placeholder 2: payment ID */
|
434 |
-
__( 'Order completed at Mollie for %s order (%s). At least one order line completed. ', 'mollie-payments-for-woocommerce' ),
|
435 |
$payment_method_title,
|
436 |
$payment->id . ( $payment->mode == 'test' ? ( ' - ' . __( 'test mode', 'mollie-payments-for-woocommerce' ) ) : '' )
|
437 |
) );
|
438 |
|
|
|
|
|
439 |
// Mark the order as processed and paid via Mollie
|
440 |
$this->setOrderPaidAndProcessed( $order );
|
441 |
|
@@ -568,21 +570,21 @@ class Mollie_WC_Payment_Order extends Mollie_WC_Payment_Object {
|
|
568 |
// Add messages to log
|
569 |
Mollie_WC_Plugin::debug( __METHOD__ . ' called for order ' . $order_id );
|
570 |
|
571 |
-
//
|
572 |
-
|
573 |
|
574 |
-
|
575 |
-
|
576 |
|
577 |
-
|
578 |
-
|
579 |
|
580 |
-
|
581 |
-
$new_order_status = apply_filters( Mollie_WC_Plugin::PLUGIN_ID . '_order_status_on_hold_' . $this->id, $new_order_status );
|
582 |
|
583 |
-
// Update order status for order with failed payment, don't restore stock
|
584 |
|
585 |
-
|
|
|
|
|
586 |
|
587 |
if ( $gateway || ( $gateway instanceof Mollie_WC_Gateway_Abstract ) ) {
|
588 |
$gateway->updateOrderStatus(
|
@@ -598,8 +600,7 @@ class Mollie_WC_Payment_Order extends Mollie_WC_Payment_Object {
|
|
598 |
);
|
599 |
}
|
600 |
|
601 |
-
Mollie_WC_Plugin::debug( __METHOD__ . ' called for order ' . $order_id . ' and payment ' . $payment->id . ', renewal order payment failed, order set to
|
602 |
-
|
603 |
|
604 |
// Send a "Failed order" email to notify the admin
|
605 |
$emails = WC()->mailer()->get_emails();
|
@@ -608,18 +609,6 @@ class Mollie_WC_Payment_Order extends Mollie_WC_Payment_Object {
|
|
608 |
}
|
609 |
} else {
|
610 |
|
611 |
-
// New order status
|
612 |
-
$new_order_status = Mollie_WC_Gateway_Abstract::STATUS_FAILED;
|
613 |
-
|
614 |
-
// Overwrite plugin-wide
|
615 |
-
$new_order_status = apply_filters( Mollie_WC_Plugin::PLUGIN_ID . '_order_status_on_hold', $new_order_status );
|
616 |
-
|
617 |
-
// Overwrite gateway-wide
|
618 |
-
$new_order_status = apply_filters( Mollie_WC_Plugin::PLUGIN_ID . '_order_status_on_hold_' . $this->id, $new_order_status );
|
619 |
-
|
620 |
-
// Update order status for order with failed payment, don't restore stock
|
621 |
-
$gateway = Mollie_WC_Plugin::getDataHelper()->getWcPaymentGatewayByOrder( $order );
|
622 |
-
|
623 |
if ( $gateway || ( $gateway instanceof Mollie_WC_Gateway_Abstract ) ) {
|
624 |
|
625 |
$gateway->updateOrderStatus(
|
@@ -728,5 +717,298 @@ class Mollie_WC_Payment_Order extends Mollie_WC_Payment_Object {
|
|
728 |
}
|
729 |
}
|
730 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
731 |
|
732 |
}
|
121 |
|
122 |
// Build the Mollie order data
|
123 |
$paymentRequestData = array (
|
124 |
+
'amount' => array (
|
125 |
'currency' => Mollie_WC_Plugin::getDataHelper()->getOrderCurrency( $order ),
|
126 |
'value' => Mollie_WC_Plugin::getDataHelper()->formatCurrencyValue( $order->get_total(), Mollie_WC_Plugin::getDataHelper()->getOrderCurrency( $order ) )
|
127 |
),
|
128 |
+
'redirectUrl' => $return_url,
|
129 |
+
'webhookUrl' => $webhook_url,
|
130 |
+
'method' => $mollie_method,
|
131 |
+
'payment' => array (
|
132 |
'issuer' => $selected_issuer
|
133 |
),
|
134 |
+
'locale' => $payment_locale,
|
135 |
+
'billingAddress' => $billingAddress,
|
136 |
+
'metadata' => apply_filters( Mollie_WC_Plugin::PLUGIN_ID . '_payment_object_metadata', array (
|
137 |
'order_id' => $order->get_id(),
|
138 |
+
'order_number' => $order->get_order_number()
|
139 |
+
) ),
|
140 |
+
'lines' => $order_lines['lines'],
|
141 |
+
'orderNumber' => $order->get_order_number(), // TODO David: use order number or order id?
|
142 |
);
|
143 |
|
144 |
// Add sequenceType for subscriptions first payments
|
431 |
|
432 |
$order->add_order_note( sprintf(
|
433 |
/* translators: Placeholder 1: payment method title, placeholder 2: payment ID */
|
434 |
+
__( 'Order completed at Mollie for %s order (%s). At least one order line completed. Remember: Completed status for an order at Mollie is not the same as Completed status in WooCommerce!', 'mollie-payments-for-woocommerce' ),
|
435 |
$payment_method_title,
|
436 |
$payment->id . ( $payment->mode == 'test' ? ( ' - ' . __( 'test mode', 'mollie-payments-for-woocommerce' ) ) : '' )
|
437 |
) );
|
438 |
|
439 |
+
// TODO David: consider setting WooCommerce orders to completed when an order is completed in Mollie? Completed in WooCommerce is not the same as Completed in Mollie! From the API docs "When all order lines are completed or canceled, the order will be set to this status." Probably need to check if it should be converted to completed or cancelled.
|
440 |
+
|
441 |
// Mark the order as processed and paid via Mollie
|
442 |
$this->setOrderPaidAndProcessed( $order );
|
443 |
|
570 |
// Add messages to log
|
571 |
Mollie_WC_Plugin::debug( __METHOD__ . ' called for order ' . $order_id );
|
572 |
|
573 |
+
// New order status
|
574 |
+
$new_order_status = Mollie_WC_Gateway_Abstract::STATUS_FAILED;
|
575 |
|
576 |
+
// Overwrite plugin-wide
|
577 |
+
$new_order_status = apply_filters( Mollie_WC_Plugin::PLUGIN_ID . '_order_status_failed', $new_order_status );
|
578 |
|
579 |
+
// Overwrite gateway-wide
|
580 |
+
$new_order_status = apply_filters( Mollie_WC_Plugin::PLUGIN_ID . '_order_status_failed_' . $this->id, $new_order_status );
|
581 |
|
582 |
+
$gateway = Mollie_WC_Plugin::getDataHelper()->getWcPaymentGatewayByOrder( $order );
|
|
|
583 |
|
|
|
584 |
|
585 |
+
// If WooCommerce Subscriptions is installed, process this failure as a subscription, otherwise as a regular order
|
586 |
+
// Update order status for order with failed payment, don't restore stock
|
587 |
+
if ( function_exists( 'wcs_order_contains_renewal' ) && wcs_order_contains_renewal( $order_id ) ) {
|
588 |
|
589 |
if ( $gateway || ( $gateway instanceof Mollie_WC_Gateway_Abstract ) ) {
|
590 |
$gateway->updateOrderStatus(
|
600 |
);
|
601 |
}
|
602 |
|
603 |
+
Mollie_WC_Plugin::debug( __METHOD__ . ' called for order ' . $order_id . ' and payment ' . $payment->id . ', renewal order payment failed, order set to ' . $new_order_status . ' for shop-owner review.' );
|
|
|
604 |
|
605 |
// Send a "Failed order" email to notify the admin
|
606 |
$emails = WC()->mailer()->get_emails();
|
609 |
}
|
610 |
} else {
|
611 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
612 |
if ( $gateway || ( $gateway instanceof Mollie_WC_Gateway_Abstract ) ) {
|
613 |
|
614 |
$gateway->updateOrderStatus(
|
717 |
}
|
718 |
}
|
719 |
|
720 |
+
/**
|
721 |
+
* Process a payment object refund
|
722 |
+
*
|
723 |
+
* @param WC_Order $order
|
724 |
+
* @param int $order_id
|
725 |
+
* @param object $payment_object
|
726 |
+
* @param null $amount
|
727 |
+
* @param string $reason
|
728 |
+
*
|
729 |
+
* @return bool|\WP_Error
|
730 |
+
*/
|
731 |
+
public function refund( WC_Order $order, $order_id, $payment_object, $amount = null, $reason = '' ) {
|
732 |
+
|
733 |
+
Mollie_WC_Plugin::debug( __METHOD__ . ' - ' . $order_id . ' - Try to process refunds or cancels.' );
|
734 |
+
|
735 |
+
try {
|
736 |
+
$payment_object = $this->getPaymentObject( $payment_object->data );
|
737 |
+
|
738 |
+
if ( ! $payment_object ) {
|
739 |
+
|
740 |
+
$error_message = "Could not find active Mollie order for WooCommerce order ' . $order_id";
|
741 |
+
|
742 |
+
Mollie_WC_Plugin::debug( __METHOD__ . ' - ' . $error_message );
|
743 |
+
|
744 |
+
throw new Exception ( $error_message );
|
745 |
+
}
|
746 |
+
|
747 |
+
if ( ! ( $payment_object->isPaid() || $payment_object->isAuthorized() || $payment_object->isCompleted() ) ) {
|
748 |
+
|
749 |
+
$error_message = "Can not cancel or refund $payment_object->id as order $order_id has status " . ucfirst( $payment_object->status ) . ", it should be at least Paid, Authorized or Completed.";
|
750 |
+
|
751 |
+
Mollie_WC_Plugin::debug( __METHOD__ . ' - ' . $error_message );
|
752 |
+
|
753 |
+
throw new Exception ( $error_message );
|
754 |
+
}
|
755 |
+
|
756 |
+
// Get all existing refunds
|
757 |
+
$refunds = $order->get_refunds();
|
758 |
+
|
759 |
+
// Get latest refund
|
760 |
+
$woocommerce_refund = wc_get_order( $refunds[0] );
|
761 |
+
|
762 |
+
// Get order items from refund
|
763 |
+
$items = $woocommerce_refund->get_items( array ( 'line_item', 'fee', 'shipping' ) );
|
764 |
+
|
765 |
+
|
766 |
+
// If the refund contains items, it's a refund for individual order lines
|
767 |
+
if ( ! empty ( $items ) ) {
|
768 |
+
|
769 |
+
// Compare total amount of the refund to the combined totals of all refunded items,
|
770 |
+
// if the refund total is greater than sum of refund items, merchant is also doing a
|
771 |
+
// 'Refund amount', which the Mollie API does not support. In that case, stop entire
|
772 |
+
// process and warn the merchant.
|
773 |
+
|
774 |
+
$totals = 0;
|
775 |
+
|
776 |
+
foreach ( $items as $item_id => $item_data ) {
|
777 |
+
|
778 |
+
$totals += $item_data->get_total() + $item_data->get_total_tax(); // Get the item line total
|
779 |
+
|
780 |
+
}
|
781 |
+
|
782 |
+
$totals = number_format(abs($totals), 2); // WooCommerce - sum of all refund items
|
783 |
+
$amount = number_format($amount, 2); // WooCommerce - refund amount
|
784 |
+
|
785 |
+
if ( $amount !== $totals ) {
|
786 |
+
$error_message = "The sum of refunds for all order lines is not identical to the refund amount, so this refund will be processed as a payment amount refund, not an order line refund.";
|
787 |
+
$order->add_order_note( $error_message );
|
788 |
+
Mollie_WC_Plugin::debug( __METHOD__ . ' - ' . $error_message );
|
789 |
+
|
790 |
+
return $this->refund_amount( $order, $order_id, $amount, $payment_object, $reason );
|
791 |
+
}
|
792 |
+
|
793 |
+
return $this->refund_order_items( $order, $order_id, $amount, $items, $payment_object, $reason );
|
794 |
+
|
795 |
+
}
|
796 |
+
|
797 |
+
// If the refund does not contain items, only refund the amount
|
798 |
+
if ( empty ( $items ) ) {
|
799 |
+
|
800 |
+
return $this->refund_amount( $order, $order_id, $amount, $payment_object, $reason );
|
801 |
+
|
802 |
+
}
|
803 |
+
}
|
804 |
+
catch ( Exception $e ) {
|
805 |
+
return new WP_Error( 1, $e->getMessage() );
|
806 |
+
}
|
807 |
+
|
808 |
+
return false;
|
809 |
+
|
810 |
+
}
|
811 |
+
|
812 |
+
/**
|
813 |
+
* @param $order
|
814 |
+
* @param $order_id
|
815 |
+
* @param $amount
|
816 |
+
* @param $items
|
817 |
+
* @param $payment_object
|
818 |
+
* @param $reason
|
819 |
+
*
|
820 |
+
* @return bool
|
821 |
+
* @throws \Mollie\Api\Exceptions\ApiException|Exception
|
822 |
+
*/
|
823 |
+
public function refund_order_items( $order, $order_id, $amount, $items, $payment_object, $reason ) {
|
824 |
+
|
825 |
+
Mollie_WC_Plugin::debug( 'Try to process individual order item refunds or cancels.' );
|
826 |
+
|
827 |
+
// Try to do the actual refunds or cancellations
|
828 |
+
|
829 |
+
// Loop through items in the WooCommerce refund
|
830 |
+
foreach ( $items as $key => $item ) {
|
831 |
+
|
832 |
+
// Some merchants update orders with an order line with value 0, in that case skip processing that order line.
|
833 |
+
$item_refund_amount_precheck = abs( $item->get_total() + $item->get_total_tax() );
|
834 |
+
if ( $item_refund_amount_precheck == 0 ) {
|
835 |
+
continue;
|
836 |
+
}
|
837 |
+
|
838 |
+
// Loop through items in the Mollie payment object (Order)
|
839 |
+
foreach ( $payment_object->lines as $line ) {
|
840 |
+
|
841 |
+
// If there is no metadata wth the order item ID, this order can't process individual order lines
|
842 |
+
if ( empty( $line->metadata->order_item_id ) ) {
|
843 |
+
|
844 |
+
$note_message = 'Refunds for this specific order can not be processed per order line. Trying to process this as an amount refund instead.';
|
845 |
+
Mollie_WC_Plugin::debug( __METHOD__ . " - " . $note_message );
|
846 |
+
|
847 |
+
return $this->refund_amount( $order, $order_id, $amount, $payment_object, $reason );
|
848 |
+
|
849 |
+
}
|
850 |
+
|
851 |
+
// Get the Mollie order line information that we need later
|
852 |
+
$original_order_item_id = $item->get_meta( '_refunded_item_id', true );
|
853 |
+
$item_refund_amount = abs( $item->get_total() + $item->get_total_tax() );
|
854 |
+
|
855 |
+
if ( $original_order_item_id == $line->metadata->order_item_id ) {
|
856 |
+
|
857 |
+
// Mollie doesn't allow a partial refund of less than 1 quantity, so when merchants try that, warn them and block the process
|
858 |
+
if ( abs($item->get_quantity()) < 1 ) {
|
859 |
+
|
860 |
+
$note_message = sprintf( "Mollie doesn't allow a partial refund of less than 1 quantity per order line. Use 'Refund amount' instead. The WooCommerce order item ID is %s, Mollie order line ID is %s.",
|
861 |
+
$original_order_item_id,
|
862 |
+
$line->id
|
863 |
+
);
|
864 |
+
|
865 |
+
Mollie_WC_Plugin::debug( __METHOD__ . " - Order $order_id: " . $note_message );
|
866 |
+
throw new Exception ( $note_message );
|
867 |
+
}
|
868 |
+
|
869 |
+
// Is test mode enabled?
|
870 |
+
$test_mode = Mollie_WC_Plugin::getSettingsHelper()->isTestModeEnabled();
|
871 |
+
|
872 |
+
// Get the Mollie order
|
873 |
+
$mollie_order = Mollie_WC_Plugin::getApiHelper()->getApiClient( $test_mode )->orders->get( $payment_object->id );
|
874 |
+
|
875 |
+
$item_total_amount = abs(number_format($item->get_total() + $item->get_total_tax(), 2));
|
876 |
+
|
877 |
+
// Prepare the order line to update
|
878 |
+
if ( !empty( $line->discountAmount) ) {
|
879 |
+
$lines = array (
|
880 |
+
'lines' => array (
|
881 |
+
array (
|
882 |
+
'id' => $line->id,
|
883 |
+
'quantity' => abs( $item->get_quantity() ),
|
884 |
+
'amount' => array (
|
885 |
+
'value' => Mollie_WC_Plugin::getDataHelper()->formatCurrencyValue( $item_total_amount, Mollie_WC_Plugin::getDataHelper()->getOrderCurrency( $order ) ),
|
886 |
+
'currency' => Mollie_WC_Plugin::getDataHelper()->getOrderCurrency( $order )
|
887 |
+
),
|
888 |
+
)
|
889 |
+
)
|
890 |
+
);
|
891 |
+
} else {
|
892 |
+
$lines = array (
|
893 |
+
'lines' => array (
|
894 |
+
array (
|
895 |
+
'id' => $line->id,
|
896 |
+
'quantity' => abs( $item->get_quantity() ),
|
897 |
+
)
|
898 |
+
)
|
899 |
+
);
|
900 |
+
}
|
901 |
+
|
902 |
+
if ( $line->status == 'created' || $line->status == 'authorized' ) {
|
903 |
+
|
904 |
+
// Returns null if successful.
|
905 |
+
$refund = $mollie_order->cancelLines( $lines );
|
906 |
+
|
907 |
+
Mollie_WC_Plugin::debug( __METHOD__ . ' - Cancelled order line: ' . abs( $item->get_quantity() ) . 'x ' . $item->get_name() . '. Mollie order line: ' . $line->id . ', payment object: ' . $payment_object->id . ', order: ' . $order_id . ', amount: ' . Mollie_WC_Plugin::getDataHelper()->getOrderCurrency( $order ) . wc_format_decimal( $item_refund_amount ) . ( ! empty( $reason ) ? ', reason: ' . $reason : '' ) );
|
908 |
+
|
909 |
+
if ( $refund == null ) {
|
910 |
+
$note_message = sprintf(
|
911 |
+
__( '%sx %s cancelled for %s%s in WooCommerce and at Mollie.', 'mollie-payments-for-woocommerce' ),
|
912 |
+
abs( $item->get_quantity() ),
|
913 |
+
$item->get_name(),
|
914 |
+
Mollie_WC_Plugin::getDataHelper()->getOrderCurrency( $order ),
|
915 |
+
$item_refund_amount
|
916 |
+
);
|
917 |
+
}
|
918 |
+
}
|
919 |
+
|
920 |
+
if ( $line->status == 'paid' || $line->status == 'shipping' || $line->status == 'completed' ) {
|
921 |
+
$lines['description'] = $reason;
|
922 |
+
$refund = $mollie_order->refund( $lines );
|
923 |
+
|
924 |
+
Mollie_WC_Plugin::debug( __METHOD__ . ' - Refunded order line: ' . abs( $item->get_quantity() ) . 'x ' . $item->get_name() . '. Mollie order line: ' . $line->id . ', payment object: ' . $payment_object->id . ', order: ' . $order_id . ', amount: ' . Mollie_WC_Plugin::getDataHelper()->getOrderCurrency( $order ) . wc_format_decimal( $item_refund_amount ) . ( ! empty( $reason ) ? ', reason: ' . $reason : '' ) );
|
925 |
+
|
926 |
+
$note_message = sprintf(
|
927 |
+
__( '%sx %s refunded for %s%s in WooCommerce and at Mollie.%s Refund ID: %s.', 'mollie-payments-for-woocommerce' ),
|
928 |
+
abs( $item->get_quantity() ),
|
929 |
+
$item->get_name(),
|
930 |
+
Mollie_WC_Plugin::getDataHelper()->getOrderCurrency( $order ),
|
931 |
+
$item_refund_amount,
|
932 |
+
( ! empty( $reason ) ? ' Reason: ' . $reason . '.' : '' ),
|
933 |
+
$refund->id
|
934 |
+
);
|
935 |
+
}
|
936 |
+
|
937 |
+
do_action( Mollie_WC_Plugin::PLUGIN_ID . '_refund_created', $refund, $order );
|
938 |
+
|
939 |
+
$order->add_order_note( $note_message );
|
940 |
+
Mollie_WC_Plugin::debug( $note_message );
|
941 |
+
|
942 |
+
// drop item from array
|
943 |
+
unset( $items[ $item->get_id() ] );
|
944 |
+
|
945 |
+
}
|
946 |
+
|
947 |
+
}
|
948 |
+
|
949 |
+
}
|
950 |
+
|
951 |
+
// TODO David: add special version of
|
952 |
+
// do_action( Mollie_WC_Plugin::PLUGIN_ID . '_refund_created', $refund, $order );
|
953 |
+
|
954 |
+
return true;
|
955 |
+
|
956 |
+
}
|
957 |
+
|
958 |
+
/**
|
959 |
+
* @param $order
|
960 |
+
* @param $order_id
|
961 |
+
* @param $amount
|
962 |
+
* @param $payment_object
|
963 |
+
* @param $reason
|
964 |
+
*
|
965 |
+
* @return bool
|
966 |
+
* @throws \Mollie\Api\Exceptions\ApiException|Exception
|
967 |
+
*/
|
968 |
+
public function refund_amount( $order, $order_id, $amount, $payment_object, $reason ) {
|
969 |
+
|
970 |
+
Mollie_WC_Plugin::debug( 'Try to process an amount refund (not individual order line)' );
|
971 |
+
|
972 |
+
$payment_object_payment = Mollie_WC_Plugin::getPaymentObject()->getActiveMolliePayment( $order_id );
|
973 |
+
|
974 |
+
// Is test mode enabled?
|
975 |
+
$test_mode = Mollie_WC_Plugin::getSettingsHelper()->isTestModeEnabled();
|
976 |
+
|
977 |
+
if ( $payment_object->isCreated() || $payment_object->isAuthorized() || $payment_object->isShipping() ) {
|
978 |
+
$note_message = 'Can not refund order amount that has status ' . ucfirst( $payment_object->status ) . ' at Mollie.';
|
979 |
+
$order->add_order_note( $note_message );
|
980 |
+
Mollie_WC_Plugin::debug( __METHOD__ . ' - ' . $note_message );
|
981 |
+
throw new Exception ( $note_message );
|
982 |
+
}
|
983 |
+
|
984 |
+
if ( $payment_object->isPaid() || $payment_object->isShipping() || $payment_object->isCompleted() ) {
|
985 |
+
|
986 |
+
$refund = Mollie_WC_Plugin::getApiHelper()->getApiClient( $test_mode )->payments->refund( $payment_object_payment, array (
|
987 |
+
'amount' => array (
|
988 |
+
'currency' => Mollie_WC_Plugin::getDataHelper()->getOrderCurrency( $order ),
|
989 |
+
'value' => Mollie_WC_Plugin::getDataHelper()->formatCurrencyValue( $amount, Mollie_WC_Plugin::getDataHelper()->getOrderCurrency( $order ) )
|
990 |
+
),
|
991 |
+
'description' => $reason
|
992 |
+
) );
|
993 |
+
|
994 |
+
$note_message = sprintf(
|
995 |
+
__( 'Amount refund of %s%s refunded in WooCommerce and at Mollie.%s Refund ID: %s.', 'mollie-payments-for-woocommerce' ),
|
996 |
+
Mollie_WC_Plugin::getDataHelper()->getOrderCurrency( $order ),
|
997 |
+
$amount,
|
998 |
+
( ! empty( $reason ) ? ' Reason: ' . $reason . '.' : '' ),
|
999 |
+
$refund->id
|
1000 |
+
);
|
1001 |
+
|
1002 |
+
$order->add_order_note( $note_message );
|
1003 |
+
Mollie_WC_Plugin::debug( $note_message );
|
1004 |
+
|
1005 |
+
do_action( Mollie_WC_Plugin::PLUGIN_ID . '_refund_created', $refund, $order );
|
1006 |
+
|
1007 |
+
return true;
|
1008 |
+
|
1009 |
+
}
|
1010 |
+
|
1011 |
+
return false;
|
1012 |
+
}
|
1013 |
|
1014 |
}
|
@@ -92,9 +92,9 @@ class Mollie_WC_Payment_Payment extends Mollie_WC_Payment_Object {
|
|
92 |
'method' => $mollie_method,
|
93 |
'issuer' => $selected_issuer,
|
94 |
'locale' => $payment_locale,
|
95 |
-
'metadata'
|
96 |
-
'order_id'
|
97 |
-
),
|
98 |
);
|
99 |
|
100 |
// Add sequenceType for subscriptions first payments
|
@@ -365,31 +365,60 @@ class Mollie_WC_Payment_Payment extends Mollie_WC_Payment_Object {
|
|
365 |
$order_id = $order->get_id();
|
366 |
}
|
367 |
|
|
|
|
|
|
|
368 |
// New order status
|
369 |
$new_order_status = Mollie_WC_Gateway_Abstract::STATUS_FAILED;
|
370 |
|
371 |
// Overwrite plugin-wide
|
372 |
-
$new_order_status = apply_filters( Mollie_WC_Plugin::PLUGIN_ID . '
|
373 |
|
374 |
// Overwrite gateway-wide
|
375 |
-
$new_order_status = apply_filters( Mollie_WC_Plugin::PLUGIN_ID . '
|
|
|
|
|
376 |
|
|
|
|
|
377 |
// Update order status for order with failed payment, don't restore stock
|
|
|
378 |
|
379 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
380 |
|
381 |
-
|
382 |
-
|
383 |
-
|
384 |
-
|
385 |
-
|
386 |
-
|
387 |
-
|
388 |
-
|
389 |
-
|
390 |
-
|
391 |
-
|
392 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
393 |
}
|
394 |
|
395 |
Mollie_WC_Plugin::debug( __METHOD__ . ' called for order ' . $order_id . ' and payment ' . $payment->id . ', regular payment failed.' );
|
@@ -475,31 +504,43 @@ class Mollie_WC_Payment_Payment extends Mollie_WC_Payment_Object {
|
|
475 |
}
|
476 |
|
477 |
/**
|
478 |
-
* Process a
|
|
|
|
|
479 |
* @param int $order_id
|
480 |
-
* @param
|
|
|
481 |
* @param string $reason
|
482 |
-
*
|
483 |
-
* @
|
484 |
*/
|
485 |
-
public function refund( $order, $order_id, $amount = null, $reason = '' ) {
|
|
|
|
|
486 |
|
487 |
try {
|
|
|
488 |
$payment_object = Mollie_WC_Plugin::getPaymentObject()->getActiveMolliePayment( $order_id );
|
489 |
|
490 |
if ( ! $payment_object ) {
|
491 |
-
Mollie_WC_Plugin::debug( __METHOD__ . ' - Could not find active Mollie payment for order ' . $order_id );
|
492 |
|
493 |
-
|
|
|
|
|
|
|
|
|
494 |
}
|
495 |
|
496 |
if ( ! $payment_object->isPaid() ) {
|
497 |
-
Mollie_WC_Plugin::debug( __METHOD__ . ' - Can not refund the unpaid payment ' . $payment_object->id . ' for order ' . $order_id );
|
498 |
|
499 |
-
|
|
|
|
|
|
|
|
|
500 |
}
|
501 |
|
502 |
-
Mollie_WC_Plugin::debug( __METHOD__ . ' - Create refund - payment: ' . $payment_object->id . ', order: ' . $order_id . ', amount: ' . Mollie_WC_Plugin::getDataHelper()->getOrderCurrency( $order ) . $amount . ( ! empty( $reason ) ? ', reason: ' . $reason : '' ) );
|
503 |
|
504 |
do_action( Mollie_WC_Plugin::PLUGIN_ID . '_create_refund', $payment_object, $order );
|
505 |
|
92 |
'method' => $mollie_method,
|
93 |
'issuer' => $selected_issuer,
|
94 |
'locale' => $payment_locale,
|
95 |
+
'metadata' => apply_filters( Mollie_WC_Plugin::PLUGIN_ID . '_payment_object_metadata', array (
|
96 |
+
'order_id' => $order->get_id(),
|
97 |
+
) ),
|
98 |
);
|
99 |
|
100 |
// Add sequenceType for subscriptions first payments
|
365 |
$order_id = $order->get_id();
|
366 |
}
|
367 |
|
368 |
+
// Add messages to log
|
369 |
+
Mollie_WC_Plugin::debug( __METHOD__ . ' called for order ' . $order_id );
|
370 |
+
|
371 |
// New order status
|
372 |
$new_order_status = Mollie_WC_Gateway_Abstract::STATUS_FAILED;
|
373 |
|
374 |
// Overwrite plugin-wide
|
375 |
+
$new_order_status = apply_filters( Mollie_WC_Plugin::PLUGIN_ID . '_order_status_failed', $new_order_status );
|
376 |
|
377 |
// Overwrite gateway-wide
|
378 |
+
$new_order_status = apply_filters( Mollie_WC_Plugin::PLUGIN_ID . '_order_status_failed_' . $this->id, $new_order_status );
|
379 |
+
|
380 |
+
$gateway = Mollie_WC_Plugin::getDataHelper()->getWcPaymentGatewayByOrder( $order );
|
381 |
|
382 |
+
|
383 |
+
// If WooCommerce Subscriptions is installed, process this failure as a subscription, otherwise as a regular order
|
384 |
// Update order status for order with failed payment, don't restore stock
|
385 |
+
if ( function_exists( 'wcs_order_contains_renewal' ) && wcs_order_contains_renewal( $order_id ) ) {
|
386 |
|
387 |
+
if ( $gateway || ( $gateway instanceof Mollie_WC_Gateway_Abstract ) ) {
|
388 |
+
$gateway->updateOrderStatus(
|
389 |
+
$order,
|
390 |
+
$new_order_status,
|
391 |
+
sprintf(
|
392 |
+
/* translators: Placeholder 1: payment method title, placeholder 2: payment ID */
|
393 |
+
__( '%s renewal payment failed via Mollie (%s). You will need to manually review the payment and adjust product stocks if you use them.', 'mollie-payments-for-woocommerce' ),
|
394 |
+
$payment_method_title,
|
395 |
+
$payment->id . ( $payment->mode == 'test' ? ( ' - ' . __( 'test mode', 'mollie-payments-for-woocommerce' ) ) : '' )
|
396 |
+
),
|
397 |
+
$restore_stock = false
|
398 |
+
);
|
399 |
+
}
|
400 |
|
401 |
+
Mollie_WC_Plugin::debug( __METHOD__ . ' called for order ' . $order_id . ' and payment ' . $payment->id . ', renewal order payment failed, order set to ' . $new_order_status . ' for shop-owner review.' );
|
402 |
+
|
403 |
+
// Send a "Failed order" email to notify the admin
|
404 |
+
$emails = WC()->mailer()->get_emails();
|
405 |
+
if ( ! empty( $emails ) && ! empty( $order_id ) && ! empty( $emails['WC_Email_Failed_Order'] ) ) {
|
406 |
+
$emails['WC_Email_Failed_Order']->trigger( $order_id );
|
407 |
+
}
|
408 |
+
} else {
|
409 |
+
|
410 |
+
if ( $gateway || ( $gateway instanceof Mollie_WC_Gateway_Abstract ) ) {
|
411 |
+
$gateway->updateOrderStatus(
|
412 |
+
$order,
|
413 |
+
$new_order_status,
|
414 |
+
sprintf(
|
415 |
+
/* translators: Placeholder 1: payment method title, placeholder 2: payment ID */
|
416 |
+
__( '%s payment failed via Mollie (%s).', 'mollie-payments-for-woocommerce' ),
|
417 |
+
$payment_method_title,
|
418 |
+
$payment->id . ( $payment->mode == 'test' ? ( ' - ' . __( 'test mode', 'mollie-payments-for-woocommerce' ) ) : '' )
|
419 |
+
)
|
420 |
+
);
|
421 |
+
}
|
422 |
}
|
423 |
|
424 |
Mollie_WC_Plugin::debug( __METHOD__ . ' called for order ' . $order_id . ' and payment ' . $payment->id . ', regular payment failed.' );
|
504 |
}
|
505 |
|
506 |
/**
|
507 |
+
* Process a payment object refund
|
508 |
+
*
|
509 |
+
* @param object $order
|
510 |
* @param int $order_id
|
511 |
+
* @param object $payment_object
|
512 |
+
* @param null $amount
|
513 |
* @param string $reason
|
514 |
+
*
|
515 |
+
* @return bool|\WP_Error
|
516 |
*/
|
517 |
+
public function refund( WC_Order $order, $order_id, $payment_object, $amount = null, $reason = '' ) {
|
518 |
+
|
519 |
+
Mollie_WC_Plugin::debug( __METHOD__ . ' - ' . $order_id . ' - Try to process refunds for individual order line(s).' );
|
520 |
|
521 |
try {
|
522 |
+
|
523 |
$payment_object = Mollie_WC_Plugin::getPaymentObject()->getActiveMolliePayment( $order_id );
|
524 |
|
525 |
if ( ! $payment_object ) {
|
|
|
526 |
|
527 |
+
$error_message = "Could not find active Mollie payment for WooCommerce order ' . $order_id";
|
528 |
+
|
529 |
+
Mollie_WC_Plugin::debug( __METHOD__ . ' - ' . $error_message );
|
530 |
+
|
531 |
+
return new WP_Error( '1', $error_message );
|
532 |
}
|
533 |
|
534 |
if ( ! $payment_object->isPaid() ) {
|
|
|
535 |
|
536 |
+
$error_message = "Can not refund payment $payment_object->id for WooCommerce order $order_id as it is not paid.";
|
537 |
+
|
538 |
+
Mollie_WC_Plugin::debug( __METHOD__ . ' - ' . $error_message );
|
539 |
+
|
540 |
+
return new WP_Error( '1', $error_message );
|
541 |
}
|
542 |
|
543 |
+
Mollie_WC_Plugin::debug( __METHOD__ . ' - Create refund - payment object: ' . $payment_object->id . ', WooCommerce order: ' . $order_id . ', amount: ' . Mollie_WC_Plugin::getDataHelper()->getOrderCurrency( $order ) . $amount . ( ! empty( $reason ) ? ', reason: ' . $reason : '' ) );
|
544 |
|
545 |
do_action( Mollie_WC_Plugin::PLUGIN_ID . '_create_refund', $payment_object, $order );
|
546 |
|
@@ -7,7 +7,7 @@ class Mollie_WC_Plugin
|
|
7 |
{
|
8 |
const PLUGIN_ID = 'mollie-payments-for-woocommerce';
|
9 |
const PLUGIN_TITLE = 'Mollie Payments for WooCommerce';
|
10 |
-
const PLUGIN_VERSION = '5.0
|
11 |
|
12 |
const DB_VERSION = '1.0';
|
13 |
const DB_VERSION_PARAM_NAME = 'mollie-db-version';
|
@@ -606,16 +606,14 @@ class Mollie_WC_Plugin
|
|
606 |
|
607 |
$order = Mollie_WC_Plugin::getDataHelper()->getWcOrder( $order_id );
|
608 |
|
609 |
-
//
|
610 |
-
$
|
611 |
-
|
612 |
-
|
613 |
-
);
|
614 |
-
|
615 |
-
// TODO David: Check minimal WooCommerce or Mollie status
|
616 |
|
617 |
-
//
|
618 |
-
|
|
|
619 |
return;
|
620 |
}
|
621 |
|
@@ -629,8 +627,8 @@ class Mollie_WC_Plugin
|
|
629 |
}
|
630 |
|
631 |
if ( $mollie_order_id == false ) {
|
632 |
-
$order->add_order_note( 'Order contains
|
633 |
-
Mollie_WC_Plugin::debug( __METHOD__ . ' - ' . $order_id . ' - Order contains
|
634 |
|
635 |
return;
|
636 |
}
|
@@ -694,16 +692,14 @@ class Mollie_WC_Plugin
|
|
694 |
|
695 |
$order = Mollie_WC_Plugin::getDataHelper()->getWcOrder( $order_id );
|
696 |
|
697 |
-
//
|
698 |
-
$
|
699 |
-
|
700 |
-
|
701 |
-
);
|
702 |
-
|
703 |
-
// TODO David: Check minimal WooCommerce or Mollie status
|
704 |
|
705 |
-
//
|
706 |
-
|
|
|
707 |
return;
|
708 |
}
|
709 |
|
@@ -717,8 +713,8 @@ class Mollie_WC_Plugin
|
|
717 |
}
|
718 |
|
719 |
if ( $mollie_order_id == false ) {
|
720 |
-
$order->add_order_note( 'Order contains
|
721 |
-
Mollie_WC_Plugin::debug( __METHOD__ . ' - ' . $order_id . ' - Order contains
|
722 |
|
723 |
return;
|
724 |
}
|
7 |
{
|
8 |
const PLUGIN_ID = 'mollie-payments-for-woocommerce';
|
9 |
const PLUGIN_TITLE = 'Mollie Payments for WooCommerce';
|
10 |
+
const PLUGIN_VERSION = '5.1.0';
|
11 |
|
12 |
const DB_VERSION = '1.0';
|
13 |
const DB_VERSION_PARAM_NAME = 'mollie-db-version';
|
606 |
|
607 |
$order = Mollie_WC_Plugin::getDataHelper()->getWcOrder( $order_id );
|
608 |
|
609 |
+
// Does WooCommerce order contain a Mollie payment?
|
610 |
+
if ( strstr( $order->get_payment_method(), 'mollie_wc_gateway_') == FALSE ) {
|
611 |
+
return;
|
612 |
+
}
|
|
|
|
|
|
|
613 |
|
614 |
+
// To disable automatic shipping and capturing of the Mollie order when a WooCommerce order status is updated to completed,
|
615 |
+
// store an option 'mollie-payments-for-woocommerce_disableShipOrderAtMollie' with value 1
|
616 |
+
if ( get_option(Mollie_WC_Plugin::PLUGIN_ID . '_' . 'disableShipOrderAtMollie', '0' ) == '1' ) {
|
617 |
return;
|
618 |
}
|
619 |
|
627 |
}
|
628 |
|
629 |
if ( $mollie_order_id == false ) {
|
630 |
+
$order->add_order_note( 'Order contains Mollie payment method, but not a valid Mollie Order ID. Processing capture canceled.' );
|
631 |
+
Mollie_WC_Plugin::debug( __METHOD__ . ' - ' . $order_id . ' - Order contains Mollie payment method, but not a valid Mollie Order ID. Processing capture cancelled.' );
|
632 |
|
633 |
return;
|
634 |
}
|
692 |
|
693 |
$order = Mollie_WC_Plugin::getDataHelper()->getWcOrder( $order_id );
|
694 |
|
695 |
+
// Does WooCommerce order contain a Mollie payment?
|
696 |
+
if ( strstr( $order->get_payment_method(), 'mollie_wc_gateway_') == FALSE ) {
|
697 |
+
return;
|
698 |
+
}
|
|
|
|
|
|
|
699 |
|
700 |
+
// To disable automatic canceling of the Mollie order when a WooCommerce order status is updated to canceled,
|
701 |
+
// store an option 'mollie-payments-for-woocommerce_disableCancelOrderAtMollie' with value 1
|
702 |
+
if ( get_option(Mollie_WC_Plugin::PLUGIN_ID . '_' . 'disableCancelOrderAtMollie', '0' ) == '1' ) {
|
703 |
return;
|
704 |
}
|
705 |
|
713 |
}
|
714 |
|
715 |
if ( $mollie_order_id == false ) {
|
716 |
+
$order->add_order_note( 'Order contains Mollie payment method, but not a valid Mollie Order ID. Canceling order failed.' );
|
717 |
+
Mollie_WC_Plugin::debug( __METHOD__ . ' - ' . $order_id . ' - Order contains Mollie payment method, but not a valid Mollie Order ID. Canceling order failed.' );
|
718 |
|
719 |
return;
|
720 |
}
|
@@ -3,11 +3,11 @@
|
|
3 |
* Plugin Name: Mollie Payments for WooCommerce
|
4 |
* Plugin URI: https://www.mollie.com
|
5 |
* Description: Accept payments in WooCommerce with the official Mollie plugin
|
6 |
-
* Version: 5.0
|
7 |
* Author: Mollie
|
8 |
* Author URI: https://www.mollie.com
|
9 |
* Requires at least: 3.8
|
10 |
-
* Tested up to:
|
11 |
* Text Domain: mollie-payments-for-woocommerce
|
12 |
* Domain Path: /i18n/languages/
|
13 |
* License: GPLv2 or later
|
@@ -34,6 +34,17 @@ if ( ! defined( 'M4W_PLUGIN_DIR' ) ) {
|
|
34 |
define( 'M4W_PLUGIN_DIR', plugin_dir_path( __FILE__ ) );
|
35 |
}
|
36 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
37 |
|
38 |
/**
|
39 |
* Pro-actively check and communicate PHP version incompatibility for Mollie Payments for WooCommerce 4.0
|
@@ -101,6 +112,25 @@ function mollie_wc_plugin_activation_hook ()
|
|
101 |
|
102 |
register_activation_hook(__FILE__, 'mollie_wc_plugin_activation_hook');
|
103 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
104 |
function mollie_wc_plugin_inactive_php() {
|
105 |
|
106 |
$nextScheduledTime = wp_next_scheduled( 'pending_payment_confirmation_check' );
|
3 |
* Plugin Name: Mollie Payments for WooCommerce
|
4 |
* Plugin URI: https://www.mollie.com
|
5 |
* Description: Accept payments in WooCommerce with the official Mollie plugin
|
6 |
+
* Version: 5.1.0
|
7 |
* Author: Mollie
|
8 |
* Author URI: https://www.mollie.com
|
9 |
* Requires at least: 3.8
|
10 |
+
* Tested up to: 5.0
|
11 |
* Text Domain: mollie-payments-for-woocommerce
|
12 |
* Domain Path: /i18n/languages/
|
13 |
* License: GPLv2 or later
|
34 |
define( 'M4W_PLUGIN_DIR', plugin_dir_path( __FILE__ ) );
|
35 |
}
|
36 |
|
37 |
+
/**
|
38 |
+
* Pro-actively check for required PHP JSON extension
|
39 |
+
*/
|
40 |
+
function mollie_wc_check_json_extension() {
|
41 |
+
if ( function_exists( 'extension_loaded' ) && ! extension_loaded( 'json' ) ) {
|
42 |
+
remove_action( 'init', 'mollie_wc_plugin_init' );
|
43 |
+
add_action( 'admin_notices', 'mollie_wc_plugin_inactive_json_extension' );
|
44 |
+
return;
|
45 |
+
}
|
46 |
+
}
|
47 |
+
add_action( 'plugins_loaded', 'mollie_wc_check_json_extension' );
|
48 |
|
49 |
/**
|
50 |
* Pro-actively check and communicate PHP version incompatibility for Mollie Payments for WooCommerce 4.0
|
112 |
|
113 |
register_activation_hook(__FILE__, 'mollie_wc_plugin_activation_hook');
|
114 |
|
115 |
+
function mollie_wc_plugin_inactive_json_extension() {
|
116 |
+
|
117 |
+
$nextScheduledTime = wp_next_scheduled( 'pending_payment_confirmation_check' );
|
118 |
+
if ( $nextScheduledTime ) {
|
119 |
+
wp_unschedule_event( $nextScheduledTime, 'pending_payment_confirmation_check' );
|
120 |
+
}
|
121 |
+
|
122 |
+
if ( ! is_admin() ) {
|
123 |
+
return false;
|
124 |
+
}
|
125 |
+
|
126 |
+
echo '<div class="error"><p>';
|
127 |
+
echo esc_html__( 'Mollie Payments for WooCommerce requires the JSON extension for PHP. Enable it in your server or ask your webhoster to enable it for you.', 'mollie-payments-for-woocommerce' );
|
128 |
+
echo '</p></div>';
|
129 |
+
|
130 |
+
return false;
|
131 |
+
|
132 |
+
}
|
133 |
+
|
134 |
function mollie_wc_plugin_inactive_php() {
|
135 |
|
136 |
$nextScheduledTime = wp_next_scheduled( 'pending_payment_confirmation_check' );
|
@@ -1,9 +1,9 @@
|
|
1 |
=== Mollie Payments for WooCommerce ===
|
2 |
Contributors: daanvm, davdebcom, l.vangunst, ndijkstra, robin-mollie
|
3 |
-
Tags: mollie, payments,
|
4 |
Requires at least: 3.8
|
5 |
-
Tested up to: 5.
|
6 |
-
Stable tag: 5.0
|
7 |
Requires PHP: 5.6
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
@@ -181,6 +181,28 @@ Automatic updates should work like a charm; as always though, ensure you backup
|
|
181 |
|
182 |
== Changelog ==
|
183 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
184 |
= 5.0.7 - 04-12-2018 =
|
185 |
|
186 |
* Fix - Bancontact payments don't return a name as part of IBAN details (in Mollie API), so in that case use the WooCommerce name
|
1 |
=== Mollie Payments for WooCommerce ===
|
2 |
Contributors: daanvm, davdebcom, l.vangunst, ndijkstra, robin-mollie
|
3 |
+
Tags: mollie, payments, payment gateway, woocommerce, credit card
|
4 |
Requires at least: 3.8
|
5 |
+
Tested up to: 5.1
|
6 |
+
Stable tag: 5.1.0
|
7 |
Requires PHP: 5.6
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
181 |
|
182 |
== Changelog ==
|
183 |
|
184 |
+
= 5.1.0 - 19-02-2019 =
|
185 |
+
|
186 |
+
* New - Enable 'refunds' for Klarna and SEPA Direct Debit payments
|
187 |
+
* New - Support refunds per order line for payments via the Orders API (used to be only amount refunds)
|
188 |
+
* New - Updated "Tested up to" to WordPress 5.1
|
189 |
+
* New - Automatically updating Mollie Orders from WooCommerce to "Ship and Capture" and "Cancel" now supports all payments via Orders API, not just Klarna payments
|
190 |
+
* New - Add support for refunding full Mollie Orders when refunding the full WooCommerce order (Orders API)
|
191 |
+
* New - Update order lines processing to use Order instead of Cart data (for Orders API and Klarna)
|
192 |
+
* New - Orders API/Klarna: also send WooCommerce order item id to Mollie as metadata, to allow for individual order line refunding
|
193 |
+
* New - Pro-actively check for required PHP JSON extension
|
194 |
+
* New - Added filter so merchants can manipulate the payment object metadata, default filter id mollie-payments-for-woocommerce_payment_object_metadata, also see https://www.mollie/WooCommerce/wiki/Helpful-snippets#add-custom-information-to-mollie-payment-object-metadata
|
195 |
+
* New - Add billing country to payment methods cache in checkout, for when customers change their country in checkout
|
196 |
+
* New - Allow developers to hook into the subscription renewal payment before it's processed with mollie-payments-for-woocommerce_before_renewal_payment_created
|
197 |
+
* New - Set Payment screen language setting to wp_locale by default
|
198 |
+
|
199 |
+
* Fix - Temporary fix for PHP 7.3 with sporadic caching issues of methods, better fix is now being tested
|
200 |
+
* Fix - Check if WooCommerce Subscriptions Failed Recurring Payment Retry System is in-use, if it is, don't update subscription status
|
201 |
+
* Fix - Polylang: another fix for edge-case with URL parameter, please test and provide feedback is you use Polylang!
|
202 |
+
* Fix - Too many customers redirected to "Pay now" after payment, add isAuthorized to status check in getReturnRedirectUrlForOrder()
|
203 |
+
* Fix - Add extra warning to order note for orders that are completed at Mollie (not WooCommerce)
|
204 |
+
* Fix - Improve onWebhookFailed for WooCommerce Subscriptions so failed payments at Mollie are failed orders at WooCommerce
|
205 |
+
|
206 |
= 5.0.7 - 04-12-2018 =
|
207 |
|
208 |
* Fix - Bancontact payments don't return a name as part of IBAN details (in Mollie API), so in that case use the WooCommerce name
|