xxxxxxxxxx
Prices::where('product_id', $product->id)->get()->latest('id');
xxxxxxxxxx
DB::table('users')->insert([
'email' => 'kayla@example.com',
'votes' => 5
]);
xxxxxxxxxx
<?php
Route::get('games', function () {
$games = DB::table('games')->get();
return view('games', ['games' => $games]);
});
xxxxxxxxxx
DB::table('users')->insert([
'email' => 'kayla@example.com',
'votes' => 0
]);