We will work on Apr 26th (Saturday) and will be off from Apr 30th (Wednesday) until May 2nd (Friday) for public holiday in our country

Commit 1580c22d authored by basm's avatar basm

PW-261 Removed the detailed refusal reasons

Additional information in Comments history
parent 331edac8
...@@ -211,23 +211,30 @@ class Result extends \Magento\Framework\App\Action\Action ...@@ -211,23 +211,30 @@ class Result extends \Magento\Framework\App\Action\Action
$type, $authResult, $pspReference, $paymentMethod $type, $authResult, $pspReference, $paymentMethod
); );
$history = $this->_orderHistoryFactory->create()
//->setStatus($status)
->setComment($comment)
->setEntityName('order')
->setOrder($order)
;
$history->save();
// needed because then we need to save $order objects // needed because then we need to save $order objects
$order->setAdyenResulturlEventCode($authResult); $order->setAdyenResulturlEventCode($authResult);
switch ($authResult) { switch ($authResult) {
case Notification::AUTHORISED: case Notification::AUTHORISED:
$result = true;
$this->_adyenLogger->addAdyenResult('Do nothing wait for the notification');
break;
case Notification::PENDING: case Notification::PENDING:
// do nothing wait for the notification // do nothing wait for the notification
$result = true; $result = true;
if (strpos($paymentMethod,"bankTransfer") !== false){
$comment .= "<br /><br />Waiting for the customer to transfer the money.";
}
elseif($paymentMethod == "sepadirectdebit"){
$comment .= "<br /><br />This request will be send to the bank at the end of the day.";
}
else {
$comment .= "<br /><br />The payment result is not confirmed (yet).
<br />Once the payment is authorised, the order status will be updated accordingly.
<br />If the order is stuck on this status, the payment can be seen as unsuccessful.
<br />The order can be automatically cancelled based on the OFFER_CLOSED notification. Please contact Adyen Support to enable this.";
}
$this->_adyenLogger->addAdyenResult('Do nothing wait for the notification'); $this->_adyenLogger->addAdyenResult('Do nothing wait for the notification');
break; break;
case Notification::CANCELLED: case Notification::CANCELLED:
...@@ -250,6 +257,15 @@ class Result extends \Magento\Framework\App\Action\Action ...@@ -250,6 +257,15 @@ class Result extends \Magento\Framework\App\Action\Action
break; break;
} }
$history = $this->_orderHistoryFactory->create()
//->setStatus($status)
->setComment($comment)
->setEntityName('order')
->setOrder($order)
;
$history->save();
return $result; return $result;
} }
......
...@@ -156,9 +156,10 @@ class Validate3d extends \Magento\Framework\App\Action\Action ...@@ -156,9 +156,10 @@ class Validate3d extends \Magento\Framework\App\Action\Action
} else { } else {
$this->_adyenLogger->addAdyenResult("Customer was redirected to bank for 3D-secure validation."); $this->_adyenLogger->addAdyenResult("Customer was redirected to bank for 3D-secure validation.");
$order->addStatusHistoryComment( $order->addStatusHistoryComment(
__('Customer was redirected to bank for 3D-secure validation.') __('Customer was redirected to bank for 3D-secure validation. Once the shopper authenticated, the order status will be updated accordingly.
)->save(); <br />Make sure that your notifications are being processed!
<br />If the order is stuck on this status, the shopper abandoned the session. The payment can be seen as unsuccessful.
<br />The order can be automatically cancelled based on the OFFER_CLOSED notification. Please contact Adyen Support to enable this.'))->save();
$this->_view->loadLayout(); $this->_view->loadLayout();
$this->_view->getLayout()->initMessages(); $this->_view->getLayout()->initMessages();
$this->_view->renderLayout(); $this->_view->renderLayout();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment