Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release v4.1.4 #537

Merged
merged 20 commits into from
Jul 29, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
ad6e8da
chore(deps): update mysql docker tag to v9
alma-renovate-bot[bot] Jul 8, 2024
135a604
Merge pull request #521 from alma/chore/backport-main-to-develop
Benjamin-Freoua-Alma Jul 18, 2024
3890aeb
fix: compatibility PS 1.6 during installing module
Benjamin-Freoua-Alma Jul 25, 2024
454ea29
fix: Issue widget in Cart Item send the static price of the product a…
Benjamin-Freoua-Alma Jul 25, 2024
172746c
fix: item insurance in the cart item
Benjamin-Freoua-Alma Jul 25, 2024
0be7495
fix: add quantity insurance in the product page without event
Benjamin-Freoua-Alma Jul 25, 2024
9d76a3c
fix: add quantity insurance in the product page without event
Benjamin-Freoua-Alma Jul 25, 2024
8b274e9
Merge pull request #531 from alma/fix/ecom-1940-ps-fix-compatibility-…
Benjamin-Freoua-Alma Jul 25, 2024
a3da35c
fix: display order of insurance subscription
Benjamin-Freoua-Alma Jul 26, 2024
2502587
fix: review [FRA] getQuantity
Benjamin-Freoua-Alma Jul 26, 2024
7299afb
Merge pull request #532 from alma/feature/ecom-1912-ps-issue-widget-i…
Benjamin-Freoua-Alma Jul 26, 2024
8dd76a9
Merge pull request #533 from alma/fix/ecom-1907-ps-fix-to-add-quantit…
Benjamin-Freoua-Alma Jul 26, 2024
c761afe
Merge pull request #534 from alma/fix/ecom-1944-ps-fix-display-order-…
Benjamin-Freoua-Alma Jul 26, 2024
1114814
Merge pull request #490 from alma/renovate/major-docker-updates
Benjamin-Freoua-Alma Jul 26, 2024
f72d447
fix: remove dump
Benjamin-Freoua-Alma Jul 26, 2024
c54fd23
Merge pull request #536 from alma/fix/remove-dump
Benjamin-Freoua-Alma Jul 26, 2024
061224c
Fix renovate configuration and disable major composer updates (#535)
gdraynz Jul 29, 2024
27e447a
chore: update version
Benjamin-Freoua-Alma Jul 29, 2024
560c443
fix: changelog
Benjamin-Freoua-Alma Jul 29, 2024
d56ef16
fix: update translation
Benjamin-Freoua-Alma Jul 29, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion .github/renovate.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,12 @@
"groupName": "composer updates"
},
{
"matchManagers": ["docker"],
"matchManagers": ["composer"],
"matchUpdateTypes": ["major"],
"enabled": false
},
{
"matchManagers": ["dockerfile"],
"matchDepNames": ["composer"],
"matchFileNames": ["scripts/build/Dockerfile"],
"enabled": false
Expand Down
15 changes: 15 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,20 @@
# Changelog

## v4.1.4 - 2024-07-29

### Changes

### 🐛 Bug Fixes

- fix: display order details of insurance subscription (#534)
- fix: add quantity insurance in the product and display cart item (#533)
- fix: Issue price widget in Cart Item (#532)
- fix: compatibility PS 1.6 during installing module (#531)

#### Contributors

@Benjamin-Freoua-Alma, @alma-renovate-bot, @gdraynz and @github-actions

## v4.1.3 - 2024-07-18

### Changes
Expand Down
9 changes: 3 additions & 6 deletions alma/alma.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,6 @@
* @copyright 2018-2024 Alma SAS
* @license https://opensource.org/licenses/MIT The MIT License
*/

use Alma\PrestaShop\Builders\Models\MediaHelperBuilder;

if (!defined('_PS_VERSION_')) {
exit;
}
Expand All @@ -33,7 +30,7 @@

class Alma extends PaymentModule
{
const VERSION = '4.1.3';
const VERSION = '4.1.4';

public $_path;
public $local_path;
Expand Down Expand Up @@ -83,7 +80,7 @@ public function __construct()
{
$this->name = 'alma';
$this->tab = 'payments_gateways';
$this->version = '4.1.3';
$this->version = '4.1.4';
$this->author = 'Alma';
$this->need_instance = false;
$this->bootstrap = true;
Expand Down Expand Up @@ -607,7 +604,7 @@ public function renderPSAccount()
}

try {
$mediaHelperBuilder = new MediaHelperBuilder();
$mediaHelperBuilder = new Alma\PrestaShop\Builders\Models\MediaHelperBuilder();
$mediaHelper = $mediaHelperBuilder->getInstance();
$mediaHelper->addJsDef([
'contextPsAccounts' => $accountsFacade->getPsAccountsPresenter()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -179,8 +179,8 @@ public function run($params)
$productQuantity = $product->quantity;
$template = 'displayCartExtraProductActions.tpl';
$cmsReference = $this->insuranceHelper->createCmsReference($idProduct, $productAttributeId);
$regularPrice = $this->productHelper->getRegularPrice($idProduct, $productAttributeId);
$regularPriceInCents = $this->priceHelper->convertPriceToCents($regularPrice);
$staticPrice = $this->productHelper->getPriceStatic($idProduct, $productAttributeId);
$staticPriceInCents = $this->priceHelper->convertPriceToCents($staticPrice);
$merchantId = $this->settingHelper->getIdMerchant();

if ($idProduct !== $insuranceProductId) {
Expand Down Expand Up @@ -220,7 +220,7 @@ public function run($params)
$this->adminInsuranceHelper->envUrl(),
ConstantsHelper::FO_IFRAME_WIDGET_INSURANCE_PATH,
$cmsReference,
$regularPriceInCents,
$staticPriceInCents,
$product['quantity_wanted'],
$merchantId,
$this->context->session->getId(),
Expand Down
6 changes: 3 additions & 3 deletions alma/lib/smarty.php
Original file line number Diff line number Diff line change
Expand Up @@ -85,13 +85,13 @@ function smarty_modifier_almaJsonEncode($value)

function smarty_function_almaCmsReference($params, $smarty)
{
$regular_price = $params['regular_price'] * 100;
$static_price = round($params['static_price'] * 100);

if ($params['product_attribute_id'] === '0') {
return $params['product_id'] . '-' . $regular_price;
return $params['product_id'] . '-' . $static_price;
}

return $params['product_id'] . '-' . $params['product_attribute_id'] . '-' . $regular_price;
return $params['product_id'] . '-' . $params['product_attribute_id'] . '-' . $static_price;
}

smartyRegisterFunction($smarty, 'function', 'almaCmsReference', 'smarty_function_almaCmsReference');
Expand Down
34 changes: 17 additions & 17 deletions alma/translations/es.php
Original file line number Diff line number Diff line change
Expand Up @@ -147,10 +147,10 @@
$_MODULE['<{alma}prestashop>insurancehelper_f1206f9fadc5ce41694f69129aecac26'] = 'Configure';
$_MODULE['<{alma}prestashop>insurancehelper_7442e29d7d53e549b78d93c46b8cdcfc'] = 'Pedidos';
$_MODULE['<{alma}prestashop>admininsurancehelper_eaff1bdf24fcffe0e14e29a1bff51a12'] = 'Seguros';
$_MODULE['<{alma}prestashop>admininsurancehelper_f1206f9fadc5ce41694f69129aecac26'] = 'Configure';
$_MODULE['<{alma}prestashop>admininsurancehelper_f1206f9fadc5ce41694f69129aecac26'] = 'Configura';
$_MODULE['<{alma}prestashop>admininsurancehelper_7442e29d7d53e549b78d93c46b8cdcfc'] = 'Pedidos';
$_MODULE['<{alma}prestashop>insurancehelper_eaff1bdf24fcffe0e14e29a1bff51a12'] = 'Seguros';
$_MODULE['<{alma}prestashop>insurancehelper_f1206f9fadc5ce41694f69129aecac26'] = 'Configure';
$_MODULE['<{alma}prestashop>insurancehelper_f1206f9fadc5ce41694f69129aecac26'] = 'Configura';
$_MODULE['<{alma}prestashop>insurancehelper_7442e29d7d53e549b78d93c46b8cdcfc'] = 'Pedidos';
$_MODULE['<{alma}prestashop>insuranceservice_d87aee5118a62a7ff6c21e4ac31006c5'] = 'Por la presente acepto suscribir el seguro ofrecido por Alma. Al hacerlo, confirmo que he revisado previamente el [aviso informativo, que constituye las condiciones generales], el [documento de información sobre el producto de seguro] y la [hoja de información y asesoramiento precontractual]. Y sin reservas, acepto firmar electrónicamente los distintos documentos que forman mi contrato, si procede. Consiento expresamente la recolección y utilización de mis datos personales a efectos de la suscripción y gestión de mi(s) contrato(s) de seguro.';
$_MODULE['<{alma}prestashop>adminalmainsuranceconfiguration_b824200e9b8aca1fbb762d6566ff0cd7'] = 'Tu configuración se ha guardado';
Expand Down Expand Up @@ -258,14 +258,14 @@
$_MODULE['<{alma}prestashop>pnx_fees_5532ee2e5ea88b613ccb38e9c88f9a77'] = 'si crees que tus volúmenes de ventas justifican mejores tarifas!';
$_MODULE['<{alma}prestashop>order_refund_ps15_cbb3ab577b705e328991986e35218f50'] = 'Importe reembolsado';
$_MODULE['<{alma}prestashop>order_refund_ps15_96b0141273eabab320119c467cdcaf17'] = 'Total';
$_MODULE['<{alma}prestashop>notificationconfiguration_9f246d669c560d2ac604f5e01c8dd981'] = 'Para utilizar Alma, siga estos pasos';
$_MODULE['<{alma}prestashop>notificationconfiguration_9f246d669c560d2ac604f5e01c8dd981'] = 'Para utilizar Alma, sigue estos pasos';
$_MODULE['<{alma}prestashop>notificationconfiguration_3f2c7ed52eb56243edc3a40def7df34b'] = 'Asociar cuenta PrestaShop (justo debajo)';
$_MODULE['<{alma}prestashop>notificationconfiguration_b6a9cb8bac15ad209cf970e3f7cc73a0'] = 'Crear una cuenta Alma';
$_MODULE['<{alma}prestashop>notificationconfiguration_e243bbd390b43c9ee6047fab4ab3cdc0'] = 'Consulte nuestra guía de iniciación';
$_MODULE['<{alma}prestashop>notificationconfiguration_cf5ec9fb9f7214a3db82a5a39fec5b48'] = 'Introduzca su clave API';
$_MODULE['<{alma}prestashop>notificationconfiguration_055f421849c2a1c32b885c95540f827c'] = 'Encuentre su API live key en su %1$s Alma dashboard%2$s';
$_MODULE['<{alma}prestashop>notificationconfiguration_e243bbd390b43c9ee6047fab4ab3cdc0'] = 'Consulta nuestra guía de iniciación';
$_MODULE['<{alma}prestashop>notificationconfiguration_cf5ec9fb9f7214a3db82a5a39fec5b48'] = 'Introduce tu clave API';
$_MODULE['<{alma}prestashop>notificationconfiguration_055f421849c2a1c32b885c95540f827c'] = 'Encuentra tu API live key en tu %1$s Alma dashboard%2$s';
$_MODULE['<{alma}prestashop>notificationconfiguration_53b458e8453e3694811e61c96527d638'] = 'Para utilizar el modo de prueba, obtenga su clave de API de prueba en el panel de control de su sandbox %1$s%2$s';
$_MODULE['<{alma}prestashop>notificationconfiguration_41d0063d3bb7d3067f46734fac8b27c4'] = 'Le proponemos descargar el módulo Cuenta PrestaShop';
$_MODULE['<{alma}prestashop>notificationconfiguration_41d0063d3bb7d3067f46734fac8b27c4'] = 'Te proponemos descargar el módulo Cuenta PrestaShop';
$_MODULE['<{alma}prestashop>notificationconfiguration_6997dde298b14fbf6a7c95bd39fe8dc4'] = 'Encontrará el módulo %1$saquí%2$s';
$_MODULE['<{alma}prestashop>notificationshareofcheckout_a6b0ef107f0d278df612764187bbdece'] = ' Aumenta tu rendimiento y obtén información';
$_MODULE['<{alma}prestashop>notificationshareofcheckout_5b64cb0849dd12ea528c04f2fe66ae4d'] = 'Al aceptar esta opción, permites a Alma analizar el uso de tus métodos de pago, [1]obtener más información para realizar[/1] y compartir estos datos contigo. Puedes [2]darte de baja y borrar tus datos[/2] en cualquier momento.';
Expand Down Expand Up @@ -302,20 +302,20 @@
$_MODULE['<{alma}prestashop>getcontent_8c10d3b0970a247fc554062dc9055fd1'] = 'El importe máximo de los pagos en %1$d plazos debe ser de entre %2$d y %3$d.';
$_MODULE['<{alma}prestashop>getcontent_84b96a3ca61f4425b3fd56534a89a653'] = 'Imposible guardar la configuración de Share of Checkout, por favor inténtalo de nuevo más tarde.';
$_MODULE['<{alma}prestashop>getcontent_7f40d377cc4942c4f0d6e75a736f8445'] = 'Configuración guardada correctamente';
$_MODULE['<{alma}prestashop>getcontent_9f246d669c560d2ac604f5e01c8dd981'] = 'Para utilizar Alma, siga estos pasos';
$_MODULE['<{alma}prestashop>getcontent_9f246d669c560d2ac604f5e01c8dd981'] = 'Para utilizar Alma, sigue estos pasos';
$_MODULE['<{alma}prestashop>getcontent_7379f16a6f4551a47731893ecfce52ab'] = '1. Asociar cuenta PrestaShop (justo debajo)';
$_MODULE['<{alma}prestashop>getcontent_54f458d63e438020e62552dc28f23925'] = '2. Crear una cuenta Alma';
$_MODULE['<{alma}prestashop>getcontent_e243bbd390b43c9ee6047fab4ab3cdc0'] = 'Consulte nuestra guía de iniciación';
$_MODULE['<{alma}prestashop>getcontent_45d67e5114ba6e1f894f12c0c8ac6538'] = '3. Introduzca su clave API';
$_MODULE['<{alma}prestashop>getcontent_055f421849c2a1c32b885c95540f827c'] = 'Encuentre su API live key en su %1$s Alma dashboard%2$s';
$_MODULE['<{alma}prestashop>getcontent_83b4d24aae962bb5581ba5720be20666'] = 'Para utilizar el modo de prueba, obtenga su clave de API de prueba en el panel de control de su sandbox %1$s%2$s';
$_MODULE['<{alma}prestashop>getcontent_41d0063d3bb7d3067f46734fac8b27c4'] = 'Le proponemos descargar el módulo Cuenta PrestaShop';
$_MODULE['<{alma}prestashop>getcontent_6997dde298b14fbf6a7c95bd39fe8dc4'] = 'Encontrará el módulo %1$saquí%2$s';
$_MODULE['<{alma}prestashop>getcontent_e243bbd390b43c9ee6047fab4ab3cdc0'] = 'Consulta nuestra guía de iniciación';
$_MODULE['<{alma}prestashop>getcontent_45d67e5114ba6e1f894f12c0c8ac6538'] = '3. Introduce tu clave API';
$_MODULE['<{alma}prestashop>getcontent_055f421849c2a1c32b885c95540f827c'] = 'Encuentre tu API live key en tu %1$s Alma dashboard%2$s';
$_MODULE['<{alma}prestashop>getcontent_83b4d24aae962bb5581ba5720be20666'] = 'Para utilizar el modo de prueba, obten tu clave de API de prueba en el panel de control de tu sandbox %1$s%2$s';
$_MODULE['<{alma}prestashop>getcontent_41d0063d3bb7d3067f46734fac8b27c4'] = 'Te proponemos descargar el módulo Cuenta PrestaShop';
$_MODULE['<{alma}prestashop>getcontent_6997dde298b14fbf6a7c95bd39fe8dc4'] = 'Encontrarás el módulo %1$saquí%2$s';
$_MODULE['<{alma}prestashop>cartproducts_39f9a4a4bf8387aa7c0478f98b713f91'] = 'Quitar el seguro';
$_MODULE['<{alma}prestashop>cartproducts_7da9ba421c3f84f283070d68bb7adca1'] = 'Seguro Alma';
$_MODULE['<{alma}prestashop>cartproducts_adcd954ece839e7da469e9b37801fa69'] = 'Proteja su producto con';
$_MODULE['<{alma}prestashop>cartproducts_adcd954ece839e7da469e9b37801fa69'] = 'Proteje tu producto con';
$_MODULE['<{alma}prestashop>cartproducts_4cc10fb1d9332d404cc8016b47a1afd1'] = 'Ver los seguros disponibles';
$_MODULE['<{alma}prestashop>widgetaddinsuranceproducts_f1aab89a3a1e86807c8dffa61d41ded6'] = 'Proteja el resto de sus productos con';
$_MODULE['<{alma}prestashop>widgetaddinsuranceproducts_f1aab89a3a1e86807c8dffa61d41ded6'] = 'Proteje el resto de tus productos con';
$_MODULE['<{alma}prestashop>widgetaddinsuranceproducts_f28220d70798406523119d998573b489'] = 'Quiero asegurar todos los [1]%1$s[/1] que quedan en mi cesta';
$_MODULE['<{alma}prestashop>fees_3acc62b245d8bc10f04d81f69d85b685'] = '(Sin gastos)';
$_MODULE['<{alma}prestashop>feeplan_64408fc092e84b9eb352626a0bcbbdf7'] = 'Interés anual (TAE)';
Expand All @@ -336,5 +336,5 @@
$_MODULE['<{alma}prestashop>notificationfirstinstallation_8e51eafe439b0adfecc2dc209c2efb15'] = 'A continuación puedes indicar tus claves API:';
$_MODULE['<{alma}prestashop>notificationfirstinstallation_1e6898bbd6a44041932ac84cbda13bd7'] = 'Encuentra tu clave API Live en %1$stu panel de control Alma%2$s';
$_MODULE['<{alma}prestashop>notificationfirstinstallation_689c39b29a6d91e6dff728a7762cbc9e'] = 'Para utilizar el modo Test (en pruebas), copia tu clave API Test desde %1$stu panel de control sandbox%2$s';
$_MODULE['<{alma}prestashop>notificationfirstinstallation_dcab24ea1a3cd9bab8047b1b6f7ee65c'] = 'Si tiene algún problema, póngase en contacto con nosotros por correo electrónico en %1$[email protected]%2$s';
$_MODULE['<{alma}prestashop>notificationfirstinstallation_dcab24ea1a3cd9bab8047b1b6f7ee65c'] = 'Si tienes algún problema, pónte en contacto con nosotros por correo electrónico en %1$[email protected]%2$s';
$_MODULE['<{alma}prestashop>displaypayment_pnx_22f0189423433ab0e055b91d98970e5f'] = 'El pago a plazos con Alma no está disponible para este pedido';
6 changes: 3 additions & 3 deletions alma/translations/fr.php
Original file line number Diff line number Diff line change
Expand Up @@ -259,10 +259,10 @@
$_MODULE['<{alma}prestashop>order_refund_ps15_cbb3ab577b705e328991986e35218f50'] = 'Montant remboursé';
$_MODULE['<{alma}prestashop>order_refund_ps15_96b0141273eabab320119c467cdcaf17'] = 'Total';
$_MODULE['<{alma}prestashop>notificationconfiguration_9f246d669c560d2ac604f5e01c8dd981'] = 'Pour utiliser Alma, veuillez suivre les étapes suivantes';
$_MODULE['<{alma}prestashop>notificationconfiguration_3f2c7ed52eb56243edc3a40def7df34b'] = 'Associer le compte PrestaShop (juste en dessous)';
$_MODULE['<{alma}prestashop>notificationconfiguration_3f2c7ed52eb56243edc3a40def7df34b'] = 'Compte PrestaShop associé (juste en dessous)';
$_MODULE['<{alma}prestashop>notificationconfiguration_b6a9cb8bac15ad209cf970e3f7cc73a0'] = 'Créer un compte Alma';
$_MODULE['<{alma}prestashop>notificationconfiguration_e243bbd390b43c9ee6047fab4ab3cdc0'] = 'Consultez notre guide de démarrage';
$_MODULE['<{alma}prestashop>notificationconfiguration_cf5ec9fb9f7214a3db82a5a39fec5b48'] = 'Saisissez votre clé API';
$_MODULE['<{alma}prestashop>notificationconfiguration_cf5ec9fb9f7214a3db82a5a39fec5b48'] = 'Entrez votre clé API';
$_MODULE['<{alma}prestashop>notificationconfiguration_055f421849c2a1c32b885c95540f827c'] = 'Trouvez votre clé API sur votre tableau de bord %1$s Alma%2$s';
$_MODULE['<{alma}prestashop>notificationconfiguration_53b458e8453e3694811e61c96527d638'] = 'Pour utiliser le mode test, récupérez votre clé API de test dans le tableau de bord de votre sandbox %1$s%2$s';
$_MODULE['<{alma}prestashop>notificationconfiguration_41d0063d3bb7d3067f46734fac8b27c4'] = 'Nous vous proposons de télécharger le module PrestaShop Account';
Expand Down Expand Up @@ -316,7 +316,7 @@
$_MODULE['<{alma}prestashop>cartproducts_adcd954ece839e7da469e9b37801fa69'] = 'Protégez votre produit avec';
$_MODULE['<{alma}prestashop>cartproducts_4cc10fb1d9332d404cc8016b47a1afd1'] = 'Voir les polices d\'assurance disponibles';
$_MODULE['<{alma}prestashop>widgetaddinsuranceproducts_f1aab89a3a1e86807c8dffa61d41ded6'] = 'Protégez le reste de vos produits avec';
$_MODULE['<{alma}prestashop>widgetaddinsuranceproducts_f28220d70798406523119d998573b489'] = 'Je veux assurer tous les [1]%1$s[/1] restants dans mon panier.';
$_MODULE['<{alma}prestashop>widgetaddinsuranceproducts_f28220d70798406523119d998573b489'] = 'Je veux assurer tous les autres produits [1]%1$s[/1] de mon panier.';
$_MODULE['<{alma}prestashop>fees_3acc62b245d8bc10f04d81f69d85b685'] = '(Sans frais)';
$_MODULE['<{alma}prestashop>feeplan_64408fc092e84b9eb352626a0bcbbdf7'] = 'TAEG fixe';
$_MODULE['<{alma}prestashop>feeplan_ae9a134243362e66fef28a6b2e8a77c4'] = 'Votre panier';
Expand Down
Loading