From 30fa35e7a28122e6ab70da282dc3307c8fbc361a Mon Sep 17 00:00:00 2001 From: miroslavs Date: Fri, 5 Jan 2024 13:18:36 +0200 Subject: [PATCH] Fix for the translations. --- nuvei_checkout.php | 4 +++- views/templates/admin/display_forma.tpl | 13 +++---------- 2 files changed, 6 insertions(+), 11 deletions(-) diff --git a/nuvei_checkout.php b/nuvei_checkout.php index e664a57..c0a4d2c 100644 --- a/nuvei_checkout.php +++ b/nuvei_checkout.php @@ -1878,7 +1878,7 @@ public function assignOrderData() 'autoOpenPM' => (bool) Configuration::get('NUVEI_AUTO_EXPAND_PMS'), 'logLevel' => Configuration::get('NUVEI_SDK_LOG_LEVEL'), 'maskCvv' => true, - 'i18n' => Configuration::get('NUVEI_SDK_TRANSL'), + 'i18n' => json_decode(Configuration::get('NUVEI_SDK_TRANSL'), true), 'theme' => Configuration::get('NUVEI_SDK_THEME'), 'apmWindowType' => Configuration::get('NUVEI_APM_WINDOW_TYPE'), 'apmConfig' => [ @@ -1895,6 +1895,8 @@ public function assignOrderData() $sdk_url = $this->getSdkLibUrl(); + $this->createLog($checkout_params, 'SDK params.'); + $this->context->smarty->assign('nuveiSdkUrl', $sdk_url); $this->context->smarty->assign('showNuveoOnly', $this->is_rebilling_order); $this->context->smarty->assign('nuveiSdkParams', json_encode($checkout_params)); diff --git a/views/templates/admin/display_forma.tpl b/views/templates/admin/display_forma.tpl index 0f1d0af..e1ecf31 100644 --- a/views/templates/admin/display_forma.tpl +++ b/views/templates/admin/display_forma.tpl @@ -243,9 +243,9 @@
+"doNotHonor":"you dont have enough money", +"DECLINE":"declined" +}'>{Configuration::get('NUVEI_SDK_TRANSL')} {l s='This filed is the only way to translate Checkout SDK strings. Put the translations for all desired languages as shown in the placeholder. For examples' mod='nuvei'} {l s='check the Documentation.' mod='nuvei'}
@@ -298,13 +298,6 @@ - *} - - {*
- -
- -
*}