Merge pull request #23133 from milenmk/16-holidays-list-error-message

FIX|Fix[#23117]
This commit is contained in:
Laurent Destailleur 2022-12-07 17:14:06 +01:00 committed by GitHub
commit 5573b88df8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1040,8 +1040,9 @@ if (!$error && ($massaction == 'delete' || ($action == 'delete' && $confirm == '
}
if ($objectclass == 'Holiday' && ! in_array($objecttmp->statut, array(Holiday::STATUS_DRAFT, Holiday::STATUS_CANCELED, Holiday::STATUS_REFUSED))) {
$langs->load("errors");
$nbignored++;
$resaction .= '<div class="error">'.$langs->trans('ErrorLeaveRequestMustBeDraftCanceledOrRefusedToBeDeleted', $objecttmp->ref).'</div><br>';
$TMsg[] = '<div class="error">'.$langs->trans('ErrorLeaveRequestMustBeDraftCanceledOrRefusedToBeDeleted', $objecttmp->ref).'</div><br>';
continue;
}