Sfoglia il codice sorgente

[Backend] Correctif cron envoi récapitulatif commandes

refactoring
Guillaume 2 anni fa
parent
commit
6ca0ca8677
1 ha cambiato i file con 3 aggiunte e 2 eliminazioni
  1. +3
    -2
      backend/controllers/CronController.php

+ 3
- 2
backend/controllers/CronController.php Vedi File

@@ -229,8 +229,7 @@ class CronController extends BackendController
'orders' => $arrayOrders
]
)
->setFrom([Yii::$app->params['adminEmail'] => 'distrib'])
->setSubject($subject);;
->setFrom([Yii::$app->params['adminEmail'] => 'distrib']);

if (is_array($arrayOrders) && count($arrayOrders)) {
$subject = '[distrib] Commandes du ' . date('d/m', strtotime($date));
@@ -249,6 +248,8 @@ class CronController extends BackendController
$subject = '[distrib] Aucune commande';
}

$mail->setSubject($subject);

// envoi des emails à tous les comptes users (statut producer) associés à ce producteur
$userArray = User::searchAll([
'id_producer' => $producer->id,

Loading…
Annulla
Salva