thanato email , date for new functionnalities h2f

This commit is contained in:
Tiavina 2025-04-25 17:00:13 +03:00
parent ad19cce002
commit 7310013da7
2 changed files with 5 additions and 3 deletions

View File

@ -26,6 +26,8 @@ class Bdd {
private String $tableprefix;
private $l;
private $dateForNewTrajetFunctionnalities = "2025-04-25";
public function __construct(IDbConnection $db,
IL10N $l) {
$this->whiteColumn = array("date", "num", "id_client", "entreprise", "nom", "prenom", "legal_one", "telephone", "mail", "adresse", "produit_id", "quantite", "date_paiement", "type_paiement",
@ -1335,7 +1337,7 @@ class Bdd {
* l'ajout d'un thanato depuis son domicile ver le siege .
*/
$dateTime = new DateTime($date);
$dateTimeForFunctionalityGoToHome = new DateTime('2025-04-07');
$dateTimeForFunctionalityGoToHome = new DateTime($this->dateForNewTrajetFunctionnalities);//Don't edit this date, it's a date for the new functionality
if ( $dateTime <= $dateTimeForFunctionalityGoToHome) {
return;
@ -1384,7 +1386,7 @@ class Bdd {
foreach($datesLignes as $date => $currentDateLignes){
$dateTime = new DateTime($date);
$dateTimeForFunctionalityGoToHome = new DateTime('2025-04-07');//Don't edit this date, it's a date for the new functionality
$dateTimeForFunctionalityGoToHome = new DateTime($this->dateForNewTrajetFunctionnalities);//Don't edit this date, it's a date for the new functionality
if ( $dateTime <= $dateTimeForFunctionalityGoToHome) {

View File

@ -313,7 +313,7 @@ class GestionService {
}
if ($thanatoIsSubcontractor && $devisExist) {
$thanatoHasEmail = $thanato["thanato_email"] != null;
$thanatoHasEmail = $thanato["thanato_email"] != null && $thanato["thanato_email"] != "" && $thanato["thanato_email"] != "-";
if($thanatoHasEmail){
$emailBody = $this->extractBodyOfEmailAttachment(VCalendarHelpers::getEmailIdInVCalendar($vCalendarString));
$this->sendEmailAndAttachment($thanato["thanato_email"] , $devis["defunt_nom"],$emailBody ,$attachmentsCalendar ,$orderContent);