We will be off from 27/1 (Monday) to 31/1 (Friday) (GMT +7) for our Tet Holiday (Lunar New Year) in our country

Commit 6da72c56 authored by attilak's avatar attilak

Use /skipDetails.shtml for openinvoice and molpay only otherwise use

/details.shtml
parent 43e5d3e0
......@@ -130,7 +130,16 @@ class Redirect extends \Magento\Payment\Block\Form
if ($this->getPaymentMethodSelectionOnAdyen()) {
$url = 'https://test.adyen.com/hpp/select.shtml';
} else {
if ($this->_adyenHelper->isPaymentMethodOpenInvoiceMethod(
$this->_order->getPayment()->getAdditionalInformation('brand_code')
) || $this->_adyenHelper->isPaymentMethodMolpayMethod(
$this->_order->getPayment()->getAdditionalInformation('brand_code')
)
) {
$url = "https://test.adyen.com/hpp/skipDetails.shtml";
} else {
$url = "https://test.adyen.com/hpp/details.shtml";
}
}
}
break;
......@@ -141,7 +150,16 @@ class Redirect extends \Magento\Payment\Block\Form
if ($this->getPaymentMethodSelectionOnAdyen()) {
$url = 'https://live.adyen.com/hpp/select.shtml';
} else {
if ($this->_adyenHelper->isPaymentMethodOpenInvoiceMethod(
$this->_order->getPayment()->getAdditionalInformation('brand_code')
) || $this->_adyenHelper->isPaymentMethodMolpayMethod(
$this->_order->getPayment()->getAdditionalInformation('brand_code')
)
) {
$url = "https://live.adyen.com/hpp/skipDetails.shtml";
} else {
$url = "https://live.adyen.com/hpp/details.shtml";
}
}
}
break;
......
......@@ -928,6 +928,19 @@ class Data extends AbstractHelper
return false;
}
/**
* @param $paymentMethod
* @return bool
*/
public function isPaymentMethodMolpayMethod($paymentMethod)
{
if (strpos($paymentMethod, 'molpay_ebanking_MY') !== false) {
return true;
}
return false;
}
public function getRatePayId()
{
return $this->getAdyenHppConfigData("ratepay_id");
......
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