diff --git a/index.php b/index.php index f7be0b77e..64d530c3d 100755 --- a/index.php +++ b/index.php @@ -1,11 +1,11 @@ My Buckaroo > General." msgstr "Die Buckaroo GUID, die in Buckaroo Plaza > Mein Buckaroo > Allgemein zu finden ist." +#: src/Gateways/Googlepay/GooglepayGateway.php:493 +msgid "The Buckaroo Gateway merchant ID which can be found in the Buckaroo Plaza → Services -> Google Pay." +msgstr "Die Gateway-Händler-ID von Buckaroo finden Sie im Buckaroo Plaza → Services → Google Pay." + #: src/Gateways/PayPerEmail/PayPerEmailGateway.php:140 msgid "The expiration date for the paylink." msgstr "Das Ablaufdatum für den Paylink." @@ -1362,3 +1365,92 @@ msgstr "Google Merchant ID" #: src/Gateways/Googlepay/GooglepayGateway.php:499 msgid "Your Google Merchant ID from the Google Pay Business Console (e.g. BCR2DN4T...)." msgstr "Ihre Google Merchant ID aus der Google Pay Business Console (z.B. BCR2DN4T...)." + +#: src/Gateways/Alipay/AlipayGateway.php +msgid "One of the world's largest mobile wallets, widely used by shoppers in China." +msgstr "Eine der größten mobilen Wallets weltweit, weit verbreitet bei Verbrauchern in China." + +#: src/Gateways/Applepay/ApplepayGateway.php +msgid "Apple's mobile wallet for quick, secure payments via Face ID or Touch ID on Apple devices." +msgstr "Die mobile Wallet von Apple für schnelle, sichere Zahlungen per Face ID oder Touch ID auf Apple-Geräten." + +#: src/Gateways/Bancontact/BancontactGateway.php +msgid "Belgium's most popular payment method, linked directly to the shopper's own bank." +msgstr "Die beliebteste Zahlungsmethode Belgiens, direkt mit der eigenen Bank des Kunden verbunden." + +#: src/Gateways/Transfer/TransferGateway.php +msgid "Manual bank transfer, with payment instructions provided to the customer after checkout." +msgstr "Manuelle Banküberweisung, bei der der Kunde nach dem Checkout die Zahlungsdaten erhält." + +#: src/Gateways/Belfius/BelfiusGateway.php +msgid "Direct, guaranteed bank payments for customers of Belfius, a major Belgian bank." +msgstr "Direkte, garantierte Bankzahlungen für Kunden von Belfius, einer großen belgischen Bank." + +#: src/Gateways/Billink/BillinkGateway.php +msgid "Dutch pay-after-delivery by invoice with a 14-day term, for private and business customers." +msgstr "Niederländischer Rechnungskauf mit einer Zahlungsfrist von 14 Tagen, für Privat- und Geschäftskunden." + +#: src/Gateways/Bizum/BizumGateway.php +msgid "Spain's mobile payment method, with instant bank-to-bank transfers via phone number." +msgstr "Die mobile Zahlungsmethode Spaniens mit sofortigen Bank-zu-Bank-Überweisungen per Telefonnummer." + +#: src/Gateways/Googlepay/GooglepayGateway.php +msgid "Google's wallet, using the cards saved to a shopper's Google Account." +msgstr "Die Wallet von Google, mit den im Google-Konto des Kunden gespeicherten Karten." + +#: src/Gateways/Crypto/CryptoGateway.php +msgid "Crypto payment method accepting digital assets such as Bitcoin, Ethereum and USDC." +msgstr "Krypto-Zahlungsmethode, die digitale Währungen wie Bitcoin, Ethereum und USDC akzeptiert." + +#: src/Gateways/Ideal/IdealGateway.php +msgid "The Netherlands' most-used online payment method, via the shopper's own bank, now co-branded with Wero." +msgstr "Die meistgenutzte Online-Zahlungsmethode der Niederlande, über die eigene Bank des Kunden, jetzt mit Co-Branding von Wero." + +#: src/Gateways/In3/In3Gateway.php +msgid "Interest-free payment in three instalments over 60 days, settled via iDEAL." +msgstr "Zinsfreie Zahlung in drei Raten über 60 Tage, abgewickelt über iDEAL." + +#: src/Gateways/Kbc/KbcGateway.php +msgid "Direct bank payments for customers of KBC/CBC in Belgium." +msgstr "Direkte Bankzahlungen für Kunden von KBC/CBC in Belgien." + +#: src/Gateways/Klarna/KlarnaGateway.php +msgid "Klarna pay-later and instalment options, with Klarna acting as Merchant of Record." +msgstr "Zahlungsaufschub und Ratenzahlung mit Klarna, wobei Klarna als Merchant of Record fungiert." + +#: src/Gateways/Klarna/KlarnaPayGateway.php +msgid "Klarna pay-after-delivery, authorized at checkout and captured on shipment." +msgstr "Kauf auf Rechnung mit Klarna, autorisiert beim Checkout und eingezogen bei Versand." + +#: src/Gateways/Paypal/PaypalGateway.php +msgid "Global digital wallet with card and balance payments, plus Buyer Protection." +msgstr "Weltweite digitale Wallet mit Zahlungen per Karte oder Guthaben, inklusive Käuferschutz." + +#: src/Gateways/PayPerEmail/PayPerEmailGateway.php +msgid "Buckaroo service for sending customers a payment request by email with a secure pay link." +msgstr "Buckaroo-Dienst, um Kunden per E-Mail eine Zahlungsaufforderung mit sicherem Zahlungslink zu senden." + +#: src/Gateways/Przelewy24/Przelewy24Gateway.php +msgid "Poland's leading online payment platform, connecting 165+ local banks and methods." +msgstr "Die führende Online-Zahlungsplattform Polens, mit über 165 lokalen Banken und Methoden." + +#: src/Gateways/Afterpay/AfterpayNewGateway.php +msgid "European pay-after-delivery within 30 days." +msgstr "Europäischer Rechnungskauf innerhalb von 30 Tagen." + +#: src/Gateways/Afterpay/AfterpayOldGateway.php +msgid "Riverty via the older API integration, for merchants not yet migrated." +msgstr "Riverty über die ältere API-Integration, für noch nicht migrierte Händler." + +#: src/Gateways/SepaDirectDebit/SepaDirectDebitGateway.php +msgid "One-off collection from the customer's bank account via a SEPA mandate." +msgstr "Einmaliger Einzug vom Bankkonto des Kunden per SEPA-Mandat." + +#: src/Gateways/Swish/SwishGateway.php +msgid "Sweden's most popular mobile payment app, with instant app-approved payments." +msgstr "Die beliebteste mobile Bezahl-App Schwedens, mit sofortigen, in der App bestätigten Zahlungen." + +#: src/Admin/GeneralSettings.php +msgid "Give every payment the attention it deserves, with 40+ methods in one plugin." +msgstr "Schenken Sie jeder Zahlung die Aufmerksamkeit, die sie verdient, mit über 40 Zahlungsmethoden in einem Plugin." + diff --git a/languages/wc-buckaroo-bpe-gateway-fr_FR.po b/languages/wc-buckaroo-bpe-gateway-fr_FR.po index 222d0c74c..175775ea4 100755 --- a/languages/wc-buckaroo-bpe-gateway-fr_FR.po +++ b/languages/wc-buckaroo-bpe-gateway-fr_FR.po @@ -975,10 +975,13 @@ msgid "The \"%s\" payment method is currently enabled" msgstr "La méthode de paiement \"%s\" est actuellement activée" #: src/Gateways/Applepay/ApplepayGateway.php:474 -#: src/Gateways/Googlepay/GooglepayGateway.php:493 msgid "The Buckaroo GUID which can be found in the Buckaroo Plaza > My Buckaroo > General." msgstr "Le GUID Buckaroo que vous pouvez trouver dans Buckaroo Plaza > Mon Buckaroo > Général." +#: src/Gateways/Googlepay/GooglepayGateway.php:493 +msgid "The Buckaroo Gateway merchant ID which can be found in the Buckaroo Plaza → Services -> Google Pay." +msgstr "L’ID marchand de la passerelle Buckaroo se trouve dans Buckaroo Plaza → Services → Google Pay." + #: src/Gateways/PayPerEmail/PayPerEmailGateway.php:140 msgid "The expiration date for the paylink." msgstr "La date d'expiration pour le lien de paiement." @@ -1362,3 +1365,92 @@ msgstr "Google Merchant ID" #: src/Gateways/Googlepay/GooglepayGateway.php:499 msgid "Your Google Merchant ID from the Google Pay Business Console (e.g. BCR2DN4T...)." msgstr "Votre Google Merchant ID de la Google Pay Business Console (par ex. BCR2DN4T...)." + +#: src/Gateways/Alipay/AlipayGateway.php +msgid "One of the world's largest mobile wallets, widely used by shoppers in China." +msgstr "L'un des plus grands portefeuilles mobiles au monde, très utilisé par les consommateurs en Chine." + +#: src/Gateways/Applepay/ApplepayGateway.php +msgid "Apple's mobile wallet for quick, secure payments via Face ID or Touch ID on Apple devices." +msgstr "Le portefeuille mobile d'Apple pour des paiements rapides et sécurisés via Face ID ou Touch ID sur les appareils Apple." + +#: src/Gateways/Bancontact/BancontactGateway.php +msgid "Belgium's most popular payment method, linked directly to the shopper's own bank." +msgstr "La méthode de paiement la plus populaire de Belgique, directement liée à la banque du client." + +#: src/Gateways/Transfer/TransferGateway.php +msgid "Manual bank transfer, with payment instructions provided to the customer after checkout." +msgstr "Virement bancaire manuel, les instructions de paiement étant transmises au client après la commande." + +#: src/Gateways/Belfius/BelfiusGateway.php +msgid "Direct, guaranteed bank payments for customers of Belfius, a major Belgian bank." +msgstr "Paiements bancaires directs et garantis pour les clients de Belfius, une grande banque belge." + +#: src/Gateways/Billink/BillinkGateway.php +msgid "Dutch pay-after-delivery by invoice with a 14-day term, for private and business customers." +msgstr "Paiement après livraison sur facture aux Pays-Bas, avec un délai de 14 jours, pour les particuliers et les professionnels." + +#: src/Gateways/Bizum/BizumGateway.php +msgid "Spain's mobile payment method, with instant bank-to-bank transfers via phone number." +msgstr "La méthode de paiement mobile de l'Espagne, avec des virements instantanés de compte à compte via le numéro de téléphone." + +#: src/Gateways/Googlepay/GooglepayGateway.php +msgid "Google's wallet, using the cards saved to a shopper's Google Account." +msgstr "Le portefeuille de Google, utilisant les cartes enregistrées dans le compte Google du client." + +#: src/Gateways/Crypto/CryptoGateway.php +msgid "Crypto payment method accepting digital assets such as Bitcoin, Ethereum and USDC." +msgstr "Méthode de paiement en cryptomonnaie acceptant des actifs numériques comme Bitcoin, Ethereum et USDC." + +#: src/Gateways/Ideal/IdealGateway.php +msgid "The Netherlands' most-used online payment method, via the shopper's own bank, now co-branded with Wero." +msgstr "La méthode de paiement en ligne la plus utilisée aux Pays-Bas, via la banque du client, désormais co-brandée avec Wero." + +#: src/Gateways/In3/In3Gateway.php +msgid "Interest-free payment in three instalments over 60 days, settled via iDEAL." +msgstr "Paiement en trois fois sans intérêt sur 60 jours, réglé via iDEAL." + +#: src/Gateways/Kbc/KbcGateway.php +msgid "Direct bank payments for customers of KBC/CBC in Belgium." +msgstr "Paiements bancaires directs pour les clients de KBC/CBC en Belgique." + +#: src/Gateways/Klarna/KlarnaGateway.php +msgid "Klarna pay-later and instalment options, with Klarna acting as Merchant of Record." +msgstr "Paiement différé et en plusieurs fois avec Klarna, Klarna agissant comme Merchant of Record." + +#: src/Gateways/Klarna/KlarnaPayGateway.php +msgid "Klarna pay-after-delivery, authorized at checkout and captured on shipment." +msgstr "Paiement après livraison avec Klarna, autorisé au moment du paiement et capturé à l'expédition." + +#: src/Gateways/Paypal/PaypalGateway.php +msgid "Global digital wallet with card and balance payments, plus Buyer Protection." +msgstr "Portefeuille numérique mondial avec paiements par carte ou solde, et Protection des Achats." + +#: src/Gateways/PayPerEmail/PayPerEmailGateway.php +msgid "Buckaroo service for sending customers a payment request by email with a secure pay link." +msgstr "Service Buckaroo permettant d'envoyer aux clients une demande de paiement par e-mail avec un lien de paiement sécurisé." + +#: src/Gateways/Przelewy24/Przelewy24Gateway.php +msgid "Poland's leading online payment platform, connecting 165+ local banks and methods." +msgstr "La principale plateforme de paiement en ligne de Pologne, réunissant plus de 165 banques et méthodes locales." + +#: src/Gateways/Afterpay/AfterpayNewGateway.php +msgid "European pay-after-delivery within 30 days." +msgstr "Paiement après livraison en Europe sous 30 jours." + +#: src/Gateways/Afterpay/AfterpayOldGateway.php +msgid "Riverty via the older API integration, for merchants not yet migrated." +msgstr "Riverty via l'ancienne intégration API, pour les marchands pas encore migrés." + +#: src/Gateways/SepaDirectDebit/SepaDirectDebitGateway.php +msgid "One-off collection from the customer's bank account via a SEPA mandate." +msgstr "Prélèvement unique sur le compte bancaire du client via un mandat SEPA." + +#: src/Gateways/Swish/SwishGateway.php +msgid "Sweden's most popular mobile payment app, with instant app-approved payments." +msgstr "L'application de paiement mobile la plus populaire de Suède, avec des paiements instantanés validés dans l'application." + +#: src/Admin/GeneralSettings.php +msgid "Give every payment the attention it deserves, with 40+ methods in one plugin." +msgstr "Accordez à chaque paiement l'attention qu'il mérite, avec plus de 40 méthodes de paiement dans un seul plugin." + diff --git a/languages/wc-buckaroo-bpe-gateway-nl_NL.po b/languages/wc-buckaroo-bpe-gateway-nl_NL.po index 7f20db0a1..d3d5fd953 100755 --- a/languages/wc-buckaroo-bpe-gateway-nl_NL.po +++ b/languages/wc-buckaroo-bpe-gateway-nl_NL.po @@ -975,10 +975,13 @@ msgid "The \"%s\" payment method is currently enabled" msgstr "De \"%s\" betaalmethode is momenteel ingeschakeld" #: src/Gateways/Applepay/ApplepayGateway.php:474 -#: src/Gateways/Googlepay/GooglepayGateway.php:493 msgid "The Buckaroo GUID which can be found in the Buckaroo Plaza > My Buckaroo > General." msgstr "De Buckaroo GUID die te vinden is in de Buckaroo Plaza > Mijn Buckaroo > Algemeen." +#: src/Gateways/Googlepay/GooglepayGateway.php:493 +msgid "The Buckaroo Gateway merchant ID which can be found in the Buckaroo Plaza → Services -> Google Pay." +msgstr "The Buckaroo Gateway merchant ID dat kan worden gevonden in de Buckaroo Plaza → Services -> Google Pay." + #: src/Gateways/PayPerEmail/PayPerEmailGateway.php:140 msgid "The expiration date for the paylink." msgstr "De vervaldatum voor de paylink." @@ -1362,3 +1365,92 @@ msgstr "Google Merchant ID" #: src/Gateways/Googlepay/GooglepayGateway.php:499 msgid "Your Google Merchant ID from the Google Pay Business Console (e.g. BCR2DN4T...)." msgstr "Uw Google Merchant ID van de Google Pay Business Console (bijv. BCR2DN4T...)." + +#: src/Gateways/Alipay/AlipayGateway.php +msgid "One of the world's largest mobile wallets, widely used by shoppers in China." +msgstr "Een van de grootste mobiele wallets ter wereld, veel gebruikt door consumenten in China." + +#: src/Gateways/Applepay/ApplepayGateway.php +msgid "Apple's mobile wallet for quick, secure payments via Face ID or Touch ID on Apple devices." +msgstr "De mobiele wallet van Apple voor snelle, veilige betalingen met Face ID of Touch ID op Apple-apparaten." + +#: src/Gateways/Bancontact/BancontactGateway.php +msgid "Belgium's most popular payment method, linked directly to the shopper's own bank." +msgstr "De populairste betaalmethode van België, rechtstreeks gekoppeld aan de eigen bank van de klant." + +#: src/Gateways/Transfer/TransferGateway.php +msgid "Manual bank transfer, with payment instructions provided to the customer after checkout." +msgstr "Handmatige bankoverschrijving, waarbij de klant na het afrekenen de betaalgegevens ontvangt." + +#: src/Gateways/Belfius/BelfiusGateway.php +msgid "Direct, guaranteed bank payments for customers of Belfius, a major Belgian bank." +msgstr "Directe, gegarandeerde bankbetalingen voor klanten van Belfius, een grote Belgische bank." + +#: src/Gateways/Billink/BillinkGateway.php +msgid "Dutch pay-after-delivery by invoice with a 14-day term, for private and business customers." +msgstr "Nederlands achteraf betalen op factuur met een betaaltermijn van 14 dagen, voor particulieren en zakelijke klanten." + +#: src/Gateways/Bizum/BizumGateway.php +msgid "Spain's mobile payment method, with instant bank-to-bank transfers via phone number." +msgstr "De mobiele betaalmethode van Spanje, met directe bank-naar-bankbetalingen via het telefoonnummer." + +#: src/Gateways/Googlepay/GooglepayGateway.php +msgid "Google's wallet, using the cards saved to a shopper's Google Account." +msgstr "De wallet van Google, met de kaarten die zijn opgeslagen in het Google-account van de klant." + +#: src/Gateways/Crypto/CryptoGateway.php +msgid "Crypto payment method accepting digital assets such as Bitcoin, Ethereum and USDC." +msgstr "Cryptobetaalmethode die digitale valuta zoals Bitcoin, Ethereum en USDC accepteert." + +#: src/Gateways/Ideal/IdealGateway.php +msgid "The Netherlands' most-used online payment method, via the shopper's own bank, now co-branded with Wero." +msgstr "De meest gebruikte online betaalmethode van Nederland, via de eigen bank van de klant, nu met co-branding van Wero." + +#: src/Gateways/In3/In3Gateway.php +msgid "Interest-free payment in three instalments over 60 days, settled via iDEAL." +msgstr "Renteloos betalen in drie termijnen over 60 dagen, afgerekend via iDEAL." + +#: src/Gateways/Kbc/KbcGateway.php +msgid "Direct bank payments for customers of KBC/CBC in Belgium." +msgstr "Directe bankbetalingen voor klanten van KBC/CBC in België." + +#: src/Gateways/Klarna/KlarnaGateway.php +msgid "Klarna pay-later and instalment options, with Klarna acting as Merchant of Record." +msgstr "Achteraf betalen en in termijnen betalen met Klarna, waarbij Klarna optreedt als Merchant of Record." + +#: src/Gateways/Klarna/KlarnaPayGateway.php +msgid "Klarna pay-after-delivery, authorized at checkout and captured on shipment." +msgstr "Achteraf betalen met Klarna, geautoriseerd bij het afrekenen en geïnd bij verzending." + +#: src/Gateways/Paypal/PaypalGateway.php +msgid "Global digital wallet with card and balance payments, plus Buyer Protection." +msgstr "Wereldwijde digitale wallet met betalingen via kaart of saldo, inclusief Kopersbescherming." + +#: src/Gateways/PayPerEmail/PayPerEmailGateway.php +msgid "Buckaroo service for sending customers a payment request by email with a secure pay link." +msgstr "Buckaroo-dienst om klanten een betaalverzoek per e-mail te sturen met een veilige betaallink." + +#: src/Gateways/Przelewy24/Przelewy24Gateway.php +msgid "Poland's leading online payment platform, connecting 165+ local banks and methods." +msgstr "Het toonaangevende online betaalplatform van Polen, met meer dan 165 lokale banken en methoden." + +#: src/Gateways/Afterpay/AfterpayNewGateway.php +msgid "European pay-after-delivery within 30 days." +msgstr "Europees achteraf betalen binnen 30 dagen." + +#: src/Gateways/Afterpay/AfterpayOldGateway.php +msgid "Riverty via the older API integration, for merchants not yet migrated." +msgstr "Riverty via de oude API-integratie, voor webshops die nog niet zijn gemigreerd." + +#: src/Gateways/SepaDirectDebit/SepaDirectDebitGateway.php +msgid "One-off collection from the customer's bank account via a SEPA mandate." +msgstr "Eenmalige incasso van de bankrekening van de klant via een SEPA-machtiging." + +#: src/Gateways/Swish/SwishGateway.php +msgid "Sweden's most popular mobile payment app, with instant app-approved payments." +msgstr "De populairste mobiele betaalapp van Zweden, met directe betalingen die in de app worden goedgekeurd." + +#: src/Admin/GeneralSettings.php +msgid "Give every payment the attention it deserves, with 40+ methods in one plugin." +msgstr "Geef elke betaling de aandacht die het verdient, met 40+ betaalmethoden in één plugin." + diff --git a/library/buckaroo_images/buckaroo_small.png b/library/buckaroo_images/buckaroo_small.png new file mode 100644 index 000000000..fd1ddacf1 Binary files /dev/null and b/library/buckaroo_images/buckaroo_small.png differ diff --git a/library/buckaroo_images/giftcards/VVVgiftcard.svg b/library/buckaroo_images/giftcards/VVVgiftcard.svg new file mode 100644 index 000000000..9a15d6956 --- /dev/null +++ b/library/buckaroo_images/giftcards/VVVgiftcard.svg @@ -0,0 +1,1111 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/library/buckaroo_images/giftcards/fashioncheque.svg b/library/buckaroo_images/giftcards/fashioncheque.svg new file mode 100644 index 000000000..a967d6f5f --- /dev/null +++ b/library/buckaroo_images/giftcards/fashioncheque.svg @@ -0,0 +1,126 @@ + + + + + + + + + + + + + + + + + + + + F + C + + diff --git a/library/buckaroo_images/giftcards/yourgift.svg b/library/buckaroo_images/giftcards/yourgift.svg new file mode 100644 index 000000000..651be92f8 --- /dev/null +++ b/library/buckaroo_images/giftcards/yourgift.svg @@ -0,0 +1,370 @@ + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/library/buckaroo_images/idin_logo.svg b/library/buckaroo_images/idin_logo.svg index 1b8b237df..98be23513 100644 --- a/library/buckaroo_images/idin_logo.svg +++ b/library/buckaroo_images/idin_logo.svg @@ -1 +1,29 @@ - \ No newline at end of file + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/library/css/buckaroo-custom.css b/library/css/buckaroo-custom.css index cbc35a0f9..10d1efa51 100644 --- a/library/css/buckaroo-custom.css +++ b/library/css/buckaroo-custom.css @@ -133,60 +133,6 @@ table.woocommerce_order_items tbody tr:first-child td { width: 100%; } -.buckaroo-payment-list { - background-color: #fff; - padding: 15px; - display: flex; - flex-wrap: wrap; - flex-direction: column; - height: 500px; -} - -.buckaroo-payment-list li { - flex: 0 0 auto; - width: 33.333%; - display: flex; - align-items: center; -} - -.buckaroo-payment-list-icon { - max-height: 35px; - width: auto; - margin-right: 10px; -} - -.buckaroo-payment-status { - margin: 0 3px; -} - -.buckaroo-payment-enabled-live { - color: #198754; -} - -.buckaroo-payment-enabled-test { - color: #ffc107; -} - -.buckaroo-payment-disabled { - color: #dc3545; -} - -@media (max-width: 1024px) { - .buckaroo-payment-list { - height: 700px; - } - - .buckaroo-payment-list li { - width: 50%; - } -} - -@media (max-width: 768px) { - .buckaroo-payment-list li { - width: 100%; - } -} - label[for^='payment_method_buckaroo_'] img { max-height: 25px; width: 32px; @@ -470,6 +416,467 @@ label.bk-in3-logo img { overflow: hidden !important; } +/* Payment method card list */ +.buckaroo-payment-cards { + column-count: 3; + column-gap: 10px; + margin: 16px 0; +} + +@media (max-width: 1024px) { + .buckaroo-payment-cards { + column-count: 2; + } +} + +@media (max-width: 640px) { + .buckaroo-payment-cards { + column-count: 1; + } +} +.buckaroo-payment-card { + display: flex; + align-items: center; + background: #fff; + border: 1px solid #e0e0e0; + border-radius: 10px; + padding: 10px 16px; + gap: 14px; + box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06); + break-inside: avoid; + margin-bottom: 10px; +} +.buckaroo-payment-card-icon { + width: 64px; + height: 44px; + border-radius: 8px; + overflow: hidden; + flex-shrink: 0; + display: flex; + align-items: center; + justify-content: center; + background: transparent; + box-sizing: border-box; +} +.buckaroo-payment-card-icon img { + width: 100%; + height: 100%; + object-fit: contain; + border-radius: 0; +} +.buckaroo-payment-card-info { + flex: 1; + min-width: 0; +} +.buckaroo-payment-card-title { + font-weight: 600; + font-size: 14px; + color: #1a1a2e; + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; +} +.buckaroo-payment-card-subtitle { + font-size: 12px; + color: #888; + margin-top: 1px; + display: flex; + align-items: center; + gap: 4px; + white-space: nowrap; + overflow: hidden; +} +.bk-meta-sep { + color: #ccc; + font-weight: 300; +} +.bk-meta-divider { + color: #d0d0d0; + margin: 0 3px; + font-weight: 300; +} + +.bk-status-pill { + display: inline-flex; + align-items: center; + gap: 6px; + padding: 0 12px; + height: 32px; + border-radius: 8px; + font-size: 13px; + font-weight: 600; + white-space: nowrap; + border: none; + box-sizing: border-box; + cursor: default; + pointer-events: none; + user-select: none; +} + +.bk-status-pill-dot { + width: 8px; + height: 8px; + border-radius: 50%; + flex-shrink: 0; + display: inline-block; +} + +.bk-status-pill.bk-status--live { + background: #c6f0d4; + color: #0f5c28; + font-weight: 700; +} +.bk-status-pill.bk-status--live .bk-status-pill-dot { + background: #1a8c3c; +} + +.bk-status-pill.bk-status--test { + background: #fde9b0; + color: #7a5500; + font-weight: 600; +} +.bk-status-pill.bk-status--test .bk-status-pill-dot { + background: #c47d00; +} + +.bk-status-pill.bk-status--disabled { + background: #ebebeb; + color: #888; + font-weight: 500; +} +.bk-status-pill.bk-status--disabled .bk-status-pill-dot { + background: transparent; + border: 1.5px solid #999; + width: 7px; + height: 7px; +} +.buckaroo-payment-card-actions { + display: flex; + align-items: center; + gap: 6px; + flex-shrink: 0; +} +.buckaroo-payment-card-settings { + display: flex; + align-items: center; + justify-content: center; + width: 32px; + height: 32px; + border-radius: 8px; + background: #f6f7f7; + border: 1px solid #dcdcde; + color: #555; + text-decoration: none; + transition: + background 0.15s, + border-color 0.15s, + color 0.15s; + flex-shrink: 0; +} +.buckaroo-payment-card-settings:hover { + background: #e8e9ea; + border-color: #b5b5b5; + color: #1a1a2e; +} +.buckaroo-payment-card-settings svg { + width: 15px; + height: 15px; +} + +/* Payment Methods list page - full-width single-column cards */ +.buckaroo-gateway-list { + display: flex; + flex-direction: column; + gap: 10px; + margin: 16px 0; +} +.buckaroo-gateway-list__card { + border-radius: 10px; + width: 100%; + box-sizing: border-box; +} +.buckaroo-gateway-list__header { + display: flex; + align-items: center; + padding: 0 16px 6px 16px; + font-size: 12px; + font-weight: 600; + color: #646970; + text-transform: uppercase; + letter-spacing: 0.04em; + border-bottom: 1px solid #e0e0e0; + margin-bottom: 4px; +} +.buckaroo-gateway-list__header-method { + flex: 1; +} +.buckaroo-gateway-list__header-enabled { + width: 80px; + text-align: center; + flex-shrink: 0; +} +.buckaroo-gateway-list__header-actions { + width: 40px; + flex-shrink: 0; +} +.buckaroo-gateway-list .buckaroo-payment-card { + break-inside: auto; + margin-bottom: 0; + width: 100%; + box-sizing: border-box; +} +.buckaroo-gateway-list .buckaroo-payment-card-actions { + align-items: center; + gap: 10px; +} +.buckaroo-gateway-list .wc-payment-gateway-method-toggle-enabled { + display: inline-flex; + width: 80px; + justify-content: center; +} + +/* Gateway settings page summary card */ +.bk-gateway-summary-card { + display: flex; + align-items: center; + background: #fff; + border: 1px solid #e0e0e0; + border-radius: 10px; + padding: 16px 20px; + gap: 14px; + box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06); + margin-bottom: 20px; +} +.bk-gateway-summary-card__icon { + width: 80px; + height: 56px; + border-radius: 8px; + overflow: hidden; + flex-shrink: 0; + display: flex; + align-items: center; + justify-content: center; + background: transparent; + box-sizing: border-box; +} +.bk-gateway-summary-card__icon img { + width: 100%; + height: 100%; + object-fit: contain; +} +.bk-gateway-summary-card__icon-placeholder { + width: 80px; + height: 56px; + border-radius: 8px; + background: #1a2340; + display: flex; + align-items: center; + justify-content: center; + color: #fff; + font-size: 11px; + font-weight: 700; + text-align: center; + line-height: 1.2; + flex-shrink: 0; +} +.bk-gateway-summary-card__info { + flex: 1; + min-width: 0; +} +.bk-gateway-summary-card__title { + font-size: 1.2em; + font-weight: 700; + color: #1a1a2e; + margin-bottom: 4px; +} +.bk-gateway-summary-card__desc { + font-size: 13px; + color: #646970; + margin-bottom: 8px; + line-height: 1.5; +} +.bk-gateway-summary-card__tags { + display: flex; + flex-wrap: wrap; + gap: 4px; +} +.bk-tag { + display: inline-block; + background: #f0f0f0; + color: #555; + font-size: 11px; + font-weight: 600; + padding: 2px 8px; + border-radius: 12px; + border: 1px solid #dcdcde; +} +.bk-gateway-summary-card__status { + flex-shrink: 0; + margin-left: auto; +} +.bk-intro-hero { + text-align: center; + padding: 32px 24px 28px; + background: #fff; + border: 1px solid #e0e0e0; + border-radius: 12px; + margin-bottom: 20px; + box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06); +} +.bk-intro-hero__logo { + margin-bottom: 14px; +} +.bk-intro-hero__logo-img { + height: 36px; + width: auto; + display: inline-block; +} +.bk-intro-hero__desc { + font-size: 13px; + color: #555; + line-height: 1.6; + max-width: 480px; + margin: 0 auto 20px; +} +.bk-intro-hero__actions { + display: flex; + justify-content: center; + gap: 12px; + flex-wrap: wrap; +} +.bk-hero-btn { + display: inline-flex; + align-items: center; + gap: 7px; + padding: 10px 22px; + border-radius: 999px; + font-size: 14px; + font-weight: 700; + text-decoration: none; + transition: + background 0.15s, + color 0.15s, + opacity 0.15s; + cursor: pointer; +} +.bk-hero-btn:hover { + text-decoration: none; +} +.bk-hero-btn--docs { + background: #c8f135; + color: #1a2340; + border: 2px solid #c8f135; +} +.bk-hero-btn--docs:hover { + background: #1a2340; + color: #c8f135; + border: 2px solid #c8f135; + opacity: 1; +} +.bk-hero-btn--contact { + background: #1a2340; + color: #fff; + border: 2px solid #1a2340; +} +.bk-hero-btn--contact:hover { + background: transparent; + color: #1a2340; + opacity: 1; +} + +/* API Credentials section */ +.bk-creds-card { + margin: 0; + padding: 0; +} +.bk-creds-table { + width: 100%; + margin: 0 !important; +} +.bk-creds-field { + display: flex; + align-items: center; + gap: 6px; +} +.bk-creds-inline-btn { + white-space: nowrap; + position: relative; +} +.bk-key-btn { + display: inline-flex; + align-items: center; + justify-content: center; + padding: 0 6px; + align-self: stretch; + border: 1px solid #dcdcde; + border-radius: 3px; + background: #f6f7f7; + cursor: pointer; + flex-shrink: 0; + transition: background 0.1s; + color: #555; +} +.bk-key-btn:active { + opacity: 0.8; +} +.bk-key-btn--toggle:hover { + background: #e8e9ea; + color: #1a1a2e; +} + +/* General Options section */ +.bk-general-options-card { + margin: 0; + padding: 0; +} +.bk-general-options-card h3:empty, +.bk-general-options-card h3 { + display: none; +} +.bk-general-options-card .form-table { + width: 100%; + margin: 0; +} + +.buckaroo-payment-card-icon-placeholder { + width: 64px; + height: 44px; + border-radius: 8px; + background: #1a2340; + display: flex; + align-items: center; + justify-content: center; + color: #fff; + font-size: 11px; + font-weight: 700; + text-align: center; + line-height: 1.2; + flex-shrink: 0; +} + +.bk-cc-icons { + display: inline-flex; + align-items: center; + gap: 3px; + margin-left: 4px; + vertical-align: middle; +} +.bk-cc-icon { + height: 14px; + width: auto; + border-radius: 2px; + opacity: 0.85; +} +body.woocommerce_page_wc-settings .form-table td textarea, +body.woocommerce_page_wc-settings .form-table td textarea.wide-input, +body.woocommerce_page_wc-settings .form-table td textarea.large-text, +body.woocommerce_page_wc-settings .form-table td textarea.input-text { + width: 29em !important; + max-width: 29em !important; + min-width: 0 !important; + box-sizing: border-box !important; +} + /* ------------------------------------------------------------------------- * BNPL birthdate datepicker (classic checkout) * diff --git a/readme.txt b/readme.txt index 2624b512a..5d00f6542 100644 --- a/readme.txt +++ b/readme.txt @@ -384,427 +384,3 @@ Add support for WooCommerce 7.8.0 - Update README with new WooCommerce version support [BP-2339] - Added YourSafe Issuer to Ideal[BP-2449] - Add a notification when one of the payment methods is in test [BP-1982] -= 3.5.0 = -- Support for WooCommerce 7.0.0 -- Update README.MD file [#127] -- Remove 'Handelsbanken' [BP-1471] -- Notice: Undefined index: PayPalExpressController.php [BP-2063] -- Rebranding Afterpay to Riverty [BP-1865] - -= 3.4.0 = -- Change gender selection for BNPL methods [BP-1896] -- Add contribution guidelines [BP-1873] -- Add string 'A valid iDEAL bank is required' to .pot file and add Dutch ( Thank you @Robbertdk ) -- Error when loading empty credicard -- Add KlarnaKP to WooCommerce BP-1886 -- Add product images to the Afterpay request (ImageUrl) [BP-1768] -- Slow load time for javascript files [BP-1857] -- Fix Payconiq payment method in live mode. [BP-2030] - -= 3.3.0 = -- Support for Wordpress version 6.0 & WooCommerce 6.7.0 [BP-1861] -- Fix undefined array key show_in_checkout -- Add paypal express merchandid admin field [BP-1477] -- Explain variable transaction description [BP-1492] -- Missing Payment method description in WooCommerce templates. [BP-1490] -- Update README file [BP-1508] -- The Apple Pay logo is not visible when the old logos are being used. [BP-1813] -- Support Afterpay B2B [BP-1468] -- Added support for payment fee vat display mode(including / excluding). [BP-1858] - -= 3.2.3 = -- Update esc_html to esc_url for image urls -- Sanitized some fields -- Other Improvments - -= 3.2.2 = -- Don't use calls like // phpcs:ignore [BP-1727] -- Use wp_enqueue commands [BP-1728] -- Sanitize, Escape and Validate variables [BP-1528] -- Adding code sniffer for Woocommerce to the GitHub pipeline [BP-1534] - -= 3.2.1 = -- Don't use calls like // phpcs:ignore [BP-1727] -- Use wp_enqueue commands [BP-1728] -- Sanitize, Escape and Validate variables [BP-1528] -- Adding code sniffer for Woocommerce to the GitHub pipeline [BP-1534] - -= 3.2.0 = -- Support for Wordpress: 6.0 and WooCommerce: 6.4.1 -- Paypal seller protection address information jumbled [BP-1479] -- Variables and options must be escaped when echo'd [BP-1529] -- Sanitize, Escape and Validate variables [BP-1528] -- Remove Libraries Already In Core [BP-1527] -- Improve files naming [BP-1526] -- Remove "png instead of svg" setting and "new" png images [BP-1498] -- Limit payment logo size [BP-1459] - -= 3.1.0 = - -- Support for Wordpress: 5.9.3 and WooCommerce: 6.3.1 -- Log report notice when no log file present -- Add new .SVG icons to all plugins [BP-1267] -- Fix for error when creating PayPerEmail [BP-1352] -- Apple Guid field missing form settings page [BP-1430] -- Buckaroo plugin settings are not visible for a specific merchant [BP-1431] -- Add PayPal express button [BP-209] - -= 3.0.0 = - -3.0.0 is a MAJOR release, it may break things so we advice to do additional testing and treat it with caution. - -With 3.0.0 we are taking a big step in improving our services within WooCommerce. We have technically improved our installation and configuration process and made it more understandable for everyone. Below are some highlights of our improvements: - -- Code upgrade: Removed a lot of duplication, started using constants for statuses and codes everywhere, removed unused services and code, started using code into common/single places, reduced long methods sizes. - -- Improved logging: We upgraded our logging service and made it more flexible. Option to store in in files or database (or both). - -- Improved our UI: We changed a lot, we improved and simplified our configuration process. Added a option to check you filled credentials, moved some advanced configuration to specific methods and changed icons for the payment methods to a single style/design. - -For more details about this release: https://docs.buckaroo.io/docs/nl/woocommerce-releases - -= 2.24.1 = - -- transactions fail after update to 2.24.0[BP-1137] -- translated payment providers description, updated translation files - -= 2.24.0 = - -- Capture amount incorrect (fix admin area url & already captured amount) [BP-997] -- Add EPS as payment method in the plugin [BP-1106] -- Company name is not sent to Buckaroo platform [BP-1102] -- Blank page upon Payconiq cancellation [BP-1062] - -= 2.23.0 = -- Fix VatNumber / translation [BP-957] -- Add accept terms & conditions for Billink [BP-996] -- 1 cent rounding issue with captures [BP-1009] -- iDIN verification does not work [BP-1050] -- Change SOAP certificate [BP-987] - -= 2.22.1 = -- Capture amount incorrect (fix for cc and ap old) [BP-997] -- fix capture transactions description pattern handling - -= 2.22.0 = -- Capture amount incorrect [BP-997] -- fix Fatal error: Uncaught Error: Call to a member function get_total() on null gateway-buckaroo.php on line 101 -- Afterpay transaction can't be placed successfully (invisible error) [BP-998] -- Buckaroo plugin conflicts with a other plugin (Fliuentform) after our latest update [BP-999] - -= 2.21.0 = -- Make it possible to set the minimum and maximum amount for a payment method to be displayed [BP-926] -- PayPal (V2) cancellation returns to the homepage and not back to the cart page [BP-941] -- "A non-numeric value encountered" fix -- Afterpay issue regarding wrong image file type [BP-963] -- Make VAT number field non-required (BILLINK) [BP-957] -- Add CreditCard brand PostePay [BP-970] -- Add translation for Billink error [BP-960] -- WooCommerce - Afterpay (new+old) date of birth field improvement [BP-964] - -= 2.20.0 = -- Make it possible for Billink to enable both methods (B2B+B2C) -- update apple-developer-merchantid-domain-association -- Refunds from Plaza are not visible in Admin -- AP old - error during partial refund -- CC and AP - capture form has no payment fee and failed -- AP new - HTTP 500 during capture attempt -- capture button for CC and AP is not clickable -- AP new - error during partial refund - -= 2.19.0 = -- Add payment method Belfius -- Add verification method iDIN (age verification) -- Add Klarna 'Pay' and 'PayInInstallments' -- Bancontact / MisterCash broken settings -- Plugin does not work when "Transaction Description" is not filled in -- Identifier 'customerTypeElement' has already been declared -- Change payment icons -- Add Payment method Billink (add article description) -- Remove iDEAL issuer Moneyou from all plugins. -- Status not pushed successfully after custom change to invoice number -- Fix some PHP notices -- PHP8 is giving errors for the payment method "Afterpaynew" - -= 2.18.1 = -- Fix In3 not working [BP-751] -- Bancontact possibly disable after update to 2.18 [BP-725] -- change default Billink name for front end -- Fix for Billink remaining price item -- Fix for Billink price rounding -- tags in description field [BP-688] -- Fix for AP, Klarna with MyParcel pick-up points [BP-563] -- In3 Order As missing Dutch translations [BP-689] -- Deliverytype error [BP-684] -- Apple pay error on product page and checkout [BP-687] -- It isn't possible to do refund for order with 10% discount and shipping costs [BP-587] - -= 2.18.0 = -- Fixed MyParcel pickup points issue -- Afterpay old update licence agreement in checkout [BP-656] -- Fixed notice for PayPerEmail [BP-632] -- Changed bancontact logo -- Added: PayPerEmail available in the front end [BP-632] -- Fixed: Incorrect error message for Afterpay Product quantity doesn't choose [BP-637] -- Fixed: Status is not pushed to WooCommerce shop [BP-611] -- Fixed: Payment method checkbox to enable/disable is not saved [BP-606] -- KBC logo is very large displayed in the checkout (Billink Request To Pay, In3) [BP-615] -- Added Payment method Billink [BP-480] -- Wordfence user agent & referrer [BP-572] - -= 2.17.0 = -- Fixed error in inspect console on every page of shop [BP-576] -- Add new bank to iDEAL payment method (Revolut) [BP-583] -- Fixed issue with Woocommerce Sequential Order Number Pro plugin compatibility -- Added payment method PayPerEmail [BP-564] -- Added carreir support for Afterpay in combination with pick-up points (Sendcloud, PostNL, DHL, MyParcel) [BP-563 ] -- Added payment data bank transfer to meta fields of order [BP-566] -- Credit Card: Added validation for 'Expiration Year' field [BP-532] - -= 2.16.4 = -- WooCommerce - new iDEAL logo not scaling correctly [BP-536] - -= 2.16.3 = -- Fixed partial refund is not working with USD currency [BP-525] -- Afterpay phone number is not asked when there is no phone number field in the checkout [BP-497] -- Fixed Creditcard empty fields issue -- Changed the order of inline Credit card (CSE) fields + fill name [BP-494] -- Fixed incorrect VAT for products with reduced VAT rate. [BP-472] -- Fixed Afterpay fee tax value [BP-472] -- Added error text for unselected creditcard [BP-453] -- Fixed incorrect refund shipping price error message [BP-411] -- .htaccess file changes [BP-422] -- Fixed not all information is send with Apple Pay (adress, phone#) [BP-387] -- Fix for Woocommerce Sequensial Order Number plugin compatibility -- Fixed error with refunds from Plaza to wordpress site using Woocommerce Sequential Order Number Pro plugin [BP-328] - -= 2.16.2 = - - Fix Payconiq transaction redirects to unknown page [BP-386] - - Fix payment fee Afterpay has wrong VAT percentage [BP-390] - - Fixed Notice: Undefined index:plugin_id - - Added translations for creditcard inline mode - -= 2.16.1 = - - Changed .htaccess file - -= 2.16.0 = - - In3 payment method [BP-305] - - Fixed compatibility with new Woocommerce Sequential Order Numbers Pro [BP-328] - - Fixed PHP Notice error [BP-344] - -= 2.15.0 = - - Incorrect VAT number BP-220 - - Fix Afterpay refund BP-220 - - Fix payment fee autorefund [BP-220] - - Add changes for VAT fee price [BP-220] - - KBC payment method [BP-219] - - Place order fails [BP-225] - - Request a change for an error message with custom gift cards (invalid retailer) [BP-236] - - Added payment method Request To Pay [BP-147] - - Apple pay button is not shown [BP-231] - - Fixed giftcards refunds error BP-170 - - Added giftcards group refunds message notification - - Trx Status updates [BP-167] - - Fix for Afterpay refund connected with reduced tax - - Fixed Afterpay taxes refund - - Afterpay Tax Refunds - added taxId value - - ApplePay - error request wit tax presence [BP-277] - - Fix applepay's customer card name error notification - -= 2.14.0 = - - Compatibility with WooCommerce 4.0.1 and WordPress 5.3.2 - - Solved issue with servicename for Carte Bleue payments - -= 2.13.2 = - - Compatibility with WooCommerce 3.9 - -= 2.13.1 = - - Fix for warning: Order ID was called incorrectly. - - Fix for error while processing creditcard refund. - - Compatibility with WooCommerce 3.8 - -= 2.13.0 = - - Apple Pay: Add CustomerCardName parameter to API call based on SDK response. - - Admin has availability to select which creditCard provider will be available in frontend by default all selected. - - Ideal: change translation domain from woocommerce to wc-buckaroo-bpe-gateway for error message in case ideal issuer not selected. - - Fix for warning: Customer ID was called incorrectly - - Compatibility with WooCommerce 3.7 - -= 2.12.1 = -- Updated readme.txt - -= 2.12.0 = - - Added new payment method: Apple Pay - -= 2.11.0 = - - Implemented inline creditcard options - - Implemented authorise and capture for creditcards - - Implemented Partial capture for creditcards - - Implemented Partial refund for all applicable payment methods - -= 2.10.2 = -- Compatibility with WooCommerce 3.6 - -= 2.10.1 = -- Updated manual with explanation about new AfterPay payment method. (Section 4.2.4) - -= 2.10.0 = -- Users can edit the giftcards available in the payment method configuration. -- New payment method Afterpay (new version) added. -- Fixed minor issue with loading the website key from the push response. - -= 2.9.0 = -- Adds new payment methods (Nexi, P24 and SEPA B2B), improves iDeal banks display, updates documentation with PayPal Seller Protection information - -= 2.8.3 = -- Fixing PHP warning with debug logfile - -= 2.8.2 = -- Added Handelsbanken as new iDeal bank - -= 2.8.1 = -- Enabled Payment Guarantee refund, fixed success redirect page for Payconiq and several small improvements - -= 2.8.0 = -- Added functionality to handle payment settlements for payment method Bank Transfer. - -= 2.7.0 = -- Added Payment Method Payconiq - -= 2.6.5 = -- Added Moneyou iDeal issuer - -= 2.6.4 = -- Fixed issue with the reading secretkey in push notifications - -= 2.6.3 = -- Fixed issue with the reading mastersettings in the configuration when settings are not set - -= 2.6.2 = -- Fixed issue with the reading mastersettings in the configuration - -= 2.6.1 = -- Use currency set in WooCommerce, rather than setting it seperately in the Plugin. -- Compatibility with WP-CLI -- Fixed an issue with the notification setting following the individual settings instead of the master settings -- Fixed an issue with Exodus sometimes being shown as payment method -- Added Westlandbon to available Giftcards - -= 2.6.0 = -- Added support for WooCommerce Sequential Order Numbers plugin by SkyVerge -- Only load JS files in wp-admin -- WooCommerce 3.2 support - -= 2.5.0 = -Admin modernised/improved -- Option to use single certificate across all payment methods added -- Certificates now added via 'upload Certificate' button -- Certificates now stored in database, rather than as network file -- Master settings page added, allows centralised setting of -- Language -- Transaction Description -- Use notification -- Notification Delay -- Merchant Key -- Secret Key -- Thumbrint -- Certificate -- Currency -- Transaction Mode -- Debug Mode added (records requests to & responses from buckaroo) -- Code modernised/imporved -- Docblocks added -- Old commented code removed -- Calls to WooCommerce & Buckaroo centralised in wrapper functions -- Include/require function centralised --Push Notifications Fixed --Missing translations added - -= 2.4.1 = -Calls to functions within empty() statements removed. Due to crashes with php 5.4 & below. - -= 2.4.0 = -Update plugin to work with WooCommerce 3.0. This includes the following changes: -- Fixed issue where duplicate orders were created. This happened when a payment method was chosen, then canceled and another was chosen to complete payment. -- Fixed function checking the version of WooCommerce. As it was only able to check if it was version 2. It now works, but will throw an exception in the log, if it breaks. -- Fixed an issue with the radio buttons to indicate gender were not rendering, on the afterpay and payment guarantee payment options. -- Fixed an issue with errors being thrown in the debug log, even with successful payments. Problem involved changing several functions across most payment methods. -- Updated calls to meet latest WooCommerce standards. -Removed pay guarantee by Juno from payment methods. - -= 2.3.4 = -Added AfterPay error messages in case consumer fills in incorrect personal information. -Updated explanations for various fields in the backend. - -= 2.3.3 = -Added Ippies to Giftcard payment method. -Fixed an issue with PayPal refund not sending an invoice number. -Fixed an issue with PayPal Seller Protection not working when Notification was disabled. - -= 2.3.2 = -Fixed redirect issues with certain payment methods. - -= 2.3.1 = -Fixed an issue where saving the payment fee didn't work. -Fixed an issue with redirect after a Sofort transaction. - -= 2.3.0 = -Fixed an issue with double order creation in combination with WooCommerce 2.6, plug-in is now officially compatible with WooCommerce 2.6. -Fixed an issue with Payment Guarantee when customer checks out as guest. -Added PayPal seller protection. - -= 2.2.12 = -Fixed an unintended result for error messages due to changes in 2.2.11. - -= 2.2.11 = -Removed checkout as company if AfterPay B2B is disabled in backend. -Added AfterPay error message in case of reject. - -= 2.2.10 = -Less AfterPay fields mandatory for B2B and different shipping address. -No longer creates order when frontend validation fails. -Fixed AfterPay issues in combination with discounts. -Added Carte Bancaire, Carte Bleue, Dankort and Visa Electron to creditcards. - -= 2.2.9 = -Changes on GroupID representation. - -= 2.2.8 = -iDeal choice of bank is mandatory, not automatically selecting ABN AMRO. - -= 2.2.7 = -Added VVV Giftcard to the existing list of giftcards. -Added Parfum Cadeaukaart Giftcard to the existing list of giftcards. -Fixed compatibility issue with WooCommerce 2.3. -Added possibility to choose payment fee tax mode(include/exclude). - -= 2.2.6 = -iDeal choice of bank is mandatory. -Fixed crashes if sopa extension not installed. -Invoice number change on transaction failure. -Added Bunq bank on iDeal list. -Problem with total amount fixed. -Unitprice with 2 decimals and it did count VAT in the order. - -= 2.2.5 = -Notification type fix. - -= 2.2.4 = -Strict mode notification fixed. - -= 2.2.3 = -Certificate directory updated to prevent delete PEM file on update. - -= 2.2.2 = -Updated plugin name. -Updated some translations. - -= 2.2.1 = -Renamed methods to make it more unique. -Added NL translations. - -= 2.2.0 = -Added payment fees to payment method. - -= 2.1.2 = -Initial version. diff --git a/src/Admin/GeneralSettings.php b/src/Admin/GeneralSettings.php index a9e099936..a71ec9dbd 100644 --- a/src/Admin/GeneralSettings.php +++ b/src/Admin/GeneralSettings.php @@ -23,6 +23,10 @@ public function __construct(WC_Settings_API $gateway) $this->label = __('Buckaroo Settings', 'wc-buckaroo-bpe-gateway'); parent::__construct(); + add_action( + 'woocommerce_admin_field_buckaroo_api_credentials', + [$this, 'render_api_credentials_card'] + ); add_action( 'woocommerce_admin_field_buckaroo_payment_list', [$this, 'render_payment_list'] @@ -78,9 +82,17 @@ public function output() switch ($current_section) { case '': - WC_Admin_Settings::output_fields($this->get_general_settings()); + $this->render_intro_card(); + $this->render_payment_list(); + $this->render_api_credentials_card_inner(); + echo '
'; + echo '

