📅  最后修改于: 2022-03-11 14:54:08.245000             🧑  作者: Mango
Product::increment('count' , 5); // count + 5
Product::decrement('count', 5); // count - 5
---------------Or-----------------------
Product::where('product_id', $product->id)
->update([
'count'=> DB::raw('count+1'),
'last_count_increased_at' => Carbon::now()
]);