ordini view

This commit is contained in:
paoloar77
2024-05-22 14:27:32 +02:00
parent 01f90df918
commit 309892c7fb

View File

@@ -1860,9 +1860,23 @@ Route::get('/autori_test', function () {
} }
}); });
function getvalstr($mystr, $value) {
return " " . $mystr . ": " . $value;
}
Route::get('/test6', function () { Route::get('/test6', function () {
$orders = Order::all(); $orders = Order::all();
dd($orders);
// Show the fields of the orders
foreach ($orders as $order) {
echo "Ordine: ";
getvalstr("Id", $order->id);
getvalstr("DataOra", $order->DataOra);
getvalstr("Totale", $order->Totale);
}
}); });
Route::get('/test7/{name}', function ($name) { Route::get('/test7/{name}', function ($name) {