Skip to content

Commit f8cbcc5

Browse files
authored
Merge pull request #341 from mollie/13.4.1
#### Changes in release 13.4.1 + Fixed Klarna and Paypal failed payment issue + Fixed double order confirmation issue + Other bugfix and improvements
2 parents 8c06495 + 20c432e commit f8cbcc5

File tree

9 files changed

+778
-862
lines changed

9 files changed

+778
-862
lines changed

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,11 @@
22

33
# Changelog #
44

5+
#### Changes in release 13.4.1
6+
+ Fixed Klarna and Paypal failed payment issue
7+
+ Fixed double order confirmation issue
8+
+ Other bugfix and improvements
9+
510
#### Changes in release 13.4.0
611
+ Removed SOFORT and Paysafecard payment methods
712
+ Added Satispay method

Opencart 1.5 - 3.x/catalog/controller/payment/mollie/base.php

Lines changed: 373 additions & 426 deletions
Large diffs are not rendered by default.

Opencart 1.5 - 3.x/catalog/model/payment/mollie/base.php

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -322,7 +322,7 @@ public function setPayment($order_id, $mollie_order_id, $method)
322322
}
323323
$bank_account = isset($this->session->data['mollie_issuer']) ? $this->session->data['mollie_issuer'] : NULL;
324324
if (!empty($order_id) && !empty($mollie_order_id) && !empty($method)) {
325-
$this->db->query("INSERT INTO `" . DB_PREFIX . "mollie_payments` SET `order_id` = '" . (int)$order_id . "', `mollie_order_id` = '" . $this->db->escape($mollie_order_id) . "', `method` = '" . $this->db->escape($method) . "', `bank_account` = '" . $this->db->escape($bank_account) . "', `payment_attempt` = '" . (int)$payment_attempt . "', date_modified = NOW() ON DUPLICATE KEY UPDATE `order_id` = '" . (int)$order_id . "'");
325+
$this->db->query("INSERT INTO `" . DB_PREFIX . "mollie_payments` SET `order_id` = '" . (int)$order_id . "', `mollie_order_id` = '" . $this->db->escape($mollie_order_id) . "', `method` = '" . $this->db->escape($method) . "', `bank_account` = '" . $this->db->escape($bank_account) . "', `payment_attempt` = '" . (int)$payment_attempt . "', `callback` = '0', date_modified = NOW() ON DUPLICATE KEY UPDATE `order_id` = '" . (int)$order_id . "'");
326326

327327
if ($this->db->countAffected() > 0) {
328328
return TRUE;
@@ -341,7 +341,7 @@ public function setPaymentForPaymentAPI($order_id, $mollie_payment_id, $method)
341341
}
342342
$bank_account = isset($this->session->data['mollie_issuer']) ? $this->session->data['mollie_issuer'] : NULL;
343343
if (!empty($order_id) && !empty($mollie_payment_id) && !empty($method)) {
344-
$this->db->query("INSERT INTO `" . DB_PREFIX . "mollie_payments` SET `order_id` = '" . (int)$order_id . "', `transaction_id` = '" . $this->db->escape($mollie_payment_id) . "', `method` = '" . $this->db->escape($method) . "', `bank_account` = '" . $this->db->escape($bank_account) . "', `payment_attempt` = '" . (int)$payment_attempt . "', date_modified = NOW() ON DUPLICATE KEY UPDATE `order_id` = '" . (int)$order_id . "'");
344+
$this->db->query("INSERT INTO `" . DB_PREFIX . "mollie_payments` SET `order_id` = '" . (int)$order_id . "', `transaction_id` = '" . $this->db->escape($mollie_payment_id) . "', `method` = '" . $this->db->escape($method) . "', `bank_account` = '" . $this->db->escape($bank_account) . "', `payment_attempt` = '" . (int)$payment_attempt . "', `callback` = '0', date_modified = NOW() ON DUPLICATE KEY UPDATE `order_id` = '" . (int)$order_id . "'");
345345

346346
if ($this->db->countAffected() > 0) {
347347
return TRUE;
@@ -437,6 +437,17 @@ public function getPayment($order_id)
437437
return FALSE;
438438
}
439439

440+
public function getPaymentById($id, $type)
441+
{
442+
if ($type == 'payment') {
443+
$results = $this->db->query("SELECT * FROM `" . DB_PREFIX . "mollie_payments` WHERE `transaction_id` = '" . $this->db->escape($id) . "'");
444+
} else {
445+
$results = $this->db->query("SELECT * FROM `" . DB_PREFIX . "mollie_payments` WHERE `mollie_order_id` = '" . $this->db->escape($id) . "'");
446+
}
447+
448+
return $results->row;
449+
}
450+
440451
public function cancelReturn($order_id, $mollie_order_id, $data) {
441452
if (!empty($order_id)) {
442453
if (!empty($mollie_order_id)) {

Opencart 1.5 - 3.x/system/library/mollie/helper.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
class MollieHelper {
66

7-
const PLUGIN_VERSION = "13.4.0";
7+
const PLUGIN_VERSION = "13.4.1";
88

99
const OUTH_URL = 'https://api.mollie.com/oauth2';
1010

Opencart 4.x/extension/mollie/catalog/controller/mollie.php

Lines changed: 368 additions & 424 deletions
Large diffs are not rendered by default.

Opencart 4.x/extension/mollie/catalog/model/mollie.php

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -352,7 +352,7 @@ public function setPayment($order_id, $mollie_order_id, $method)
352352
}
353353
$bank_account = isset($this->session->data['mollie_issuer']) ? $this->session->data['mollie_issuer'] : '';
354354
if (!empty($order_id) && !empty($mollie_order_id) && !empty($method)) {
355-
$this->db->query("INSERT INTO `" . DB_PREFIX . "mollie_payments` SET `order_id` = '" . (int)$order_id . "', `mollie_order_id` = '" . $this->db->escape($mollie_order_id) . "', `method` = '" . $this->db->escape($method) . "', `bank_account` = '" . $this->db->escape($bank_account) . "', `payment_attempt` = '" . (int)$payment_attempt . "', date_modified = NOW() ON DUPLICATE KEY UPDATE `order_id` = '" . (int)$order_id . "'");
355+
$this->db->query("INSERT INTO `" . DB_PREFIX . "mollie_payments` SET `order_id` = '" . (int)$order_id . "', `mollie_order_id` = '" . $this->db->escape($mollie_order_id) . "', `method` = '" . $this->db->escape($method) . "', `bank_account` = '" . $this->db->escape($bank_account) . "', `payment_attempt` = '" . (int)$payment_attempt . "', `callback` = '0', date_modified = NOW() ON DUPLICATE KEY UPDATE `order_id` = '" . (int)$order_id . "'");
356356

357357
if ($this->db->countAffected() > 0) {
358358
return TRUE;
@@ -371,7 +371,7 @@ public function setPaymentForPaymentAPI($order_id, $mollie_payment_id, $method)
371371
}
372372
$bank_account = isset($this->session->data['mollie_issuer']) ? $this->session->data['mollie_issuer'] : '';
373373
if (!empty($order_id) && !empty($mollie_payment_id) && !empty($method)) {
374-
$this->db->query("INSERT INTO `" . DB_PREFIX . "mollie_payments` SET `order_id` = '" . (int)$order_id . "', `transaction_id` = '" . $this->db->escape($mollie_payment_id) . "', `method` = '" . $this->db->escape($method) . "', `bank_account` = '" . $this->db->escape($bank_account) . "', `payment_attempt` = '" . (int)$payment_attempt . "', date_modified = NOW() ON DUPLICATE KEY UPDATE `order_id` = '" . (int)$order_id . "'");
374+
$this->db->query("INSERT INTO `" . DB_PREFIX . "mollie_payments` SET `order_id` = '" . (int)$order_id . "', `transaction_id` = '" . $this->db->escape($mollie_payment_id) . "', `method` = '" . $this->db->escape($method) . "', `bank_account` = '" . $this->db->escape($bank_account) . "', `payment_attempt` = '" . (int)$payment_attempt . "', `callback` = '0', date_modified = NOW() ON DUPLICATE KEY UPDATE `order_id` = '" . (int)$order_id . "'");
375375

376376
if ($this->db->countAffected() > 0) {
377377
return TRUE;
@@ -467,6 +467,17 @@ public function getPayment($order_id)
467467
return FALSE;
468468
}
469469

470+
public function getPaymentById($id, $type)
471+
{
472+
if ($type == 'payment') {
473+
$results = $this->db->query("SELECT * FROM `" . DB_PREFIX . "mollie_payments` WHERE `transaction_id` = '" . $this->db->escape($id) . "'");
474+
} else {
475+
$results = $this->db->query("SELECT * FROM `" . DB_PREFIX . "mollie_payments` WHERE `mollie_order_id` = '" . $this->db->escape($id) . "'");
476+
}
477+
478+
return $results->row;
479+
}
480+
470481
public function cancelReturn($order_id, $mollie_order_id, $data) {
471482
if (!empty($order_id)) {
472483
if (!empty($mollie_order_id)) {

Opencart 4.x/extension/mollie/system/library/mollie/helper.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
class MollieHelper {
66

7-
const PLUGIN_VERSION = "13.4.0";
7+
const PLUGIN_VERSION = "13.4.1";
88

99
const OUTH_URL = 'https://api.mollie.com/oauth2';
1010

Opencart 4.x/install.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "Mollie",
3-
"version": "13.4.0",
3+
"version": "13.4.1",
44
"author": "Qualityworks",
55
"link": "https://www.qualityworks.eu"
66
}

readme.md

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -31,13 +31,11 @@ them ready-made into your OpenCart webshop with this powerful plugin.
3131

3232
# Payment methods #
3333
- Credit Cards (Visa / MasterCard & American Express)
34-
- SOFORT banking
3534
- PayPal
3635
- SEPA Direct Debits
3736
- SEPA Bank Transfer
3837
- iDeal
3938
- Bancontact
40-
- Paysafecard
4139
- KBC/CBC Payment Button
4240
- Belfius Payment Button
4341
- CartaSi
@@ -60,6 +58,7 @@ them ready-made into your OpenCart webshop with this powerful plugin.
6058
- Alma
6159
- Riverty
6260
- Payconiq
61+
- Satispay
6362

6463
Please go to the signup page to create a new Mollie account and start receiving payments in
6564
a couple of minutes. Contact info@mollie.com if you have any questions or comments about
@@ -84,12 +83,10 @@ Contact Mollie: [www.mollie.com/nl/about](https://www.mollie.com/nl/about) — i
8483
+ [More info on iDEAL via Mollie](https://www.mollie.com/en/payments/ideal/)
8584
+ [More info on credit card via Mollie](https://www.mollie.com/en/payments/creditcard/)
8685
+ [More info on Bancontact via Mollie](https://www.mollie.com/en/payments/bancontact/)
87-
+ [More info on SOFORT Banking via Mollie](https://www.mollie.com/en/payments/sofort/)
8886
+ [More info on SEPA Bank transfer via Mollie](https://www.mollie.com/en/payments/banktransfer/)
8987
+ [More info on SEPA Direct debit via Mollie](https://www.mollie.com/en/payments/directdebit/)
9088
+ [More info on PayPal via Mollie](https://www.mollie.com/en/payments/paypal/)
9189
+ [More info on Belfius Direct Net via Mollie](https://www.mollie.com/en/payments/belfiusdirectnet/)
92-
+ [More info on paysafecard via Mollie](https://www.mollie.com/en/payments/paysafecard/)
9390
+ [More info on Giftcards via Mollie](https://www.mollie.com/en/payments/gift-cards/)
9491
+ [More info on EPS via Mollie](https://www.mollie.com/en/payments/eps/)
9592
+ [More info on Klarna Pay Later via Mollie](https://www.mollie.com/en/payments/klarna-pay-later/)
@@ -98,7 +95,7 @@ Contact Mollie: [www.mollie.com/nl/about](https://www.mollie.com/nl/about) — i
9895
+ [More info on Przelewy24 It via Mollie](https://www.mollie.com/en/payments/p24/)
9996
+ [More info on Apple Pay via Mollie](https://www.mollie.com/en/payments/apple-pay/)
10097
+ [More info on Vouchers via Mollie](https://www.mollie.com/en/payments/meal-eco-gift-vouchers/)
101-
+ [More info on IN3 via Mollie](https://www.mollie.com/en/payments/in3/)
98+
+ [More info on iDeal IN3 via Mollie](https://www.mollie.com/en/payments/ideal-in3/)
10299
+ [More info on MyBank via Mollie](https://www.mollie.com/en/payments/mybank/)
103100
+ [More info on Billie via Mollie](https://www.mollie.com/en/payments/billie/)
104101
+ [More info on Twint via Mollie](https://www.mollie.com/en/payments/twint/)
@@ -108,3 +105,4 @@ Contact Mollie: [www.mollie.com/nl/about](https://www.mollie.com/nl/about) — i
108105
+ [More info on Alma Pay via Mollie](https://www.mollie.com/en/payments/alma/)
109106
+ [More info on Riverty Pay via Mollie](https://www.mollie.com/en/payments/riverty/)
110107
+ [More info on Payconiq Pay via Mollie](https://www.mollie.com/en/payments/payconiq/)
108+
+ [More info on Satispay Pay via Mollie](https://www.mollie.com/en/payments/satispay/)

0 commit comments

Comments
 (0)