Traitement date à 0

This commit is contained in:
Michael RICOIS 2016-12-06 10:50:09 +01:00
parent 10dda43a79
commit d6ca919aa4

View File

@ -227,10 +227,14 @@ foreach ($sourcesList as $source => $item) {
}
continue;
}
$calculDate = DateTime::createFromFormat('YmdHis', $survResult->dateUpdate);
$evenDate = DateTime::createFromFormat('YmdHis', $item->dateEven);
if ($evenDate > $calculDate) {
if ($survResult->dateUpdate == '0000-00-00 00:00:00') {
$toCalculate = true;
} else {
$calculDate = DateTime::createFromFormat('YmdHis', $survResult->dateUpdate);
$evenDate = DateTime::createFromFormat('YmdHis', $item->dateEven);
if ($evenDate > $calculDate) {
$toCalculate = true;
}
}
}