This commit is contained in:
paoloar77
2024-05-17 13:43:34 +02:00
parent 37cc797f2f
commit b8d8ff0f51

View File

@@ -110,15 +110,15 @@ class TestPao extends Command
} else {
$mostra = true;
}
if ($mostra) {
if (is_object($article)) {
if ($mostra) {
if (is_object($article)) {
$strarticolo = json_encode($article, JSON_PRETTY_PRINT);
if ($strarticolo !== false) {
echo $strarticolo;
$log .= $strarticolo;
}
}
if ($article->stock)
echo "\r\n QTA = " . $article->stock . "\r\n";
}
@@ -260,6 +260,12 @@ class TestPao extends Command
Log::channel('testpao')->notice($log);
// echo $log;
if (true) {
// Send the email
Mail::raw($log, function ($message) {
$message->to(Mylog::getEmail());
$message->subject(Mylog::getSubjectEmail("TESTPAO"));
});
}
}
}