[22/05/2023] Pour ne pas envoyer les emails de confirmation d'envoi, pour le smodules Chorno, MR et Colissimo (en attendant de résoudre le souci de mauvais email qui part)

This commit is contained in:
2023-05-22 18:11:46 +02:00
parent b7877511d6
commit 4721e50d2b
7 changed files with 580 additions and 7 deletions

View File

@@ -49,6 +49,9 @@ class ShippingNotificationSender extends BaseAction implements EventSubscriberI
if ($event->getOrder()->isSent() && (
$event->getOrder()->getDeliveryModuleId() == ModuleQuery::create()->findOneByCode('ChronopostHomeDelivery')->getId())) {
/* TheCoreDev le 22/05/2023 : ajouté en attendant de résoudre le problème des emails qui partent même si la commande utilise un autre mode de livraison*/
return;
$contactEmail = ConfigQuery::getStoreEmail();
if ($contactEmail) {

View File

@@ -25,7 +25,7 @@
{/loop}
<p>{intl l="We are pleased to inform you that your order number"} {$order_ref} {intl l="has been shipped on"} {format_date date=$update_date output="date"} {intl l="with the tracking number"} <strong>{$package}</strong>.</p>
<p>{intl l="We are pleased to inform you that your order number"} {$order_ref} {intl l="has been shipped on"} {format_date date=$update_date output="date"} {intl l="with the tracking number"} <strong>{$package}</strong>.</p>
<p>{intl l='<a href="https://www.chronopost.fr/tracking-no-cms/suivi-page?listeNumerosLT=%package">Click here</a> to track your shipment.' package=$package}</p>
<p>{intl l='Thank you for your shopping with us and hope to see you soon on <a href="#">www.yourshop.com</a>'}</p>

View File

@@ -57,6 +57,10 @@ class ShippingNotificationSender extends BaseAction implements EventSubscriberIn
$module = new ColissimoWs();
if ($event->getOrder()->isSent() && $order->getDeliveryModuleId() == $module->getModuleModel()->getId()) {
/* TheCoreDev le 22/05/2023 : ajouté en attendant de résoudre le problème des emails qui partent même si la commande utilise un autre mode de livraison*/
return;
$contact_email = ConfigQuery::getStoreEmail();
if ($contact_email) {

View File

@@ -47,6 +47,9 @@ class SendDeliveryEmail implements EventSubscriberInterface
&&
$order->getDeliveryModuleId() == MondialRelay::getModuleId()
) {
/* TheCoreDev le 22/05/2023 : ajouté en attendant de résoudre le problème des emails qui partent même si la commande utilise un autre mode de livraison*/
return;
if (null !== $contactEmail = ConfigQuery::read('store_email')) {
$this->mailer->sendEmailToCustomer(
MondialRelay::TRACKING_MESSAGE_NAME,

View File

@@ -12,4 +12,4 @@ return array(
'Your %ref order has been shipped' => 'Votre commande %ref a été expédiée.',
'Your order %order_ref has just been shipped from our store. The tracking number for this order is %tracking_ref. Please <a href="https://www.mondialrelay.fr/suivi-de-colis">click here</a> to track the delivery.' => 'Votre commande %order_ref vient de quitter nos entrepôts. Le numéro de suivi est %tracking_ref. <a href="https://www.mondialrelay.fr/suivi-de-colis">Merci de cliquer ici</a> pour obtenir les informations de suivi.',
'Your order %order_ref has just been shipped from our store. The tracking number for this order is %tracking_ref. Tracking data is available at this address: https://www.mondialrelay.fr/suivi-de-colis' => 'Votre commande %order_ref vient de quitter nos entrepôts. Le numéro de suivi est %tracking_ref. Pour obtenir des informations sur l\'avancement de votre commande, merci de suivre ce lien: https://www.mondialrelay.fr/suivi-de-colis',
);
);