' . esc_html__('General Options', 'wc-buckaroo-bpe-gateway') . '

'; + echo '

' . esc_html__('Configure transaction, fee and locale settings.', 'wc-buckaroo-bpe-gateway') . '

'; + WC_Admin_Settings::output_fields($this->get_general_right_settings()); + echo '
'; break; case 'verification': + $this->render_verification_header(); WC_Admin_Settings::output_fields($this->get_verification_settings()); break; case 'advanced': @@ -101,24 +113,14 @@ public function output() } } - /** - * Get general settings - */ public function get_general_settings() { - $generalFields = [ - 'merchantkey', - 'secretkey', - 'test_credentials', - 'auto_configure', - 'transactiondescription', - 'refund_description', - 'feetax', - 'paymentfeevat', - 'culture' - ]; + return array_merge($this->get_general_top_settings(), $this->get_general_right_settings()); + } - $settings = [ + public function get_general_top_settings() + { + return [ [ 'title' => __('Buckaroo General Settings', 'wc-buckaroo-bpe-gateway'), 'type' => 'buckaroo_submeniu', @@ -144,21 +146,41 @@ public function get_general_settings() [ 'type' => 'buckaroo_payment_list', ], + [ + 'type' => 'sectionend', + 'id' => 'buckaroo-general-top', + ], + ]; + } + + public function get_general_right_settings() + { + $generalFields = [ + 'transactiondescription', + 'refund_description', + 'feetax', + 'paymentfeevat', + 'culture' + ]; + + $settings = [ + [ + 'type' => 'title', + 'id' => 'buckaroo-general-options', + 'title' => '', + ], ]; $settings = array_merge($settings, $this->get_fields_by_keys($generalFields)); $settings[] = [ 'type' => 'sectionend', - 'id' => 'buckaroo-general', + 'id' => 'buckaroo-general-options', ]; return $settings; } - /** - * Get verification settings - */ public function get_verification_settings() { $verificationFields = [ @@ -171,7 +193,6 @@ public function get_verification_settings() 'title' => __('Verification Settings', 'wc-buckaroo-bpe-gateway'), 'type' => 'title', 'id' => 'buckaroo-verification', - 'desc' => __('Configure verification settings for age verification and identity checking.', 'wc-buckaroo-bpe-gateway'), ], ]; @@ -185,9 +206,6 @@ public function get_verification_settings() return $settings; } - /** - * Get advanced settings - */ public function get_advanced_settings() { $advancedFields = [ @@ -214,19 +232,13 @@ public function get_advanced_settings() return $settings; } - /** - * Get specific fields by their keys - * - * @param array $fieldKeys - * @return array - */ public function get_fields_by_keys($fieldKeys) { $this->gateway->init_form_fields(); $fields = []; foreach ($fieldKeys as $id) { - if (!isset($this->gateway->form_fields[$id])) { + if (! isset($this->gateway->form_fields[$id])) { continue; } @@ -241,7 +253,7 @@ public function get_fields_by_keys($fieldKeys) $field, [ 'id' => $this->gateway->get_field_key($id), - 'desc' => $field['description'], + 'desc' => $field['description'] ?? '', 'value' => $this->gateway->get_option($id), 'type' => $type, ] @@ -262,85 +274,95 @@ protected function render_gateway_list() { ?>

