diff --git a/.github/workflows/templates/magento/configure-mollie.sh b/.github/workflows/templates/magento/configure-mollie.sh index 074ee7979cf..3cab4876433 100644 --- a/.github/workflows/templates/magento/configure-mollie.sh +++ b/.github/workflows/templates/magento/configure-mollie.sh @@ -21,6 +21,7 @@ bin/magento config:set payment/mollie_methods_kbc/active 1 & bin/magento config:set payment/mollie_methods_klarnasliceit/active 1 & bin/magento config:set payment/mollie_methods_paypal/active 1 & bin/magento config:set payment/mollie_methods_przelewy24/active 1 & +bin/magento config:set payment/mollie_methods_alma/active 1 & bin/magento config:set payment/mollie_methods_bancontact/active 1 & bin/magento config:set payment/mollie_methods_belfius/active 1 & bin/magento config:set payment/mollie_methods_eps/active 1 & diff --git a/Controller/ApplePay/ShippingMethods.php b/Controller/ApplePay/ShippingMethods.php index 12d66eb57f3..6f04908b837 100644 --- a/Controller/ApplePay/ShippingMethods.php +++ b/Controller/ApplePay/ShippingMethods.php @@ -16,6 +16,7 @@ use Magento\Quote\Api\ShippingMethodManagementInterface; use Magento\Quote\Model\Quote\Address; use Magento\Quote\Model\Quote\Address\Total as AddressTotal; +use Mollie\Payment\Service\Magento\ChangeShippingMethodForQuote; class ShippingMethods extends Action { @@ -23,34 +24,37 @@ class ShippingMethods extends Action * @var CartRepositoryInterface */ private $cartRepository; - /** * @var GuestCartRepositoryInterface */ private $guestCartRepository; - /** * @var ShippingMethodManagementInterface */ private $shippingMethodManagement; - /** * @var CheckoutSession */ private $checkoutSession; + /** + * @var ChangeShippingMethodForQuote + */ + private $changeShippingMethodForQuote; public function __construct( Context $context, CartRepositoryInterface $cartRepository, ShippingMethodManagementInterface $shippingMethodManagement, CheckoutSession $checkoutSession, - GuestCartRepositoryInterface $guestCartRepository + GuestCartRepositoryInterface $guestCartRepository, + ChangeShippingMethodForQuote $changeShippingMethodForQuote ) { parent::__construct($context); $this->shippingMethodManagement = $shippingMethodManagement; $this->guestCartRepository = $guestCartRepository; $this->cartRepository = $cartRepository; $this->checkoutSession = $checkoutSession; + $this->changeShippingMethodForQuote = $changeShippingMethodForQuote; } public function execute() @@ -66,8 +70,10 @@ public function execute() $address->setPostcode($this->getRequest()->getParam('postalCode')); if ($this->getRequest()->getParam('shippingMethod')) { - $address->setCollectShippingRates(true); - $address->setShippingMethod($this->getRequest()->getParam('shippingMethod')['identifier']); + $this->changeShippingMethodForQuote->execute( + $address, + $this->getRequest()->getParam('shippingMethod')['identifier'] + ); } $cart->setPaymentMethod('mollie_methods_applepay'); diff --git a/Helper/General.php b/Helper/General.php index 8be96d965d7..242f055885d 100755 --- a/Helper/General.php +++ b/Helper/General.php @@ -1,6 +1,6 @@ productRepository = $productRepository; + } + + public function execute(Observer $observer) + { + /** @var RequestInterface $request */ + $request = $observer->getData('request_model'); + + if ($request->has('item') && !$request->getPost('update_items') + ) { + $itemsChanged = false; + $items = $request->getPost('item'); + foreach ($items as $item => $requestData) { + if (!$this->productAllowsOneTimePurchase($item)) { + continue; + } + + $itemsChanged = true; + $items[$item]['purchase'] = 'onetime'; + } + + if ($itemsChanged) { + $request->setPostValue('item', $items); + } + } + } + + private function productAllowsOneTimePurchase(int $productId): bool + { + try { + $product = $this->productRepository->getById($productId); + } catch (NoSuchEntityException $e) { + return false; + } + + return !!$product->getData('mollie_subscription_product'); + } +} diff --git a/Plugin/CustomerBalance/Observer/PreventDoubleCreditRevert.php b/Plugin/CustomerBalance/Observer/PreventDoubleCreditRevert.php new file mode 100644 index 00000000000..cf0bb87cc58 --- /dev/null +++ b/Plugin/CustomerBalance/Observer/PreventDoubleCreditRevert.php @@ -0,0 +1,37 @@ +getData('order'); + if (!$order || + !$order instanceof OrderInterface || + !$order->getPayment() + ) { + return $proceed($observer); + } + + if ($observer->getEvent()->getName() == 'restore_quote' && + $this->isMollieOrder($order) + ) { + return $subject; + } + + return $proceed($observer); + } + + private function isMollieOrder(OrderInterface $order): bool + { + $payment = $order->getPayment(); + + return strstr($payment->getMethod(), 'mollie_methods_') !== false; + } +} diff --git a/Queue/Handler/TransactionProcessor.php b/Queue/Handler/TransactionProcessor.php index 9b86eac0e3d..77b0c40dddd 100644 --- a/Queue/Handler/TransactionProcessor.php +++ b/Queue/Handler/TransactionProcessor.php @@ -8,6 +8,8 @@ namespace Mollie\Payment\Queue\Handler; +use Magento\Framework\Phrase; +use Magento\Framework\Phrase\RendererInterface; use Magento\Sales\Api\OrderRepositoryInterface; use Mollie\Payment\Api\Data\TransactionToProcessInterface; use Mollie\Payment\Config; @@ -19,6 +21,10 @@ class TransactionProcessor * @var OrderRepositoryInterface */ private $orderRepository; + /** + * @var RendererInterface + */ + private $phraseRenderer; /** * @var Config */ @@ -30,12 +36,14 @@ class TransactionProcessor public function __construct( OrderRepositoryInterface $orderRepository, + RendererInterface $phraseRenderer, Config $config, Mollie $mollieModel ) { $this->orderRepository = $orderRepository; $this->config = $config; $this->mollieModel = $mollieModel; + $this->phraseRenderer = $phraseRenderer; } public function execute(TransactionToProcessInterface $data): void @@ -44,6 +52,9 @@ public function execute(TransactionToProcessInterface $data): void $order = $this->orderRepository->get($data->getOrderId()); $order->setMollieTransactionId($data->getTransactionId()); + // Make sure the translations are loaded + Phrase::setRenderer($this->phraseRenderer); + $this->mollieModel->processTransactionForOrder($order, $data->getType()); } catch (\Throwable $throwable) { $this->config->addToLog('error', [ diff --git a/README.md b/README.md index 0b39e3f986b..2d5732cbabe 100644 --- a/README.md +++ b/README.md @@ -27,6 +27,7 @@ Mollie requires no minimum costs, no fixed contracts, no hidden costs. At Mollie ## Supported Mollie Payment Methods - Apple Pay (direct) +- Alma - Bancontact - Bank transfer - Belfius Pay Button diff --git a/Service/Magento/ChangeShippingMethodForQuote.php b/Service/Magento/ChangeShippingMethodForQuote.php new file mode 100644 index 00000000000..1403b0e42e3 --- /dev/null +++ b/Service/Magento/ChangeShippingMethodForQuote.php @@ -0,0 +1,51 @@ +shippingInformationManagement = $shippingInformationManagement; + $this->shippingInformationFactory = $shippingInformationFactory; + } + + public function execute(AddressInterface $address, string $identifier): void + { + $address->setCollectShippingRates(true); + $address->setShippingMethod($identifier); + + [$carrierCode, $methodCode] = explode('_', $identifier); + $shippingInformation = $this->shippingInformationFactory->create([ + 'data' => [ + ShippingInformationInterface::SHIPPING_ADDRESS => $address, + ShippingInformationInterface::SHIPPING_CARRIER_CODE => $carrierCode, + ShippingInformationInterface::SHIPPING_METHOD_CODE => $methodCode, + ], + ]); + + $this->shippingInformationManagement->saveAddressInformation($address->getQuoteId(), $shippingInformation); + } +} diff --git a/Service/Mollie/GetMollieStatus.php b/Service/Mollie/GetMollieStatus.php index 0692d7a6d46..39371618e31 100644 --- a/Service/Mollie/GetMollieStatus.php +++ b/Service/Mollie/GetMollieStatus.php @@ -35,10 +35,17 @@ public function __construct( $this->getMollieStatusResultFactory = $getMollieStatusResultFactory; } - public function execute(int $orderId): GetMollieStatusResult + public function execute(int $orderId, string $transactionId = null): GetMollieStatusResult { $order = $this->orderRepository->get($orderId); - $transactionId = $order->getMollieTransactionId(); + if ($transactionId === null) { + $transactionId = $order->getMollieTransactionId(); + } + + if ($transactionId === null) { + throw new \Exception('No transaction ID found for order ' . $orderId); + } + $mollieApi = $this->mollieApiClient->loadByStore((int)$order->getStoreId()); if (substr($transactionId, 0, 4) == 'ord_') { diff --git a/Service/Mollie/GetMollieStatusResult.php b/Service/Mollie/GetMollieStatusResult.php index 333cb87fb67..c2031505b47 100644 --- a/Service/Mollie/GetMollieStatusResult.php +++ b/Service/Mollie/GetMollieStatusResult.php @@ -15,13 +15,13 @@ class GetMollieStatusResult */ private $status; /** - * @var string + * @var string|null */ private $method; public function __construct( string $status, - string $method + string $method = null ) { $method = str_replace('mollie_methods_', '', $method); @@ -34,7 +34,7 @@ public function getStatus(): string return $this->status; } - public function getMethod(): string + public function getMethod(): ?string { return $this->method; } diff --git a/Service/Mollie/PaymentMethods.php b/Service/Mollie/PaymentMethods.php index 14641a2a300..5cd713637e3 100644 --- a/Service/Mollie/PaymentMethods.php +++ b/Service/Mollie/PaymentMethods.php @@ -1,5 +1,5 @@ config->processTransactionsInTheQueue()) { $this->queueOrder($orderId, $transactionId, $type); - return $this->getMollieStatus->execute($orderId); + return $this->getMollieStatus->execute($orderId, $transactionId); } $order = $this->orderRepository->get($orderId); diff --git a/Service/Order/Lines/Generator/MagentoRewardPoints.php b/Service/Order/Lines/Generator/MagentoRewardPoints.php new file mode 100644 index 00000000000..66513849a96 --- /dev/null +++ b/Service/Order/Lines/Generator/MagentoRewardPoints.php @@ -0,0 +1,55 @@ +mollieHelper = $mollieHelper; + } + + public function process(OrderInterface $order, array $orderLines): array + { + $extensionAttributes = $order->getExtensionAttributes(); + + if (!method_exists($extensionAttributes, 'getRewardCurrencyAmount')) { + return $orderLines; + } + + $amount = $extensionAttributes->getRewardCurrencyAmount(); + if ($amount === null) { + return $orderLines; + } + + $forceBaseCurrency = (bool)$this->mollieHelper->useBaseCurrency($order->getStoreId()); + if ($forceBaseCurrency) { + $amount = $extensionAttributes->getBaseRewardCurrencyAmount(); + } + + $currency = $forceBaseCurrency ? $order->getBaseCurrencyCode() : $order->getOrderCurrencyCode(); + + $orderLines[] = [ + 'type' => 'surcharge', + 'name' => 'Reward Points', + 'quantity' => 1, + 'unitPrice' => $this->mollieHelper->getAmountArray($currency, -$amount), + 'totalAmount' => $this->mollieHelper->getAmountArray($currency, -$amount), + 'vatRate' => 0, + 'vatAmount' => $this->mollieHelper->getAmountArray($currency, 0.0), + ]; + + return $orderLines; + } +} diff --git a/Service/Order/Lines/Order.php b/Service/Order/Lines/Order.php index 592949fb22e..ec28e4646be 100644 --- a/Service/Order/Lines/Order.php +++ b/Service/Order/Lines/Order.php @@ -1,5 +1,5 @@ processors = $processors; } - /** - * @param array $orderLine - * @param OrderInterface $order - * @param OrderItemInterface|null $orderItem - * @return array - */ - public function process(array $orderLine, OrderInterface $order, OrderItemInterface $orderItem = null) + public function process(array $orderLine, OrderInterface $order, OrderItemInterface $orderItem = null): array { foreach ($this->processors as $processor) { $orderLine = $processor->process($orderLine, $order, $orderItem); @@ -37,4 +31,4 @@ public function process(array $orderLine, OrderInterface $order, OrderItemInterf return $orderLine; } -} \ No newline at end of file +} diff --git a/Test/End-2-end/cypress/e2e/magento/checkout.cy.js b/Test/End-2-end/cypress/e2e/magento/checkout.cy.js index 45ccc05e612..e6627a4d027 100644 --- a/Test/End-2-end/cypress/e2e/magento/checkout.cy.js +++ b/Test/End-2-end/cypress/e2e/magento/checkout.cy.js @@ -1,4 +1,9 @@ +/* + * Copyright Magmodules.eu. All rights reserved. + * See COPYING.txt for license details. + */ + import CheckoutPaymentPage from "Pages/frontend/CheckoutPaymentPage"; import VisitCheckoutPaymentCompositeAction from "CompositeActions/VisitCheckoutPaymentCompositeAction"; import MollieHostedPaymentPage from "Pages/mollie/MollieHostedPaymentPage"; @@ -23,6 +28,7 @@ describe('Checkout usage', () => { const availableMethods = Cypress.env('mollie_available_methods'); [ + 'alma', 'bancontact', 'banktransfer', 'belfius', diff --git a/Test/End-2-end/cypress/e2e/magento/methods/alma.cy.js b/Test/End-2-end/cypress/e2e/magento/methods/alma.cy.js new file mode 100644 index 00000000000..799aafada83 --- /dev/null +++ b/Test/End-2-end/cypress/e2e/magento/methods/alma.cy.js @@ -0,0 +1,60 @@ +/* + * Copyright Magmodules.eu. All rights reserved. + * See COPYING.txt for license details. + */ + +import CheckoutPaymentPage from "Pages/frontend/CheckoutPaymentPage"; +import VisitCheckoutPaymentCompositeAction from "CompositeActions/VisitCheckoutPaymentCompositeAction"; +import MollieHostedPaymentPage from "Pages/mollie/MollieHostedPaymentPage"; +import CheckoutSuccessPage from "Pages/frontend/CheckoutSuccessPage"; +import OrdersPage from "Pages/backend/OrdersPage"; +import CartPage from "Pages/frontend/CartPage"; + +const checkoutPaymentPage = new CheckoutPaymentPage(); +const visitCheckoutPayment = new VisitCheckoutPaymentCompositeAction(); +const mollieHostedPaymentPage = new MollieHostedPaymentPage(); +const checkoutSuccessPage = new CheckoutSuccessPage(); +const ordersPage = new OrdersPage(); +const cartPage = new CartPage(); + +if (Cypress.env('mollie_available_methods').includes('alma')) { + describe('Check that Alma behaves as expected', () => { + [ + {status: 'paid', orderStatus: 'Processing', title: 'C2938625: Validate the submission of an order with Alma as payment method and payment mark as "Paid"'}, + {status: 'failed', orderStatus: 'Canceled', title: 'C2938626: Validate the submission of an order with Alma as payment method and payment mark as "Failed"'}, + {status: 'expired', orderStatus: 'Canceled', title: 'C2938627: Validate the submission of an order with Alma as payment method and payment mark as "Expired"'}, + {status: 'canceled', orderStatus: 'Canceled', title: 'C2938628: Validate the submission of an order with Alma as payment method and payment mark as "Cancelled"'}, + ].forEach((testCase) => { + it(testCase.title, () => { + visitCheckoutPayment.visit(); + + cy.intercept('mollie/checkout/redirect/paymentToken/*').as('mollieRedirect'); + + checkoutPaymentPage.selectPaymentMethod('ALMA'); + checkoutPaymentPage.placeOrder(); + + mollieHostedPaymentPage.selectStatus(testCase.status); + + if (testCase.status === 'paid') { + checkoutSuccessPage.assertThatOrderSuccessPageIsShown(); + } + + if (testCase.status === 'canceled') { + cartPage.assertCartPageIsShown(); + } + + cy.backendLogin(); + + cy.get('@order-id').then((orderId) => { + ordersPage.openOrderById(orderId); + }); + + if (testCase.status === 'expired') { + ordersPage.callFetchStatus(); + } + + ordersPage.assertOrderStatusIs(testCase.orderStatus); + }); + }); + }) +} diff --git a/Test/End-2-end/cypress/e2e/magento/methods/creditcard-with-components.cy.js b/Test/End-2-end/cypress/e2e/magento/methods/creditcard-with-components.cy.js index 755fdfa6b34..8b31c9cae00 100644 --- a/Test/End-2-end/cypress/e2e/magento/methods/creditcard-with-components.cy.js +++ b/Test/End-2-end/cypress/e2e/magento/methods/creditcard-with-components.cy.js @@ -1,3 +1,8 @@ +/* + * Copyright Magmodules.eu. All rights reserved. + * See COPYING.txt for license details. + */ + import CheckoutPaymentPage from "Pages/frontend/CheckoutPaymentPage"; import VisitCheckoutPaymentCompositeAction from "CompositeActions/VisitCheckoutPaymentCompositeAction"; import MollieHostedPaymentPage from "Pages/mollie/MollieHostedPaymentPage"; @@ -12,7 +17,7 @@ const mollieHostedPaymentPage = new MollieHostedPaymentPage(); const checkoutSuccessPage = new CheckoutSuccessPage(); const ordersPage = new OrdersPage(); -if (Cypress.env('mollie_available_methods').includes('bancontact')) { +if (Cypress.env('mollie_available_methods').includes('creditcard')) { describe('Check that creditcards with components behaves as expected', () => { it('C3037: Validate the submission of an order with Credit Card as payment method using Mollie Components and payment mark as "Paid"', () => { visitCheckoutPayment.visit(); diff --git a/Test/Fakes/Service/Mollie/GetMollieStatusFake.php b/Test/Fakes/Service/Mollie/GetMollieStatusFake.php index f891aeba2f8..cb19a153891 100644 --- a/Test/Fakes/Service/Mollie/GetMollieStatusFake.php +++ b/Test/Fakes/Service/Mollie/GetMollieStatusFake.php @@ -23,12 +23,12 @@ public function setResponse(GetMollieStatusResult $response): void $this->response = $response; } - public function execute(int $orderId): GetMollieStatusResult + public function execute(int $orderId, string $transactionId = null): GetMollieStatusResult { if ($this->response) { return $this->response; } - return parent::execute($orderId); + return parent::execute($orderId, $transactionId); } } diff --git a/Test/Integration/Etc/Config/MethodsConfigurationTest.php b/Test/Integration/Etc/Config/MethodsConfigurationTest.php index 48417145f59..b5dd4a45797 100644 --- a/Test/Integration/Etc/Config/MethodsConfigurationTest.php +++ b/Test/Integration/Etc/Config/MethodsConfigurationTest.php @@ -15,6 +15,7 @@ public function methods(): array { return [ ['mollie_methods_applepay'], + ['mollie_methods_alma'], ['mollie_methods_bancontact'], ['mollie_methods_banktransfer'], ['mollie_methods_belfius'], diff --git a/Test/Integration/Helper/GeneralTest.php b/Test/Integration/Helper/GeneralTest.php index 3b2b99d9e5d..2361be46d23 100644 --- a/Test/Integration/Helper/GeneralTest.php +++ b/Test/Integration/Helper/GeneralTest.php @@ -1,4 +1,8 @@ ['free', ''], 'applepay' => ['mollie_methods_applepay', 'applepay'], + 'alma' => ['mollie_methods_alma', 'alma'], 'bancontact' => ['mollie_methods_bancontact', 'bancontact'], 'banktransfer' => ['mollie_methods_banktransfer', 'banktransfer'], 'belfius' => ['mollie_methods_belfius', 'belfius'], diff --git a/Test/Integration/Model/Methods/AlmaTest.php b/Test/Integration/Model/Methods/AlmaTest.php new file mode 100644 index 00000000000..c1a8cfa12fc --- /dev/null +++ b/Test/Integration/Model/Methods/AlmaTest.php @@ -0,0 +1,16 @@ +assertArrayHasKey('mollie_methods_giftcard', $result['payment']['issuersListType']); $this->assertArrayHasKey('mollie_methods_applepay', $result['payment']['image']); + $this->assertArrayHasKey('mollie_methods_alma', $result['payment']['image']); $this->assertArrayHasKey('mollie_methods_bancontact', $result['payment']['image']); $this->assertArrayHasKey('mollie_methods_banktransfer', $result['payment']['image']); $this->assertArrayHasKey('mollie_methods_belfius', $result['payment']['image']); diff --git a/Test/Integration/Service/Config/PaymentFeeTest.php b/Test/Integration/Service/Config/PaymentFeeTest.php index e6407b4ef7b..13388b2c0e3 100644 --- a/Test/Integration/Service/Config/PaymentFeeTest.php +++ b/Test/Integration/Service/Config/PaymentFeeTest.php @@ -1,5 +1,5 @@ assertEquals('discount', $lastLine['type']); - $this->assertEquals($adjustment, $lastLine['totalAmount']['value']); + $this->assertEquals(round($adjustment, 2), $lastLine['totalAmount']['value']); $total = 0; foreach ($result as $orderLine) { $total += $orderLine['totalAmount']['value']; } - $this->assertEquals($order->getBaseGrandTotal(), $total); + $this->assertEquals( + round($order->getBaseGrandTotal(), 2), + $total + ); } /** @@ -242,6 +245,8 @@ public function adjustmentsDataProvider(): array [-0.03], [-0.02], [-0.01], + [0.0051111111], // Rounds up to 0.1, so valid + [0.0099999999], // Rounds up to 0.1, so valid [0.01], [0.02], [0.03], diff --git a/composer.json b/composer.json index 093a2b74859..e10f2156b2c 100644 --- a/composer.json +++ b/composer.json @@ -1,12 +1,13 @@ { "name": "mollie/magento2", "description": "Mollie Payment Module for Magento 2", - "version": "2.36.0", + "version": "2.37.0", "keywords": [ "mollie", "payment", "service", "apple pay", + "alma", "bancontact", "banktransfer", "belfius", diff --git a/etc/adminhtml/methods.xml b/etc/adminhtml/methods.xml index 5f89c4f63b6..d3402c05eb3 100644 --- a/etc/adminhtml/methods.xml +++ b/etc/adminhtml/methods.xml @@ -1,12 +1,11 @@ + ~ Copyright Magmodules.eu. All rights reserved. + ~ See COPYING.txt for license details. + --> + diff --git a/etc/adminhtml/methods/alma.xml b/etc/adminhtml/methods/alma.xml new file mode 100644 index 00000000000..b16c5b77143 --- /dev/null +++ b/etc/adminhtml/methods/alma.xml @@ -0,0 +1,144 @@ + + + + + + + + + Magento\Config\Model\Config\Source\Yesno + payment/mollie_methods_alma/active + + + + payment/mollie_methods_alma/title + + 1 + + + + + payment/mollie_methods_alma/payment_description + + + payment + 1 + + + + + validate-digits-range digits-range-1-365 + payment/mollie_methods_alma/days_before_expire + + 1 + order + + How many days before orders for this method becomes expired? Leave empty to use default expiration (28 days) + + + + Magento\Payment\Model\Config\Source\Allspecificcountries + payment/mollie_methods_alma/allowspecific + + 1 + + + + + Magento\Directory\Model\Config\Source\Country + 1 + payment/mollie_methods_alma/specificcountry + + 1 + + + + + payment/mollie_methods_alma/min_order_total + + 1 + + + + + payment/mollie_methods_alma/max_order_total + + 1 + + + + + payment/mollie_methods_alma/payment_surcharge_type + Mollie\Payment\Model\Adminhtml\Source\PaymentFeeType + + 1 + + + + + payment/mollie_methods_alma/payment_surcharge_fixed_amount + Mollie\Payment\Model\Adminhtml\Backend\VerifiyPaymentFee + validate-not-negative-number + + 1 + fixed_fee,fixed_fee_and_percentage + + + + + payment/mollie_methods_alma/payment_surcharge_percentage + Mollie\Payment\Model\Adminhtml\Backend\VerifiyPaymentFee + validate-number-range number-range-0-10 + + 1 + percentage,fixed_fee_and_percentage + + + + + payment/mollie_methods_alma/payment_surcharge_limit + + Mollie\Payment\Model\Adminhtml\Backend\VerifiyPaymentFee + validate-not-negative-number + + 1 + percentage,fixed_fee_and_percentage + + + + + payment/mollie_methods_alma/payment_surcharge_tax_class + \Magento\Tax\Model\TaxClass\Source\Product + + 1 + fixed_fee,percentage,fixed_fee_and_percentage + + + + + validate-number + payment/mollie_methods_alma/sort_order + + 1 + + + + diff --git a/etc/adminhtml/methods/applepay.xml b/etc/adminhtml/methods/applepay.xml index e9589d4e6b5..0fefe3579f8 100644 --- a/etc/adminhtml/methods/applepay.xml +++ b/etc/adminhtml/methods/applepay.xml @@ -48,7 +48,7 @@ payment/mollie_methods_applepay/integration_type
External: The user is redirected to a Mollie page. No extra configuration required.
- Direct: The user can use Apple Pay in your checkout. You need to upload a certificate to your server for this to work. View instructions. + Direct: The user can use Apple Pay directly from your checkout, product page, minicart and shopping cart page. ]]>
Mollie\Payment\Model\Adminhtml\Source\ApplePayIntegrationType diff --git a/etc/config.xml b/etc/config.xml index 9473b6fa3fc..fd1dcda8f69 100644 --- a/etc/config.xml +++ b/etc/config.xml @@ -3,7 +3,7 @@ - v2.36.0 + v2.37.0 0 0 test @@ -71,6 +71,25 @@ 0 1 + + 1 + Mollie\Payment\Model\Methods\Alma + ALMA + {ordernumber} + payment + order + 0 + + 1 + 1 + 1 + 1 + 0 + 1 + 0 + 0 + 1 + 1 Mollie\Payment\Model\Methods\Bancontact diff --git a/etc/di.xml b/etc/di.xml index 4d3d9700cfa..9fb71038043 100644 --- a/etc/di.xml +++ b/etc/di.xml @@ -161,6 +161,7 @@ Mollie\Payment\Service\Order\Lines\Generator\MagentoGiftWrapping Mollie\Payment\Service\Order\Lines\Generator\GeisswebEuvat Mollie\Payment\Service\Order\Lines\Generator\ShippingDiscount + Mollie\Payment\Service\Order\Lines\Generator\MagentoRewardPoints @@ -366,6 +367,10 @@ + + + + @@ -412,6 +417,141 @@ + + + + Magento\Payment\Block\Form + Mollie\Payment\Block\Info\Base + MollieAlmaValueHandlerPool + MollieCommandPool + MollieAlmaValidatorPool + + + + + + + MollieAlmaConfigValueHandler + + + + + + + MollieAlmaConfig + + + + + + Mollie\Payment\Model\Methods\Alma::CODE + + + + + + + MollieAlmaCountryValidator + + + + + + + MollieAlmaConfig + + + + + + + Magento\Payment\Block\Form + Mollie\Payment\Block\Info\Base + MollieBancontactValueHandlerPool + MollieCommandPool + MollieBancontactValidatorPool + + + + + + + MollieBancontactConfigValueHandler + + + + + + + MollieBancontactConfig + + + + + + Mollie\Payment\Model\Methods\Bancontact::CODE + + + + + + + MollieBancontactCountryValidator + + + + + + + MollieBancontactConfig + + + + + + + Magento\Payment\Block\Form + Mollie\Payment\Block\Info\Base + MollieBanktransferValueHandlerPool + MollieCommandPool + MollieBanktransferValidatorPool + + + + + + + MollieBanktransferConfigValueHandler + + + + + + + MollieBanktransferConfig + + + + + + Mollie\Payment\Model\Methods\Banktransfer::CODE + + + + + + + MollieBanktransferCountryValidator + + + + + + + MollieBanktransferConfig + + + diff --git a/etc/events.xml b/etc/events.xml index 1b45d8f4f24..6c9df6b8668 100644 --- a/etc/events.xml +++ b/etc/events.xml @@ -66,4 +66,7 @@ + + + diff --git a/etc/graphql/di.xml b/etc/graphql/di.xml index 59ef874468c..5017366df3e 100644 --- a/etc/graphql/di.xml +++ b/etc/graphql/di.xml @@ -1,9 +1,15 @@ + + Mollie\Payment\GraphQL\DataProvider + Mollie\Payment\GraphQL\DataProvider Mollie\Payment\GraphQL\DataProvider Mollie\Payment\GraphQL\DataProvider Mollie\Payment\GraphQL\DataProvider diff --git a/etc/payment.xml b/etc/payment.xml index f8dc5d320f8..16c2a8ede56 100644 --- a/etc/payment.xml +++ b/etc/payment.xml @@ -1,9 +1,17 @@ + + 0 + + 0 + 0 diff --git a/i18n/de_DE.csv b/i18n/de_DE.csv index 4659350dcea..55074350eb4 100644 --- a/i18n/de_DE.csv +++ b/i18n/de_DE.csv @@ -192,6 +192,7 @@ "Payment Surcharge limit","Maximaler Zahlungszuschlag" "Payment Surcharge Tax Class","Steuerklassifikation für Zahlungszuschlag" "Sorting Order","Sortierreihenfolge" +"Alma","Alma" "Bancontact","Bancontact" "Banktransfer","Banküberweisung" "Status Pending","Status ausstehend" diff --git a/i18n/en_US.csv b/i18n/en_US.csv index 3da26903d4d..b09a1b55a5c 100644 --- a/i18n/en_US.csv +++ b/i18n/en_US.csv @@ -192,6 +192,7 @@ "Payment Surcharge limit","Payment Surcharge limit" "Payment Surcharge Tax Class","Payment Surcharge Tax Class" "Sorting Order","Sorting Order" +"Alma","Alma" "Bancontact","Bancontact" "Banktransfer","Banktransfer" "Status Pending","Status Pending" diff --git a/i18n/es_ES.csv b/i18n/es_ES.csv index f6e00ae3a0a..b8a8db57c49 100644 --- a/i18n/es_ES.csv +++ b/i18n/es_ES.csv @@ -192,6 +192,7 @@ "Payment Surcharge limit","Recargo de pago límite" "Payment Surcharge Tax Class","Recargo de pago clase impositiva" "Sorting Order","Orden de clasificación" +"Alma","Alma" "Bancontact","Contacto bancario" "Banktransfer","Transferencia bancaria" "Status Pending","Estado pendiente" diff --git a/i18n/fr_FR.csv b/i18n/fr_FR.csv index 494000d05f3..4128f6df607 100644 --- a/i18n/fr_FR.csv +++ b/i18n/fr_FR.csv @@ -192,6 +192,7 @@ "Payment Surcharge limit","Limite de majoration de paiement" "Payment Surcharge Tax Class","Classe fiscale pour majoration de paiement" "Sorting Order","Tri des commandes" +"Alma","Alma" "Bancontact","Bancontact" "Banktransfer","Virement bancaire" "Status Pending","Statut en attente" diff --git a/i18n/nl_NL.csv b/i18n/nl_NL.csv index 55b1f8368c4..ce54e3eba97 100644 --- a/i18n/nl_NL.csv +++ b/i18n/nl_NL.csv @@ -192,6 +192,7 @@ "Payment Surcharge limit","Betalingstoeslag limiet" "Payment Surcharge Tax Class","Betalingstoeslag belastingklasse" "Sorting Order","Sorteervolgorde" +"Alma","Alma" "Bancontact","Bancontact" "Banktransfer","Bankoverschrijving" "Status Pending","Status openstaand" diff --git a/view/adminhtml/templates/form/mollie_paymentlink.phtml b/view/adminhtml/templates/form/mollie_paymentlink.phtml index ffe61817f6b..ba4307efcd2 100644 --- a/view/adminhtml/templates/form/mollie_paymentlink.phtml +++ b/view/adminhtml/templates/form/mollie_paymentlink.phtml @@ -1,6 +1,6 @@ " style="display:none">