Skip to content

Commit

Permalink
Updated translations
Browse files Browse the repository at this point in the history
  • Loading branch information
woutse committed Feb 16, 2021
1 parent ed43647 commit 96565db
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions Model/Paymentmethod/PaymentMethod.php
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ public function getCompany()
return $this->_scopeConfig->getValue('payment/' . $this->_code . '/showforcompany', 'store');
}


public function isCurrentIpValid()
{
return true;
Expand All @@ -146,7 +146,7 @@ public function isCurrentAgentValid()
{
return true;
}

public function genderConversion($gender)
{
switch ($gender) {
Expand Down Expand Up @@ -192,6 +192,7 @@ public function refund(InfoInterface $payment, $amount)
$this->paynlConfig->configureSDK();

$transactionId = $payment->getParentTransactionId();
$transactionId = str_replace('-capture', '', $transactionId);

try {
Transaction::refund($transactionId, $amount);
Expand All @@ -203,7 +204,7 @@ public function refund(InfoInterface $payment, $amount)
if (substr($message, 0, 19) == '403 - access denied') {
$message = 'PAY. could not authorize this refund. Errorcode: PAY-MAGENTO2-001. See for more information ' . $docsLink;
} else {
$message = 'PAY. could not process this refund (' . $message . '). Errorcode: PAY-MAGENTO2-002. More info: ' . $docsLink;
$message = 'PAY. could not process this refund (' . $message . '). Errorcode: PAY-MAGENTO2-002. Transaction: '.$transactionId.'. More info: ' . $docsLink;
}

throw new \Magento\Framework\Exception\LocalizedException(__($message));
Expand Down Expand Up @@ -306,7 +307,7 @@ protected function doStartTransaction(Order $order)
if (isset($additionalData['dob'])) {
$enduser['dob'] = $additionalData['dob'];
}

if (isset($additionalData['gender'])) {
$enduser['gender'] = $additionalData['gender'];
}
Expand Down Expand Up @@ -447,7 +448,7 @@ protected function doStartTransaction(Order $order)
// Gift Wrapping
$gwCost = $order->getGwPriceInclTax();
$gwTax = $order->getGwTaxAmount();

if ($this->paynlConfig->isAlwaysBaseCurrency()) {
$gwCost = $order->getGwBasePriceInclTax();
$gwTax = $order->getGwBaseTaxAmount();
Expand Down

0 comments on commit 96565db

Please sign in to comment.