diff --git a/README.EN.md b/README.EN.md index 67e9517..6a51469 100644 --- a/README.EN.md +++ b/README.EN.md @@ -27,23 +27,25 @@ The PayU payments Prestashop plugin adds the PayU payment option and enables you Plugin version 3.x supports PrestaShop versions 1.6 and 1.7 -| Feature | PrestaShop 1.6 | PrestaShop 1.7 | -|-----------------------------------------------------------------|:-------------------:|:--------------------:| -| Creating a payment order (with discounts included) | :white_check_mark: | :white_check_mark: | -| Capturing a payment order (when auto-capture is disabled) | :white_check_mark: | :white_check_mark: | -| Conducting a refund operation (whole or partial) | :white_check_mark: | :white_check_mark: | -| Displaying payment methods on Presta checkout summary page | :white_check_mark: | :white_check_mark: | -| Card payment as separate method | :white_check_mark: | :white_check_mark: | -| Card payment via widget on summary page | :white_check_mark: | :white_check_mark: | -| Payment retry for cancelled payments | :white_check_mark: | :white_check_mark: | -| Repayment | :white_check_mark: | :white_check_mark: | -| Multi-currency support | :white_check_mark: | :white_check_mark: | -| Payment method order | :white_check_mark: | :white_check_mark: | -| Promoting [PayU Installments][ext10] and [PayU Later][ext9] | :white_check_mark: | :white_check_mark: | -| Twisto payment as separate method | :white_check_mark: | :white_check_mark: | -| Present installment estimated value on product and listing page | :white_check_mark: | :white_check_mark: | -| Present installment estimated value in checkout view | :white_check_mark: | :white_check_mark: | -| Present installment estimated value in cart view | :x: | :white_check_mark: | +| Feature | PrestaShop 1.6 | PrestaShop 1.7 | +|-----------------------------------------------------------------|:------------------:|:------------------:| +| Creating a payment order (with discounts included) | :white_check_mark: | :white_check_mark: | +| Capturing a payment order (when auto-capture is disabled) | :white_check_mark: | :white_check_mark: | +| Conducting a refund operation (whole or partial) | :white_check_mark: | :white_check_mark: | +| Displaying payment methods on Presta checkout summary page | :white_check_mark: | :white_check_mark: | +| Card payment as separate method | :white_check_mark: | :white_check_mark: | +| Card payment via widget on summary page | :white_check_mark: | :white_check_mark: | +| Payment retry for cancelled payments | :white_check_mark: | :white_check_mark: | +| Repayment | :white_check_mark: | :white_check_mark: | +| Multi-currency support | :white_check_mark: | :white_check_mark: | +| Payment method order | :white_check_mark: | :white_check_mark: | +| Promoting [PayU Installments][ext10] and [PayU Later][ext9] | :white_check_mark: | :white_check_mark: | +| Klarna payment as separate method | :white_check_mark: | :white_check_mark: | +| PayPo payment as separate method | :white_check_mark: | :white_check_mark: | +| Twisto payment as separate method | :white_check_mark: | :white_check_mark: | +| Present installment estimated value on product and listing page | :white_check_mark: | :white_check_mark: | +| Present installment estimated value in checkout view | :white_check_mark: | :white_check_mark: | +| Present installment estimated value in cart view | :x: | :white_check_mark: | More information on the features can be found in the [More on features](#more-on-features) section @@ -171,7 +173,7 @@ Plugin version 3.0.10 introduced functionality of promoting [credit payment meth Functionality is enabled by default. It can be deactivated using "Promote credit" switch in admin panel. Support for given functionalities has been described in [Features](#features) section. > Presenting credit widgets is dependent on gateways availability for given point of sale (POS). - Plugin automatically checks whether "ai" or "dpt" gateways are enabled. + Plugin automatically checks whether "ai", "dpt", "dpp" or "dpkl" gateways are enabled. If used POS doesn't have credit agreement activated functionality will not work, and widget presentation will be supressed (even if flag in admin panel is enabled). @@ -184,6 +186,8 @@ Support for given functionalities has been described in [Features](#features) se |1.7|Product page|| |1.7|Cart| | |1.7|Promote credit payment methods|| +|1.7|PayPo payment as separate method || +|1.7|Klarna payment as separate method || |1.7|Twisto payment as separate method|| |1.6|Products listing|| |1.6|Product page|| diff --git a/README.md b/README.md index c5508e4..88db4de 100644 --- a/README.md +++ b/README.md @@ -41,6 +41,8 @@ Plugin w wersji 3.x wspiera PrestaShop w wersji 1.6 i 1.7 | Wielowalutowość | :white_check_mark: | :white_check_mark: | | Kolejność metod płatności | :white_check_mark: | :white_check_mark: | | Promowanie [PayU Raty][ext10] i [PayU Płacę Później][ext9] | :white_check_mark: | :white_check_mark: | +| Płatność Klarna jako osobna metoda płatności | :white_check_mark: | :white_check_mark: | +| Płatność PayPo jako osobna metoda płatności | :white_check_mark: | :white_check_mark: | | Płatność Twisto jako osobna metoda płatności | :white_check_mark: | :white_check_mark: | | Prezentacja kalkulacji ratalnej przy produkcie i listingu | :white_check_mark: | :white_check_mark: | | Prezentacja kalkulacji ratalnej na podsumowaniu | :white_check_mark: | :white_check_mark: | @@ -175,7 +177,7 @@ Od wersji 3.0.10 plugin udostępnia opcję promowania [płatności ratalnych i o Funkcjonalność jest domyślnie włączona. Można ją dezaktywować poprzez przełącznik "Promuj płatności ratalne" w panelu admińskim. Wsparcie dla konkretnych funkcjonalności przedstawione zostało w tabeli [Cechy i Kompatybilność](#cechy-i-kompatybilność). - > Prezentacja kalkulacji zależna jest od dostępności bramek "ai" oraz "dpt" na danym punkcie płatności i sprawdzana + > Prezentacja kalkulacji zależna jest od dostępności bramek "ai", "dpt", "dpp" oraz "dpkl" na danym punkcie płatności i sprawdzana jest automatycznie przez plugin. Jeśli na punkcie płatności nie zostały aktywowane Raty PayU kalkulacja nie zostanie zaprezentowana pomimo włączonej opcji w pluginie. @@ -188,6 +190,8 @@ Funkcjonalność jest domyślnie włączona. Można ją dezaktywować poprzez pr |1.7|Karta produktu|| |1.7|Koszyk| | |1.7|Promowanie płatności ratalnych|| +|1.7|Wydzielenie Klarna jako metody płatności | | +|1.7|Wydzielenie PayPo jako metody płatności | | |1.7|Wydzielenie Twisto jako metody płatności|| |1.6|Listing produktów|| |1.6|Karta produktu|| diff --git a/payu/controllers/front/payment.php b/payu/controllers/front/payment.php index 559776c..bcb51e0 100644 --- a/payu/controllers/front/payment.php +++ b/payu/controllers/front/payment.php @@ -44,6 +44,7 @@ public function process() $payMethod === 'blik' || $payMethod === 'dp' || $payMethod === 'dpt' || + $payMethod === 'dpkl' || $payMethod === 'dpp' ) { $this->pay($payMethod, [], $payMethod); diff --git a/payu/img/payu_later_klarna_logo.svg b/payu/img/payu_later_klarna_logo.svg new file mode 100644 index 0000000..da67bfa --- /dev/null +++ b/payu/img/payu_later_klarna_logo.svg @@ -0,0 +1,14 @@ + + + + + + + + + + + + + + diff --git a/payu/img/payu_later_paypo_logo.svg b/payu/img/payu_later_paypo_logo.svg new file mode 100644 index 0000000..5cd939c --- /dev/null +++ b/payu/img/payu_later_paypo_logo.svg @@ -0,0 +1,13 @@ + + + + + + + + + + + + + diff --git a/payu/img/payu_later_twisto_logo.png b/payu/img/payu_later_twisto_logo.png deleted file mode 100644 index e8e5833..0000000 Binary files a/payu/img/payu_later_twisto_logo.png and /dev/null differ diff --git a/payu/img/payu_later_twisto_logo.svg b/payu/img/payu_later_twisto_logo.svg new file mode 100644 index 0000000..4069245 --- /dev/null +++ b/payu/img/payu_later_twisto_logo.svg @@ -0,0 +1,15 @@ + + + + + + + + + + + + + + + diff --git a/payu/payu.php b/payu/payu.php index 256b603..401b7e6 100644 --- a/payu/payu.php +++ b/payu/payu.php @@ -92,6 +92,8 @@ function_exists('curl_version') && Configuration::updateValue('PAYU_PROMOTE_CREDIT_SUMMARY', 1) && Configuration::updateValue('PAYU_PROMOTE_CREDIT_PRODUCT', 1) && Configuration::updateValue('PAYU_SEPARATE_PAY_LATER_TWISTO', 0) && + Configuration::updateValue('PAYU_SEPARATE_PAY_LATER_KLARNA', 0) && + Configuration::updateValue('PAYU_SEPARATE_PAY_LATER_PAYPO', 0) && Configuration::updateValue('PAYU_SEPARATE_BLIK_PAYMENT', 0) && Configuration::updateValue('PAYU_PAYMENT_METHODS_GRID', 0) ); @@ -125,6 +127,8 @@ public function uninstall() !Configuration::deleteByName('PAYU_PROMOTE_CREDIT_SUMMARY') || !Configuration::deleteByName('PAYU_PROMOTE_CREDIT_PRODUCT') || !Configuration::deleteByName('PAYU_SEPARATE_PAY_LATER_TWISTO') || + !Configuration::deleteByName('PAYU_SEPARATE_PAY_LATER_KLARNA') || + !Configuration::deleteByName('PAYU_SEPARATE_PAY_LATER_PAYPO') || !Configuration::deleteByName('PAYU_SEPARATE_BLIK_PAYMENT') || !Configuration::deleteByName('PAYU_PAYMENT_METHODS_GRID', 0) ) { @@ -193,6 +197,8 @@ public function getContent() !Configuration::updateValue('PAYU_PROMOTE_CREDIT_SUMMARY', (Tools::getValue('PAYU_PROMOTE_CREDIT_SUMMARY') ? 1 : 0)) || !Configuration::updateValue('PAYU_PROMOTE_CREDIT_PRODUCT', (Tools::getValue('PAYU_PROMOTE_CREDIT_PRODUCT') ? 1 : 0)) || !Configuration::updateValue('PAYU_SEPARATE_PAY_LATER_TWISTO', (Tools::getValue('PAYU_SEPARATE_PAY_LATER_TWISTO') ? 1 : 0)) || + !Configuration::updateValue('PAYU_SEPARATE_PAY_LATER_KLARNA', (Tools::getValue('PAYU_SEPARATE_PAY_LATER_KLARNA') ? 1 : 0)) || + !Configuration::updateValue('PAYU_SEPARATE_PAY_LATER_PAYPO', (Tools::getValue('PAYU_SEPARATE_PAY_LATER_PAYPO') ? 1 : 0)) || !Configuration::updateValue('PAYU_PAYMENT_METHODS_GRID', (Tools::getValue('PAYU_PAYMENT_METHODS_GRID') ? 1 : 0)) ) { @@ -368,6 +374,42 @@ public function displayForm() ] ], ], + [ + 'type' => 'switch', + 'label' => $this->l('Separate pay later Klarna'), + 'desc' => $this->l('Shows separate Klarna payment method'), + 'name' => 'PAYU_SEPARATE_PAY_LATER_KLARNA', + 'values' => [ + [ + 'id' => 'active_on', + 'value' => 1, + 'label' => $this->l('Enabled') + ], + [ + 'id' => 'active_off', + 'value' => 0, + 'label' => $this->l('Disabled') + ] + ], + ], + [ + 'type' => 'switch', + 'label' => $this->l('Separate pay later PayPo'), + 'desc' => $this->l('Shows separate PayPo payment method'), + 'name' => 'PAYU_SEPARATE_PAY_LATER_PAYPO', + 'values' => [ + [ + 'id' => 'active_on', + 'value' => 1, + 'label' => $this->l('Enabled') + ], + [ + 'id' => 'active_off', + 'value' => 0, + 'label' => $this->l('Disabled') + ] + ], + ], [ 'type' => 'switch', 'label' => $this->l('Separate pay later Twisto'), @@ -604,6 +646,8 @@ private function getConfigFieldsValues() 'PAYU_PROMOTE_CREDIT_SUMMARY' => Configuration::get('PAYU_PROMOTE_CREDIT_SUMMARY'), 'PAYU_PROMOTE_CREDIT_PRODUCT' => Configuration::get('PAYU_PROMOTE_CREDIT_PRODUCT'), 'PAYU_SEPARATE_PAY_LATER_TWISTO' => Configuration::get('PAYU_SEPARATE_PAY_LATER_TWISTO'), + 'PAYU_SEPARATE_PAY_LATER_KLARNA' => Configuration::get('PAYU_SEPARATE_PAY_LATER_KLARNA'), + 'PAYU_SEPARATE_PAY_LATER_PAYPO' => Configuration::get('PAYU_SEPARATE_PAY_LATER_PAYPO'), 'PAYU_PAYMENT_METHODS_GRID' => Configuration::get('PAYU_PAYMENT_METHODS_GRID'), ]; @@ -798,6 +842,8 @@ public function hookPaymentOptions($params, $retry = false) 'paymentMethods' => $paymentMethods['payByLinks'], 'separateBlik' => Configuration::get('PAYU_SEPARATE_BLIK_PAYMENT'), 'separateTwisto' => Configuration::get('PAYU_SEPARATE_PAY_LATER_TWISTO'), + 'separateKlarna' => Configuration::get('PAYU_SEPARATE_PAY_LATER_KLARNA'), + 'separatePaypo' => Configuration::get('PAYU_SEPARATE_PAY_LATER_PAYPO'), 'separateCard' => Configuration::get('PAYU_SEPARATE_CARD_PAYMENT'), 'posId' => OpenPayU_Configuration::getMerchantPosId(), 'lang' => Language::getIsoById($this->context->language->id), @@ -923,21 +969,70 @@ public function hookPaymentOptions($params, $retry = false) } $paymentOptions[] = $paymentOption; - + if ($this->isPayLaterKlarnaAvailable($totalPrice)) { + if ($retry16) { + $payLaterKlarnaOption = [ + 'CallToActionText' => $this->l('Pay later'), + 'AdditionalInformation' => '', + 'ModuleName' => $this->name, + 'Logo' => $this->getPayuLogo('payu_later_klarna_logo.svg') + ]; + } else { + $payLaterKlarnaOption = new PrestaShop\PrestaShop\Core\Payment\PaymentOption(); + $payLaterKlarnaOption + ->setCallToActionText($this->l('Pay later')) + ->setModuleName($this->name) + ->setLogo($this->getPayuLogo('payu_later_klarna_logo.svg')) + ->setAction($this->context->link->getModuleLink($this->name, 'payment', + [ + 'payMethod' => 'dpkl' + ] + )); + if ($retry) { + $payLaterKlarnaOption->setAdditionalInformation(''); + } + } + $paymentOptions[] = $payLaterKlarnaOption; + } + if ($this->isPayLaterPaypoAvailable($totalPrice)) { + if ($retry16) { + $payLaterPaypoOption = [ + 'CallToActionText' => $this->l('Pay later'), + 'AdditionalInformation' => '', + 'ModuleName' => $this->name, + 'Logo' => $this->getPayuLogo('payu_later_paypo_logo.svg') + ]; + } else { + $payLaterPaypoOption = new PrestaShop\PrestaShop\Core\Payment\PaymentOption(); + $payLaterPaypoOption + ->setCallToActionText($this->l('Pay later')) + ->setModuleName($this->name) + ->setLogo($this->getPayuLogo('payu_later_paypo_logo.svg')) + ->setAction($this->context->link->getModuleLink($this->name, 'payment', + [ + 'payMethod' => 'dpp' + ] + )); + if ($retry) { + $payLaterPaypoOption->setAdditionalInformation(''); + } + } + $paymentOptions[] = $payLaterPaypoOption; + } if ($this->isPayLaterTwistoAvailable($totalPrice)) { if ($retry16) { $payLaterTwistoOption = [ 'CallToActionText' => $this->l('Pay later'), 'AdditionalInformation' => '', 'ModuleName' => $this->name, - 'Logo' => $this->getPayuLogo('payu_later_twisto_logo.png') + 'Logo' => $this->getPayuLogo('payu_later_twisto_logo.svg') ]; } else { $payLaterTwistoOption = new PrestaShop\PrestaShop\Core\Payment\PaymentOption(); $payLaterTwistoOption ->setCallToActionText($this->l('Pay later')) ->setModuleName($this->name) - ->setLogo($this->getPayuLogo('payu_later_twisto_logo.png')) + ->setLogo($this->getPayuLogo('payu_later_twisto_logo.svg')) ->setAction($this->context->link->getModuleLink($this->name, 'payment', [ 'payMethod' => 'dpt' @@ -1012,14 +1107,24 @@ public function hookPayment($params) 'creditPayLaterTwistoActionUrl' => $this->context->link->getModuleLink('payu', 'payment', [ 'payMethod' => 'dpt' ]), + 'creditPayLaterKlarnaActionUrl' => $this->context->link->getModuleLink('payu', 'payment', [ + 'payMethod' => 'dpkl' + ]), + 'creditPayLaterPaypoActionUrl' => $this->context->link->getModuleLink('payu', 'payment', [ + 'payMethod' => 'dpp' + ]), 'credit_available' => $this->isCreditAvailable($params['cart']->getOrderTotal()), 'payu_later_twisto_available' => $this->isPayLaterTwistoAvailable($params['cart']->getOrderTotal()), + 'payu_later_klarna_available' => $this->isPayLaterKlarnaAvailable($params['cart']->getOrderTotal()), + 'payu_later_paypo_available' => $this->isPayLaterPaypoAvailable($params['cart']->getOrderTotal()), 'cart_total_amount' => $params['cart']->getOrderTotal(), 'credit_pos' => OpenPayU_Configuration::getMerchantPosId(), 'credit_pos_key' => substr(OpenPayU_Configuration::getOauthClientSecret(), 0, 2), 'separateBlik' => Configuration::get('PAYU_SEPARATE_BLIK_PAYMENT'), 'separateTwisto' => Configuration::get('PAYU_SEPARATE_PAY_LATER_TWISTO'), + 'separateKlarna' => Configuration::get('PAYU_SEPARATE_PAY_LATER_KLARNA'), + 'separatePaypo' => Configuration::get('PAYU_SEPARATE_PAY_LATER_PAYPO'), 'separateCard' => Configuration::get('PAYU_SEPARATE_CARD_PAYMENT'), 'paymentGrid' => Configuration::get('PAYU_PAYMENT_METHODS_GRID'), 'conditionTemplate' => _PS_MODULE_DIR_ . 'payu/views/templates/front/conditions17.tpl', @@ -1530,7 +1635,7 @@ public function orderCreateRequestByOrder($orderTotal, $payMethod = null, $param } - if ($payMethod === 'ai' || $payMethod === 'dp' || $payMethod === 'dpt' || $payMethod === 'dpp') { + if ($payMethod === 'ai' || $payMethod === 'dp' || $payMethod === 'dpt' || $payMethod === 'dpp' || $payMethod === 'dpkl') { $ocreq['credit'] = $this->getCreditSection(); } @@ -2516,6 +2621,36 @@ private function isPayLaterTwistoAvailable($amount) $this->getVersion()); } + /** + * @param float $amount + * + * @return bool + */ + private function isPayLaterKlarnaAvailable($amount) + { + return (Configuration::get('PAYU_SEPARATE_PAY_LATER_KLARNA') === '1') + && PayMethodsCache::isPaytypeAvailable('dpkl', + Currency::getCurrency($this->context->cart->id_currency), + $this->getLanguage(), + $amount, + $this->getVersion()); + } + + /** + * @param float $amount + * + * @return bool + */ + private function isPayLaterPaypoAvailable($amount) + { + return (Configuration::get('PAYU_SEPARATE_PAY_LATER_PAYPO') === '1') + && PayMethodsCache::isPaytypeAvailable('dpp', + Currency::getCurrency($this->context->cart->id_currency), + $this->getLanguage(), + $amount, + $this->getVersion()); + } + private function setPayuNotification() { if (session_status() == PHP_SESSION_NONE) { diff --git a/payu/translations/pl.php b/payu/translations/pl.php index ae77a06..e1cb4a6 100644 --- a/payu/translations/pl.php +++ b/payu/translations/pl.php @@ -25,8 +25,12 @@ $_MODULE['<{payu}prestashop>payu_ba5376b5ba3216a7a51eabb18265d921'] = 'Raty'; $_MODULE['<{payu}prestashop>payu_a1f6309d520783d4d0163d5a9ff26cda'] = 'Promuj płatności ratalne'; $_MODULE['<{payu}prestashop>payu_ba9cce7b6b5c225fbd3d11a555030435'] = 'Włącza płatności ratalne na wyborze metod płatności i pozwala na promowanie rat'; -$_MODULE['<{payu}prestashop>payu_a9ba633160b4732c06848c8ec792e7bb'] = 'Wyświetl Twisto jako osobną metoda płatności'; +$_MODULE['<{payu}prestashop>payu_a9ba633160b4732c06848c8ec792e7bb'] = 'Wyświetl Twisto jako osobną metodę płatności'; $_MODULE['<{payu}prestashop>payu_58c031a7bd41986ec989d13d559b570d'] = 'Wydziela Twisto ze wszystkich metod płatności'; +$_MODULE['<{payu}prestashop>payu_a2ada5a24ad67c11a37eaae8a7338980'] = 'Wyświetl PayPo jako osobną metodę płatności'; +$_MODULE['<{payu}prestashop>payu_0acc8d2999baab348e6afc73b46ab508'] = 'Wydziela PayPo ze wszystkich metod płatności'; +$_MODULE['<{payu}prestashop>payu_ea1e8638f361bb18223be5df0fea0fab'] = 'Wyświetl Klarna jako osobną metodę płatności'; +$_MODULE['<{payu}prestashop>payu_d98abe3400d15209d16d87980cb975d5'] = 'Wydziela Klarna ze wszystkich metod płatności'; $_MODULE['<{payu}prestashop>payu_f22e2e3d4a09b23efdd495ffe80ebb8e'] = 'Wyświetl raty w koszyku'; $_MODULE['<{payu}prestashop>payu_1a731c98ab99a867c6b7f9ea212c6e3c'] = 'Promuje raty w widoku koszyka'; $_MODULE['<{payu}prestashop>payu_352d40b8f691e22c5bacd2e5d63258d8'] = 'Wyświetl raty na podsumowaniu'; @@ -120,4 +124,6 @@ $_MODULE['<{payu}prestashop>payment16_961d23fcb6c49cee1150dba52beb04ca'] = 'Zapłać przelewem online'; $_MODULE['<{payu}prestashop>payment16_3a236fb1c82cd58579049b70a46fcdc5'] = 'Zapłać przelewem online lub kartą'; $_MODULE['<{payu}prestashop>payment16_22811d85a0f85861e285232e81c5b239'] = 'Zapłać później z Twisto'; +$_MODULE['<{payu}prestashop>payment16_e3285e42a8110e81f687a6fe35e0f2c6'] = 'Zapłać później z Klarna'; +$_MODULE['<{payu}prestashop>payment16_40ae01b812835afd7d7205dd21151f62'] = 'Zapłać później z PayPo'; $_MODULE['<{payu}prestashop>payment16_8b30b72eb751e7549e99b8e2753098df'] = 'Zapłać na raty online z PayU'; diff --git a/payu/views/templates/front/repaymentTransferList.tpl b/payu/views/templates/front/repaymentTransferList.tpl index c20908f..e55b6cf 100644 --- a/payu/views/templates/front/repaymentTransferList.tpl +++ b/payu/views/templates/front/repaymentTransferList.tpl @@ -33,6 +33,14 @@ pay-methods__hide {/if} + {if $separateKlarna && $payment->value == 'dpkl'} + pay-methods__hide + {/if} + + {if $separatePaypo && $payment->value == 'dpp'} + pay-methods__hide + {/if} + {if $separateTwisto && $payment->value == 'dpt'} pay-methods__hide {/if} diff --git a/payu/views/templates/hook/payment16.tpl b/payu/views/templates/hook/payment16.tpl index 414bf79..9d1c3ec 100644 --- a/payu/views/templates/hook/payment16.tpl +++ b/payu/views/templates/hook/payment16.tpl @@ -100,6 +100,32 @@ {/if} + {if $payu_later_klarna_available == true} +
+
+

+ + {l s='Pay later with Klarna' mod='payu'} + +

+
+
+ {/if} + + {if $payu_later_paypo_available == true} +
+
+

+ + {l s='Pay later with PayPo' mod='payu'} + +

+
+
+ {/if} + {if $payu_later_twisto_available == true}
diff --git a/payu/views/templates/hook/paymentTransferList.tpl b/payu/views/templates/hook/paymentTransferList.tpl index 7d9ecde..756ddf9 100644 --- a/payu/views/templates/hook/paymentTransferList.tpl +++ b/payu/views/templates/hook/paymentTransferList.tpl @@ -34,6 +34,14 @@ pay-methods__hide {/if} + {if $separateKlarna && $payment->value == 'dpkl'} + pay-methods__hide + {/if} + + {if $separatePaypo && $payment->value == 'dpp'} + pay-methods__hide + {/if} + {if $separateTwisto && $payment->value == 'dpt'} pay-methods__hide {/if} diff --git a/payu/views/templates/hook/paymentTransferList17.tpl b/payu/views/templates/hook/paymentTransferList17.tpl index 8187940..e066c97 100644 --- a/payu/views/templates/hook/paymentTransferList17.tpl +++ b/payu/views/templates/hook/paymentTransferList17.tpl @@ -29,6 +29,14 @@ pay-methods__hide {/if} + {if $separateKlarna && $payment->value == 'dpkl'} + pay-methods__hide + {/if} + + {if $separatePaypo && $payment->value == 'dpp'} + pay-methods__hide + {/if} + {if $separateTwisto && $payment->value == 'dpt'} pay-methods__hide {/if} diff --git a/readme_images/credit-1-7-checkout-separate-klarna.png b/readme_images/credit-1-7-checkout-separate-klarna.png new file mode 100644 index 0000000..33adcee Binary files /dev/null and b/readme_images/credit-1-7-checkout-separate-klarna.png differ diff --git a/readme_images/credit-1-7-checkout-separate-paypo.png b/readme_images/credit-1-7-checkout-separate-paypo.png new file mode 100644 index 0000000..289a916 Binary files /dev/null and b/readme_images/credit-1-7-checkout-separate-paypo.png differ diff --git a/readme_images/credit-1-7-checkout-separate-twisto.png b/readme_images/credit-1-7-checkout-separate-twisto.png index be97cca..c5d1d6b 100644 Binary files a/readme_images/credit-1-7-checkout-separate-twisto.png and b/readme_images/credit-1-7-checkout-separate-twisto.png differ