-

- -

- - - - - - __('Method', 'wc-buckaroo-bpe-gateway'), - 'status' => __('Enabled', 'wc-buckaroo-bpe-gateway'), - 'action' => __('Actions', 'wc-buckaroo-bpe-gateway'), - ]; - foreach ($columns as $key => $column) { - echo ''; - } - ?> - - - +

+
+
+ + + + +
getBuckarooGateways() as $gateway) { - echo '
'; - - foreach ($columns as $key => $column) { - $method_title = $gateway->get_method_title() ? $gateway->get_method_title() : $gateway->get_title(); - $custom_title = $gateway->get_title(); - - $width = ''; - - if (in_array($key, ['status', 'action'], true)) { - $width = '1%'; - } - - echo ''; } - - echo ''; + ?> +
+
+ icon)) : ?> + <?php echo esc_attr($display_title); ?> + + + +
+
+
+
+ | ' . $currency_html); ?> +
+
+
+ + + + + + + + + + + + + + + + +
+
+ - -
' . esc_html($column) . '
'; + $method_title = $gateway->get_method_title() ? $gateway->get_method_title() : $gateway->get_title(); + $display_title = str_replace('Buckaroo ', '', $method_title); + $manage_url = admin_url('admin.php?page=wc-settings&tab=checkout§ion=' . strtolower($gateway->id)); + $is_enabled = wc_string_to_bool($gateway->enabled); + + $currencies = $gateway->getSupportedCurrencies(); + $countries = $gateway->getSupportedCountries(); + $european_countries = ['AT', 'BE', 'BG', 'CH', 'CY', 'CZ', 'DE', 'DK', 'EE', 'ES', 'FI', 'FR', 'GB', 'GR', 'HR', 'HU', 'IE', 'IS', 'IT', 'LI', 'LT', 'LU', 'LV', 'MT', 'NL', 'NO', 'PL', 'PT', 'RO', 'SE', 'SI', 'SK']; + + if (empty($countries)) { + $country_html = 'Global'; + } elseif (count($countries) >= 5 && count(array_diff($countries, $european_countries)) === 0) { + $country_html = 'Europe'; + } else { + $country_html = '' . implode(' · ', array_map('esc_html', $countries)) . ''; + } - switch ($key) { - case 'name': - echo '' . wp_kses_post(str_replace('Buckaroo ', '', $method_title)) . ''; - if ($method_title !== $custom_title) { - echo ' – ' . wp_kses_post($custom_title) . ''; - } - break; - case 'action': - if (wc_string_to_bool($gateway->enabled)) { - /* Translators: %s Payment gateway name. */ - echo '' . esc_html__('Manage', 'wc-buckaroo-bpe-gateway') . ''; - } else { - /* Translators: %s Payment gateway name. */ - echo '' . esc_html__('Set up', 'wc-buckaroo-bpe-gateway') . ''; - } - break; - case 'status': - echo ''; - if (wc_string_to_bool($gateway->enabled)) { - /* Translators: %s Payment gateway name. */ - echo '' . esc_attr__('Yes', 'wc-buckaroo-bpe-gateway') . ''; - } else { - /* Translators: %s Payment gateway name. */ - echo '' . esc_attr__('No', 'wc-buckaroo-bpe-gateway') . ''; - } - echo ''; - break; + $currency_html = count($currencies) >= 6 + ? 'Multi-currency' + : '' . implode(' · ', array_map('esc_html', $currencies)) . ''; + + $toggle_class = $is_enabled ? 'woocommerce-input-toggle--enabled' : 'woocommerce-input-toggle--disabled'; + $toggle_label = $is_enabled + /* Translators: %s Payment gateway name. */ + ? sprintf(__('The "%s" payment method is currently enabled', 'wc-buckaroo-bpe-gateway'), $method_title) + /* Translators: %s Payment gateway name. */ + : sprintf(__('The "%s" payment method is currently disabled', 'wc-buckaroo-bpe-gateway'), $method_title); + $toggle_text = $is_enabled ? __('Yes', 'wc-buckaroo-bpe-gateway') : __('No', 'wc-buckaroo-bpe-gateway'); + + $status_class = 'bk-status--disabled'; + $status_label = esc_html__('Inactive', 'wc-buckaroo-bpe-gateway'); + if ($is_enabled) { + $mode = isset($gateway->mode) ? strtolower((string) $gateway->mode) : 'test'; + if ($mode === 'live') { + $status_class = 'bk-status--live'; + $status_label = esc_html__('Active', 'wc-buckaroo-bpe-gateway'); + } else { + $status_class = 'bk-status--test'; + $status_label = esc_html__('Test', 'wc-buckaroo-bpe-gateway'); } - - echo '
- - + gateway->init_form_fields(); @@ -419,9 +438,6 @@ private function get_current_section_fields($section) return $sectionFields; } - /** - * Get field keys for a specific section - */ private function get_section_field_keys($section) { switch ($section) { @@ -461,44 +477,266 @@ public function getErrors() } } + + public function render_intro_card() + { + ?> +
+ +

+ +

+
+ + + + + + + + +
+
+ +
+
+ iDIN +
+
+
+
+
+ NL + EUR +
+
+
+ '; + $this->render_api_credentials_card_inner(); + echo ''; + } + + public function render_api_credentials_card_inner() + { + $merchant_key = $this->gateway->get_option('merchantkey', ''); + $secret_key = $this->gateway->get_option('secretkey', ''); + $merchant_key_id = $this->gateway->get_field_key('merchantkey'); + $secret_key_id = $this->gateway->get_field_key('secretkey'); + + $this->gateway->init_form_fields(); + $test_btn_field = $this->gateway->form_fields['test_credentials'] ?? null; + $auto_btn_field = $this->gateway->form_fields['auto_configure'] ?? null; + ?> +
+ +

+

+ + + + + + + + + + + + + +
+ + +
+ + + $val) { + $test_custom_attrs .= esc_attr($attr) . '="' . esc_attr($val) . '" '; + } + ?> + + +
+
+ + +
+ + + $val) { + $auto_custom_attrs .= esc_attr($attr) . '="' . esc_attr($val) . '" '; + } + ?> + + +
+
+
+ + + getBuckarooGateways(); - $containerHeight = ceil(count($gateways) / 3) * 45; ?> - + 'off', ]; $this->form_fields['culture'] = [ - 'title' => __('Language', 'wc-buckaroo-bpe-gateway'), + 'title' => __('Payment page language', 'wc-buckaroo-bpe-gateway'), 'type' => 'select', - 'description' => __( - "The chosen language (culture) for the Buckaroo payment engine
page. -When this is set to “Dynamic language” the plugin will
automatically determine the language based on the -language
settings of the customer's web browser. Please note that we only
support the following languages: English, Dutch, German and French.
-English will be used as a fallback language for unknown language types.", - 'wc-buckaroo-bpe-gateway' - ), + 'description' => __('Select the Buckaroo payment page language. “Dynamic language” uses the customer’s browser language, with English as fallback.', 'wc-buckaroo-bpe-gateway'), 'options' => [ 'dynamic' => 'Dynamic language (based on the web browser language)', 'en-US' => 'English', @@ -146,19 +140,17 @@ public function init_form_fields() ]; $this->form_fields['transactiondescription'] = [ - 'title' => __('Transaction description', 'wc-buckaroo-bpe-gateway'), - 'type' => 'textarea', - 'description' => __('Transaction description', 'wc-buckaroo-bpe-gateway'), - 'desc_tip' => __('Transaction description can be filled with static text and tags like: {order_number}, {shop_name} and {product_name} for first product found.'), - 'default' => '', + 'title' => __('Transaction description', 'wc-buckaroo-bpe-gateway'), + 'type' => 'textarea', + 'desc_tip' => __('Available tags: {order_number}, {shop_name}, {product_name} (first product).', 'wc-buckaroo-bpe-gateway'), + 'default' => '', ]; $this->form_fields['refund_description'] = [ - 'title' => __('Refund description', 'wc-buckaroo-bpe-gateway'), - 'type' => 'textarea', - 'description' => __('Refund description', 'wc-buckaroo-bpe-gateway'), - 'desc_tip' => __('Refund description can be filled with static text and tags like: {order_number}, {shop_name} and {product_name} for first product found.'), - 'default' => '', + 'title' => __('Refund description', 'wc-buckaroo-bpe-gateway'), + 'type' => 'textarea', + 'desc_tip' => __('Available tags: {order_number}, {shop_name}, {product_name} (first product).', 'wc-buckaroo-bpe-gateway'), + 'default' => '', ]; $this->apply_filter_or_error('append_subscription_configurationCode_in_setting_field', $this); diff --git a/src/Gateways/AbstractPaymentGateway.php b/src/Gateways/AbstractPaymentGateway.php index 32c4492b0..75066458c 100644 --- a/src/Gateways/AbstractPaymentGateway.php +++ b/src/Gateways/AbstractPaymentGateway.php @@ -49,8 +49,13 @@ class AbstractPaymentGateway extends WC_Payment_Gateway protected array $supportedCurrencies = ['EUR']; + /** ISO 3166-1 alpha-2 country codes. Empty = worldwide / no restriction. */ + protected array $supportedCountries = []; + public bool $capturable = false; + public $method_description = ''; + public function __construct() { // Load the form fields @@ -134,7 +139,7 @@ public function init_form_fields() 'default' => 'test', ], 'title' => [ - 'title' => __('Front-end label', 'wc-buckaroo-bpe-gateway'), + 'title' => __('Title', 'wc-buckaroo-bpe-gateway'), 'type' => 'text', 'description' => __( 'Determines how the payment method is named in the checkout.', @@ -428,12 +433,98 @@ public function action_woocommerce_checkout_process() public function generate_buckaroo_notice_html($key, $data) { - // Add Warning, if currency set in Buckaroo is unsupported - if (isset($_GET['section']) && $this->id == sanitize_text_field($_GET['section']) && ! $this->checkCurrencySupported() && is_admin()) { - $message = esc_html__('This payment method is not supported for the selected currency ', 'wc-buckaroo-bpe-gateway') . '(' . esc_html(get_woocommerce_currency()) . ')'; + if (! isset($_GET['section']) || $this->id !== sanitize_text_field($_GET['section']) || ! is_admin()) { + return; + } + + $method_title = $this->get_method_title() ?: $this->get_title(); + $display_title = str_replace('Buckaroo ', '', $method_title); + $currencies = $this->getSupportedCurrencies(); + $countries = $this->getSupportedCountries(); + $is_enabled = $this->enabled === 'yes'; + $mode = strtolower((string) $this->get_option('mode', 'test')); + + if ($is_enabled) { + if ($mode === 'live') { + $status_class = 'bk-status--live'; + $status_label = __('Active', 'wc-buckaroo-bpe-gateway'); + } else { + $status_class = 'bk-status--test'; + $status_label = __('Test', 'wc-buckaroo-bpe-gateway'); + } + } else { + $status_class = 'bk-status--disabled'; + $status_label = __('Inactive', 'wc-buckaroo-bpe-gateway'); + } + + $description = $this->method_description !== '' + ? $this->method_description + : $this->getPaymentDescription(); + + echo '
'; + + echo '
'; + if (! empty($this->icon)) { + echo '' . esc_attr($display_title) . ''; + } else { + echo '' . esc_html(strtoupper(substr($display_title, 0, 2))) . ''; + } + echo '
'; + + echo '
'; + echo '
' . esc_html($display_title) . '
'; + echo '
' . esc_html($description) . '
'; + $european_countries = ['AT', 'BE', 'BG', 'CH', 'CY', 'CZ', 'DE', 'DK', 'EE', 'ES', 'FI', 'FR', 'GB', 'GR', 'HR', 'HU', 'IE', 'IS', 'IT', 'LI', 'LT', 'LU', 'LV', 'MT', 'NL', 'NO', 'PL', 'PT', 'RO', 'SE', 'SI', 'SK']; - return printf('

%s

', $message); + if (empty($countries)) { + $country_label = 'Global'; + } elseif (count($countries) >= 5 && count(array_diff($countries, $european_countries)) === 0) { + $country_label = 'Europe'; + } else { + $country_label = implode(' · ', $countries); } + + $currency_label = count($currencies) >= 6 ? 'Multi-currency' : implode(' · ', $currencies); + + echo '
'; + echo '' . esc_html($country_label) . ''; + echo '' . esc_html($currency_label) . ''; + echo '
'; + echo '
'; + + echo '
'; + echo '' . esc_html($status_label) . ''; + echo '
'; + + echo '
'; + + if (! $this->checkCurrencySupported()) { + $message = esc_html__('This payment method is not supported for the selected currency ', 'wc-buckaroo-bpe-gateway') . '(' . esc_html(get_woocommerce_currency()) . ')'; + printf('

%s

', $message); + } + + ?> + + supportedCurrencies); } + public function getSupportedCurrencies(): array + { + return $this->supportedCurrencies; + } + + public function getSupportedCountries(): array + { + return $this->supportedCountries; + } + public function canShowCaptureForm($order): bool { return false; diff --git a/src/Gateways/Afterpay/AfterpayNewGateway.php b/src/Gateways/Afterpay/AfterpayNewGateway.php index 5cd91050c..566061585 100644 --- a/src/Gateways/Afterpay/AfterpayNewGateway.php +++ b/src/Gateways/Afterpay/AfterpayNewGateway.php @@ -17,6 +17,8 @@ class AfterpayNewGateway extends AbstractPaymentGateway public const REFUND_CLASS = AfterpayNewRefundProcessor::class; + protected array $supportedCountries = ['NL', 'BE', 'DE']; + public const CUSTOMER_TYPE_B2C = 'b2c'; public const CUSTOMER_TYPE_B2B = 'b2b'; @@ -41,6 +43,7 @@ public function __construct() { $this->id = 'buckaroo_afterpaynew'; $this->title = 'Riverty'; + $this->method_description = __('European pay-after-delivery within 30 days.', 'wc-buckaroo-bpe-gateway'); $this->has_fields = false; $this->method_title = 'Buckaroo Riverty'; $this->setIcon('svg/afterpay.svg'); diff --git a/src/Gateways/Afterpay/AfterpayOldGateway.php b/src/Gateways/Afterpay/AfterpayOldGateway.php index 7ae7496cb..baa0889d8 100644 --- a/src/Gateways/Afterpay/AfterpayOldGateway.php +++ b/src/Gateways/Afterpay/AfterpayOldGateway.php @@ -16,6 +16,8 @@ class AfterpayOldGateway extends AbstractPaymentGateway public const REFUND_CLASS = AbstractAfterpayRefundProcessor::class; + protected array $supportedCountries = ['NL', 'BE', 'DE']; + public $type; public $b2b; @@ -32,6 +34,7 @@ public function __construct() { $this->id = 'buckaroo_afterpay'; $this->title = 'Riverty'; + $this->method_description = __('Riverty via the older API integration, for merchants not yet migrated.', 'wc-buckaroo-bpe-gateway'); $this->has_fields = false; $this->method_title = 'Buckaroo Riverty (Old)'; $this->setIcon('svg/afterpay.svg'); diff --git a/src/Gateways/Alipay/AlipayGateway.php b/src/Gateways/Alipay/AlipayGateway.php index b8b85947e..9b8818400 100644 --- a/src/Gateways/Alipay/AlipayGateway.php +++ b/src/Gateways/Alipay/AlipayGateway.php @@ -6,10 +6,13 @@ class AlipayGateway extends AbstractPaymentGateway { + protected array $supportedCountries = ['CN']; + public function __construct() { $this->id = 'buckaroo_alipay'; $this->title = 'Alipay'; + $this->method_description = __("One of the world's largest mobile wallets, widely used by shoppers in China.", 'wc-buckaroo-bpe-gateway'); $this->has_fields = false; $this->method_title = 'Buckaroo Alipay'; $this->setIcon('svg/alipay.svg'); diff --git a/src/Gateways/Applepay/ApplepayGateway.php b/src/Gateways/Applepay/ApplepayGateway.php index dd03298c0..c141343b2 100644 --- a/src/Gateways/Applepay/ApplepayGateway.php +++ b/src/Gateways/Applepay/ApplepayGateway.php @@ -26,6 +26,7 @@ public function __construct() { $this->id = 'buckaroo_applepay'; $this->title = 'Apple Pay'; + $this->method_description = __("Apple's mobile wallet for quick, secure payments via Face ID or Touch ID on Apple devices.", 'wc-buckaroo-bpe-gateway'); $this->has_fields = true; $this->method_title = 'Buckaroo Apple Pay'; $this->CustomerCardName = ''; diff --git a/src/Gateways/Bancontact/BancontactGateway.php b/src/Gateways/Bancontact/BancontactGateway.php index 51cf4b774..58d79df60 100644 --- a/src/Gateways/Bancontact/BancontactGateway.php +++ b/src/Gateways/Bancontact/BancontactGateway.php @@ -6,10 +6,13 @@ class BancontactGateway extends AbstractPaymentGateway { + protected array $supportedCountries = ['BE']; + public function __construct() { $this->id = 'buckaroo_bancontactmrcash'; $this->title = 'Bancontact'; + $this->method_description = __("Belgium's most popular payment method, linked directly to the shopper's own bank.", 'wc-buckaroo-bpe-gateway'); $this->has_fields = false; $this->method_title = 'Buckaroo Bancontact'; $this->setIcon('svg/bancontact.svg'); diff --git a/src/Gateways/Belfius/BelfiusGateway.php b/src/Gateways/Belfius/BelfiusGateway.php index 8c6dccdf3..38d4ca9ba 100644 --- a/src/Gateways/Belfius/BelfiusGateway.php +++ b/src/Gateways/Belfius/BelfiusGateway.php @@ -6,10 +6,13 @@ class BelfiusGateway extends AbstractPaymentGateway { + protected array $supportedCountries = ['BE']; + public function __construct() { $this->id = 'buckaroo_belfius'; $this->title = 'Belfius'; + $this->method_description = __('Direct, guaranteed bank payments for customers of Belfius, a major Belgian bank.', 'wc-buckaroo-bpe-gateway'); $this->has_fields = false; $this->method_title = 'Buckaroo Belfius'; $this->setIcon('svg/belfius.svg'); diff --git a/src/Gateways/Billink/BillinkGateway.php b/src/Gateways/Billink/BillinkGateway.php index bd5a8b1b0..e7c9d9152 100644 --- a/src/Gateways/Billink/BillinkGateway.php +++ b/src/Gateways/Billink/BillinkGateway.php @@ -9,6 +9,8 @@ class BillinkGateway extends AbstractPaymentGateway { use HasDateValidation; + protected array $supportedCountries = ['NL', 'BE']; + public const PAYMENT_CLASS = BillinkProcessor::class; public $type; @@ -25,6 +27,7 @@ public function __construct() { $this->id = 'buckaroo_billink'; $this->title = 'Billink'; + $this->method_description = __('Dutch pay-after-delivery by invoice with a 14-day term, for private and business customers.', 'wc-buckaroo-bpe-gateway'); $this->has_fields = true; $this->method_title = 'Buckaroo Billink'; $this->setIcon('svg/billink.svg'); diff --git a/src/Gateways/Bizum/BizumGateway.php b/src/Gateways/Bizum/BizumGateway.php index 6e768c7c3..9b735192b 100644 --- a/src/Gateways/Bizum/BizumGateway.php +++ b/src/Gateways/Bizum/BizumGateway.php @@ -10,12 +10,13 @@ public function __construct() { $this->id = 'buckaroo_bizum'; $this->title = 'Bizum'; + $this->method_description = __("Spain's mobile payment method, with instant bank-to-bank transfers via phone number.", 'wc-buckaroo-bpe-gateway'); $this->has_fields = false; $this->method_title = 'Buckaroo Bizum'; $this->setIcon('svg/bizum.svg'); - // Bizum supports EUR only (default already contains EUR) $this->supportedCurrencies = ['EUR']; + $this->supportedCountries = ['ES']; parent::__construct(); $this->addRefundSupport(); diff --git a/src/Gateways/Blik/BlikGateway.php b/src/Gateways/Blik/BlikGateway.php index 33cd7d30a..62c78b717 100644 --- a/src/Gateways/Blik/BlikGateway.php +++ b/src/Gateways/Blik/BlikGateway.php @@ -7,6 +7,7 @@ class BlikGateway extends AbstractPaymentGateway { protected array $supportedCurrencies = ['PLN']; + protected array $supportedCountries = ['PL']; public function __construct() { diff --git a/src/Gateways/CreditCard/Cards/CartebancaireGateway.php b/src/Gateways/CreditCard/Cards/CartebancaireGateway.php index 583c63bac..6dbfa6bc8 100644 --- a/src/Gateways/CreditCard/Cards/CartebancaireGateway.php +++ b/src/Gateways/CreditCard/Cards/CartebancaireGateway.php @@ -4,6 +4,8 @@ class CartebancaireGateway extends SingleCreditCardGateway { + protected array $supportedCountries = ['FR']; + public function setParameters() { $this->id = 'buckaroo_creditcard_cartebancaire'; diff --git a/src/Gateways/CreditCard/Cards/CartebleuevisaGateway.php b/src/Gateways/CreditCard/Cards/CartebleuevisaGateway.php index 0a1ca7b7d..1c39b7038 100644 --- a/src/Gateways/CreditCard/Cards/CartebleuevisaGateway.php +++ b/src/Gateways/CreditCard/Cards/CartebleuevisaGateway.php @@ -4,6 +4,8 @@ class CartebleuevisaGateway extends SingleCreditCardGateway { + protected array $supportedCountries = ['FR']; + public function setParameters() { $this->id = 'buckaroo_creditcard_cartebleuevisa'; diff --git a/src/Gateways/CreditCard/Cards/DankortGateway.php b/src/Gateways/CreditCard/Cards/DankortGateway.php index c3c1d0d29..afd77dd43 100644 --- a/src/Gateways/CreditCard/Cards/DankortGateway.php +++ b/src/Gateways/CreditCard/Cards/DankortGateway.php @@ -4,6 +4,8 @@ class DankortGateway extends SingleCreditCardGateway { + protected array $supportedCountries = ['DK']; + public function setParameters() { $this->id = 'buckaroo_creditcard_dankort'; diff --git a/src/Gateways/CreditCard/Cards/NexiGateway.php b/src/Gateways/CreditCard/Cards/NexiGateway.php index df6fc27d4..935e6907c 100644 --- a/src/Gateways/CreditCard/Cards/NexiGateway.php +++ b/src/Gateways/CreditCard/Cards/NexiGateway.php @@ -4,6 +4,8 @@ class NexiGateway extends SingleCreditCardGateway { + protected array $supportedCountries = ['IT']; + public function setParameters() { $this->id = 'buckaroo_creditcard_nexi'; diff --git a/src/Gateways/CreditCard/Cards/PostepayGateway.php b/src/Gateways/CreditCard/Cards/PostepayGateway.php index 99df37cee..04d0f9248 100644 --- a/src/Gateways/CreditCard/Cards/PostepayGateway.php +++ b/src/Gateways/CreditCard/Cards/PostepayGateway.php @@ -4,6 +4,8 @@ class PostepayGateway extends SingleCreditCardGateway { + protected array $supportedCountries = ['IT']; + public function setParameters() { $this->id = 'buckaroo_creditcard_postepay'; diff --git a/src/Gateways/CreditCard/CreditCardGateway.php b/src/Gateways/CreditCard/CreditCardGateway.php index b562c0587..c6ecc5e99 100644 --- a/src/Gateways/CreditCard/CreditCardGateway.php +++ b/src/Gateways/CreditCard/CreditCardGateway.php @@ -74,6 +74,7 @@ public function __construct() $this->addRefundSupport(); add_action('wp_enqueue_scripts', [$this, 'enqueue_scripts']); + add_action('admin_footer', [$this, 'admin_inline_script_hosted_fields_toggle']); if (version_compare(WOOCOMMERCE_VERSION, '2.0.0', '>=')) { $this->registerControllers(); @@ -87,6 +88,52 @@ private function registerControllers() add_action("{$namespace}-hosted-fields-token", [HostedFieldsController::class, 'getToken']); } + /** + * Output JS to toggle hosted-fields rows based on the selected payment method. + * Hooked into admin_footer when the creditcard settings page is active. + * + * @return void + */ + public function admin_inline_script_hosted_fields_toggle() + { + if ( + ! isset($_GET['section']) || + $this->id !== sanitize_text_field($_GET['section']) || + ! is_admin() + ) { + return; + } + $select_id = esc_js($this->get_field_key('creditcardmethod')); + $id_field = esc_js($this->get_field_key('hosted_fields_client_id')); + $sec_field = esc_js($this->get_field_key('hosted_fields_client_secret')); + ?> + + id = 'buckaroo_eps'; diff --git a/src/Gateways/GiftCard/GiftCardGateway.php b/src/Gateways/GiftCard/GiftCardGateway.php index 11caa7b58..d8f40f105 100644 --- a/src/Gateways/GiftCard/GiftCardGateway.php +++ b/src/Gateways/GiftCard/GiftCardGateway.php @@ -8,6 +8,8 @@ class GiftCardGateway extends AbstractPaymentGateway { public const PAYMENT_CLASS = GiftCardProcessor::class; + protected array $supportedCountries = ['NL']; + public $giftcards; public function __construct() diff --git a/src/Gateways/Googlepay/GooglepayGateway.php b/src/Gateways/Googlepay/GooglepayGateway.php index 144e22b48..2c89b4595 100644 --- a/src/Gateways/Googlepay/GooglepayGateway.php +++ b/src/Gateways/Googlepay/GooglepayGateway.php @@ -23,6 +23,7 @@ public function __construct() { $this->id = 'buckaroo_googlepay'; $this->title = 'Google Pay'; + $this->method_description = __("Google's wallet, using the cards saved to a shopper's Google Account.", 'wc-buckaroo-bpe-gateway'); $this->has_fields = true; $this->method_title = 'Buckaroo Google Pay'; $this->CustomerCardName = ''; @@ -499,9 +500,9 @@ protected function set_guid_after_usemaster() $new_form_fields[$k] = $value; if ($k === 'mode') { $new_form_fields['merchant_guid'] = [ - 'title' => __('GUID', 'wc-buckaroo-bpe-gateway'), + 'title' => __('Gateway Merchant ID', 'wc-buckaroo-bpe-gateway'), 'type' => 'text', - 'description' => __('The Buckaroo GUID which can be found in the Buckaroo Plaza > My Buckaroo > General.', 'wc-buckaroo-bpe-gateway'), + 'description' => __('The Buckaroo Gateway merchant ID which can be found in the Buckaroo Plaza → Services -> Google Pay.', 'wc-buckaroo-bpe-gateway'), 'default' => '0', ]; $new_form_fields['google_merchant_id'] = [ diff --git a/src/Gateways/Ideal/IdealGateway.php b/src/Gateways/Ideal/IdealGateway.php index d54973d60..5dfd1dd84 100644 --- a/src/Gateways/Ideal/IdealGateway.php +++ b/src/Gateways/Ideal/IdealGateway.php @@ -8,10 +8,13 @@ class IdealGateway extends AbstractPaymentGateway { public const PAYMENT_CLASS = IdealProcessor::class; + protected array $supportedCountries = ['NL']; + public function __construct() { $this->id = 'buckaroo_ideal'; $this->title = 'iDEAL | Wero'; + $this->method_description = __("The Netherlands' most-used online payment method, via the shopper's own bank, now co-branded with Wero.", 'wc-buckaroo-bpe-gateway'); $this->has_fields = true; $this->method_title = 'Buckaroo iDEAL | Wero'; $this->setIcon('svg/ideal-wero.svg'); diff --git a/src/Gateways/In3/In3Gateway.php b/src/Gateways/In3/In3Gateway.php index afaa70d92..57ae93912 100644 --- a/src/Gateways/In3/In3Gateway.php +++ b/src/Gateways/In3/In3Gateway.php @@ -12,6 +12,8 @@ class In3Gateway extends AbstractPaymentGateway public const PAYMENT_CLASS = In3Processor::class; + protected array $supportedCountries = ['NL']; + public $type; public $vattype; @@ -23,7 +25,7 @@ public function __construct() $this->id = 'buckaroo_in3'; $this->has_fields = false; $this->method_title = 'Buckaroo In3'; - + $this->method_description = __('Interest-free payment in three instalments over 60 days, settled via iDEAL.', 'wc-buckaroo-bpe-gateway'); $this->title = 'In3'; $this->setCountry(); diff --git a/src/Gateways/Kbc/KbcGateway.php b/src/Gateways/Kbc/KbcGateway.php index 34dc7df11..bd5ad6315 100644 --- a/src/Gateways/Kbc/KbcGateway.php +++ b/src/Gateways/Kbc/KbcGateway.php @@ -6,10 +6,13 @@ class KbcGateway extends AbstractPaymentGateway { + protected array $supportedCountries = ['BE']; + public function __construct() { $this->id = 'buckaroo_kbc'; $this->title = 'KBC'; + $this->method_description = __('Direct bank payments for customers of KBC/CBC in Belgium.', 'wc-buckaroo-bpe-gateway'); $this->has_fields = false; $this->method_title = 'Buckaroo KBC'; $this->setIcon('svg/kbc.svg'); diff --git a/src/Gateways/Klarna/KlarnaGateway.php b/src/Gateways/Klarna/KlarnaGateway.php index 048474b00..ce060d1b8 100644 --- a/src/Gateways/Klarna/KlarnaGateway.php +++ b/src/Gateways/Klarna/KlarnaGateway.php @@ -8,6 +8,8 @@ class KlarnaGateway extends AbstractPaymentGateway { public const PAYMENT_CLASS = KlarnaProcessor::class; + protected array $supportedCountries = ['DE', 'AT', 'SE', 'NO', 'FI', 'DK', 'NL', 'CH', 'GB', 'BE']; + protected $type; protected $vattype; @@ -18,6 +20,7 @@ public function __construct() { $this->has_fields = true; $this->type = 'klarna'; + $this->method_description = __('Klarna pay-later and instalment options, with Klarna acting as Merchant of Record.', 'wc-buckaroo-bpe-gateway'); $this->setIcon('svg/klarna.svg'); $this->setCountry(); diff --git a/src/Gateways/Klarna/KlarnaKpGateway.php b/src/Gateways/Klarna/KlarnaKpGateway.php index 3ef68f0cb..56dd80e28 100644 --- a/src/Gateways/Klarna/KlarnaKpGateway.php +++ b/src/Gateways/Klarna/KlarnaKpGateway.php @@ -21,7 +21,8 @@ public function __construct() { $this->id = 'buckaroo_klarnakp'; $this->title = 'Klarna: Pay later'; - $this->method_title = 'Buckaroo Klarna Pay later (authorize/capture)'; + $this->method_description = __('Klarna pay-after-delivery, authorized at checkout and captured on shipment.', 'wc-buckaroo-bpe-gateway'); + $this->method_title = 'Klarna (KP)'; $this->has_fields = true; $this->type = 'klarnakp'; $this->klarnaPaymentFlowId = 'pay'; diff --git a/src/Gateways/Klarna/KlarnaPayGateway.php b/src/Gateways/Klarna/KlarnaPayGateway.php index 72ba7b299..32b5c2687 100644 --- a/src/Gateways/Klarna/KlarnaPayGateway.php +++ b/src/Gateways/Klarna/KlarnaPayGateway.php @@ -17,6 +17,7 @@ public function __construct() { $this->id = 'buckaroo_klarnapay'; $this->title = 'Klarna'; + $this->method_description = __('Klarna pay-later and instalment options, with Klarna acting as Merchant of Record.', 'wc-buckaroo-bpe-gateway'); $this->method_title = 'Klarna (MoR)'; parent::__construct(); diff --git a/src/Gateways/KnakenSettle/KnakenSettleGateway.php b/src/Gateways/KnakenSettle/KnakenSettleGateway.php index a49a5f161..7de648d40 100644 --- a/src/Gateways/KnakenSettle/KnakenSettleGateway.php +++ b/src/Gateways/KnakenSettle/KnakenSettleGateway.php @@ -6,10 +6,13 @@ class KnakenSettleGateway extends AbstractPaymentGateway { + protected array $supportedCountries = ['NL']; + public function __construct() { $this->id = 'buckaroo_knaken'; $this->title = 'goSettle'; + $this->method_description = __('Crypto payment method accepting digital assets such as Bitcoin, Ethereum and USDC.', 'wc-buckaroo-bpe-gateway'); $this->has_fields = false; $this->method_title = 'Buckaroo goSettle'; $this->setIcon('svg/goSettle.svg'); diff --git a/src/Gateways/MbWay/MbWayGateway.php b/src/Gateways/MbWay/MbWayGateway.php index 1bd261395..3938303a2 100644 --- a/src/Gateways/MbWay/MbWayGateway.php +++ b/src/Gateways/MbWay/MbWayGateway.php @@ -6,6 +6,8 @@ class MbWayGateway extends AbstractPaymentGateway { + protected array $supportedCountries = ['PT']; + public function __construct() { $this->id = 'buckaroo_mbway'; diff --git a/src/Gateways/Multibanco/MultibancoGateway.php b/src/Gateways/Multibanco/MultibancoGateway.php index a279a2317..1c62aa3d4 100644 --- a/src/Gateways/Multibanco/MultibancoGateway.php +++ b/src/Gateways/Multibanco/MultibancoGateway.php @@ -6,6 +6,8 @@ class MultibancoGateway extends AbstractPaymentGateway { + protected array $supportedCountries = ['PT']; + public function __construct() { $this->id = 'buckaroo_multibanco'; diff --git a/src/Gateways/PayByBank/PayByBankGateway.php b/src/Gateways/PayByBank/PayByBankGateway.php index b0976090e..faad72759 100644 --- a/src/Gateways/PayByBank/PayByBankGateway.php +++ b/src/Gateways/PayByBank/PayByBankGateway.php @@ -8,6 +8,8 @@ class PayByBankGateway extends AbstractPaymentGateway { public const PAYMENT_CLASS = PayByBankProcessor::class; + protected array $supportedCountries = ['NL', 'BE', 'DE', 'GB']; + public function __construct() { $this->id = 'buckaroo_paybybank'; diff --git a/src/Gateways/PayPerEmail/PayPerEmailGateway.php b/src/Gateways/PayPerEmail/PayPerEmailGateway.php index 653f7cc1f..c0385436d 100644 --- a/src/Gateways/PayPerEmail/PayPerEmailGateway.php +++ b/src/Gateways/PayPerEmail/PayPerEmailGateway.php @@ -47,6 +47,7 @@ public function __construct() { $this->id = 'buckaroo_payperemail'; $this->title = 'PayPerEmail'; + $this->method_description = __('Buckaroo service for sending customers a payment request by email with a secure pay link.', 'wc-buckaroo-bpe-gateway'); $this->has_fields = true; $this->method_title = 'Buckaroo PayPerEmail'; $this->setIcon('svg/payperemail.svg'); diff --git a/src/Gateways/Payconiq/PayconiqGateway.php b/src/Gateways/Payconiq/PayconiqGateway.php index 08dc60be4..ec9eab3e9 100644 --- a/src/Gateways/Payconiq/PayconiqGateway.php +++ b/src/Gateways/Payconiq/PayconiqGateway.php @@ -6,6 +6,8 @@ class PayconiqGateway extends AbstractPaymentGateway { + protected array $supportedCountries = ['BE', 'LU']; + public function __construct() { $this->id = 'buckaroo_payconiq'; diff --git a/src/Gateways/Paypal/PaypalGateway.php b/src/Gateways/Paypal/PaypalGateway.php index 2958b4faf..74835f66e 100644 --- a/src/Gateways/Paypal/PaypalGateway.php +++ b/src/Gateways/Paypal/PaypalGateway.php @@ -46,6 +46,7 @@ public function __construct() { $this->id = 'buckaroo_paypal'; $this->title = 'PayPal'; + $this->method_description = __('Global digital wallet with card and balance payments, plus Buyer Protection.', 'wc-buckaroo-bpe-gateway'); $this->has_fields = false; $this->method_title = 'Buckaroo PayPal'; $this->setIcon('svg/paypal.svg'); diff --git a/src/Gateways/Przelewy24/Przelewy24Gateway.php b/src/Gateways/Przelewy24/Przelewy24Gateway.php index 028267b0d..9f289465d 100644 --- a/src/Gateways/Przelewy24/Przelewy24Gateway.php +++ b/src/Gateways/Przelewy24/Przelewy24Gateway.php @@ -9,11 +9,13 @@ class Przelewy24Gateway extends AbstractPaymentGateway public const PAYMENT_CLASS = Przelewy24Processor::class; protected array $supportedCurrencies = ['EUR', 'PLN']; + protected array $supportedCountries = ['PL']; public function __construct() { $this->id = 'buckaroo_przelewy24'; $this->title = 'Przelewy24'; + $this->method_description = __("Poland's leading online payment platform, connecting 165+ local banks and methods.", 'wc-buckaroo-bpe-gateway'); $this->has_fields = false; $this->method_title = 'Buckaroo Przelewy24'; $this->setIcon('svg/przelewy24.svg'); diff --git a/src/Gateways/SepaDirectDebit/SepaDirectDebitGateway.php b/src/Gateways/SepaDirectDebit/SepaDirectDebitGateway.php index 9fb74b3c1..9b3e5c4a7 100644 --- a/src/Gateways/SepaDirectDebit/SepaDirectDebitGateway.php +++ b/src/Gateways/SepaDirectDebit/SepaDirectDebitGateway.php @@ -8,10 +8,13 @@ class SepaDirectDebitGateway extends AbstractPaymentGateway { public const PAYMENT_CLASS = SepaDirectDebitProcessor::class; + protected array $supportedCountries = ['AT', 'BE', 'DE', 'ES', 'FR', 'GB', 'IT', 'NL', 'PT', 'LU']; + public function __construct() { $this->id = 'buckaroo_sepadirectdebit'; $this->title = 'SEPA Direct Debit'; + $this->method_description = __("One-off collection from the customer's bank account via a SEPA mandate.", 'wc-buckaroo-bpe-gateway'); $this->has_fields = false; $this->method_title = 'Buckaroo SEPA Direct Debit'; $this->setIcon('svg/sepa-directdebit.svg'); diff --git a/src/Gateways/Swish/SwishGateway.php b/src/Gateways/Swish/SwishGateway.php index 430215605..744f028f3 100644 --- a/src/Gateways/Swish/SwishGateway.php +++ b/src/Gateways/Swish/SwishGateway.php @@ -12,9 +12,10 @@ public function __construct() $this->title = 'Swish'; $this->has_fields = false; $this->method_title = 'Buckaroo Swish'; - $this->method_description = __('Swish is Sweden\'s real-time mobile payment method, authorized via BankID.', 'wc-buckaroo-bpe-gateway'); + $this->method_description = __("Sweden's real-time mobile payment method, authorized via BankID.", 'wc-buckaroo-bpe-gateway'); $this->setIcon('svg/swish.svg'); $this->supportedCurrencies = ['SEK']; + $this->supportedCountries = ['SE']; parent::__construct(); $this->addRefundSupport(); } diff --git a/src/Gateways/Transfer/TransferGateway.php b/src/Gateways/Transfer/TransferGateway.php index 2704a7e8b..515f6344c 100644 --- a/src/Gateways/Transfer/TransferGateway.php +++ b/src/Gateways/Transfer/TransferGateway.php @@ -21,6 +21,7 @@ public function __construct() { $this->id = 'buckaroo_transfer'; $this->title = 'Bank Transfer'; + $this->method_description = __('Manual bank transfer, with payment instructions provided to the customer after checkout.', 'wc-buckaroo-bpe-gateway'); $this->has_fields = false; $this->method_title = 'Buckaroo Bank Transfer'; $this->setIcon('svg/sepa-credittransfer.svg'); diff --git a/src/Gateways/Trustly/TrustlyGateway.php b/src/Gateways/Trustly/TrustlyGateway.php index 610e4b67e..2e78c86a2 100644 --- a/src/Gateways/Trustly/TrustlyGateway.php +++ b/src/Gateways/Trustly/TrustlyGateway.php @@ -9,6 +9,7 @@ class TrustlyGateway extends AbstractPaymentGateway public const PAYMENT_CLASS = TrustlyProcessor::class; protected array $supportedCurrencies = ['EUR', 'SEK', 'NOK', 'DKK', 'GBP']; + protected array $supportedCountries = ['SE', 'NO', 'DK', 'FI', 'EE', 'LV', 'LT', 'DE', 'NL']; public function __construct() { diff --git a/src/Gateways/Twint/TwintGateway.php b/src/Gateways/Twint/TwintGateway.php index 53df171e7..a834ae37c 100644 --- a/src/Gateways/Twint/TwintGateway.php +++ b/src/Gateways/Twint/TwintGateway.php @@ -7,6 +7,7 @@ class TwintGateway extends AbstractPaymentGateway { protected array $supportedCurrencies = ['CHF']; + protected array $supportedCountries = ['CH']; public function __construct() { diff --git a/src/Gateways/WeChatPay/WeChatPayGateway.php b/src/Gateways/WeChatPay/WeChatPayGateway.php index 69e6ce7ce..df316d683 100644 --- a/src/Gateways/WeChatPay/WeChatPayGateway.php +++ b/src/Gateways/WeChatPay/WeChatPayGateway.php @@ -6,6 +6,8 @@ class WeChatPayGateway extends AbstractPaymentGateway { + protected array $supportedCountries = ['CN']; + public function __construct() { $this->id = 'buckaroo_wechatpay'; diff --git a/src/Gateways/Wero/WeroGateway.php b/src/Gateways/Wero/WeroGateway.php index 9c8886f96..673d838de 100644 --- a/src/Gateways/Wero/WeroGateway.php +++ b/src/Gateways/Wero/WeroGateway.php @@ -30,6 +30,7 @@ class WeroGateway extends AbstractPaymentGateway * @var array */ protected array $supportedCurrencies = ['EUR']; + protected array $supportedCountries = ['FR', 'DE', 'BE']; public function __construct() {