Commit 1d08c3c1 authored by alexandros's avatar alexandros Committed by attilak

Remove unused boleto methods and fix for single configured value

parent e07ffe3d
...@@ -54,28 +54,26 @@ class CheckoutDataBuilder implements BuilderInterface ...@@ -54,28 +54,26 @@ class CheckoutDataBuilder implements BuilderInterface
*/ */
protected $taxConfig; protected $taxConfig;
/**
/** * CheckoutDataBuilder constructor.
* CheckoutDataBuilder constructor. * @param \Adyen\Payment\Helper\Data $adyenHelper
* * @param \Magento\Store\Model\StoreManagerInterface $storeManager
* @param \Adyen\Payment\Helper\Data $adyenHelper * @param \Magento\Checkout\Model\Session $checkoutSession
* @param \Magento\Store\Model\StoreManagerInterface $storeManager * @param \Magento\Tax\Model\Config $taxConfig
* @param \Magento\Checkout\Model\Session $checkoutSession */
* @param \Magento\Tax\Model\Config $taxConfig
*/
public function __construct( public function __construct(
\Adyen\Payment\Helper\Data $adyenHelper, \Adyen\Payment\Helper\Data $adyenHelper,
\Magento\Store\Model\StoreManagerInterface $storeManager, \Magento\Store\Model\StoreManagerInterface $storeManager,
\Magento\Checkout\Model\Session $checkoutSession, \Magento\Checkout\Model\Session $checkoutSession,
\Magento\Tax\Model\Config $taxConfig \Magento\Tax\Model\Config $taxConfig
) )
{ {
$this->adyenHelper = $adyenHelper; $this->adyenHelper = $adyenHelper;
$this->storeManager = $storeManager; $this->storeManager = $storeManager;
$this->checkoutSession = $checkoutSession; $this->checkoutSession = $checkoutSession;
$this->quote = $checkoutSession->getQuote(); $this->quote = $checkoutSession->getQuote();
$this->taxConfig = $taxConfig; $this->taxConfig = $taxConfig;
} }
/** /**
* @param array $buildSubject * @param array $buildSubject
...@@ -156,7 +154,7 @@ class CheckoutDataBuilder implements BuilderInterface ...@@ -156,7 +154,7 @@ class CheckoutDataBuilder implements BuilderInterface
$request['shopperName']['lastName'] = $payment->getAdditionalInformation("lastName"); $request['shopperName']['lastName'] = $payment->getAdditionalInformation("lastName");
} }
if ($payment->getAdditionalInformation(AdyenBoletoDataAssignObserver::BOLETO_TYPE)) { if ($payment->getMethod() == \Adyen\Payment\Model\Ui\AdyenBoletoConfigProvider::CODE) {
$boletoTypes = $this->adyenHelper->getAdyenBoletoConfigData('boletotypes'); $boletoTypes = $this->adyenHelper->getAdyenBoletoConfigData('boletotypes');
$boletoTypes = explode(',', $boletoTypes); $boletoTypes = explode(',', $boletoTypes);
......
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