Terminadas standarizaciones
This commit is contained in:
@@ -59,8 +59,8 @@ class SaleController extends Controller
|
||||
SaleDetail::create([
|
||||
'sale_id' => $sale->id,
|
||||
'product_id' => $product->id,
|
||||
'cantidad' => $item['quantity'],
|
||||
'precio' => $product->price,
|
||||
'quantity' => $item['quantity'],
|
||||
'price' => $product->price,
|
||||
]);
|
||||
$nuevoStock = $product->stock_quantity - $item['quantity'];
|
||||
$product->stock_quantity = $nuevoStock;
|
||||
|
||||
Reference in New Issue
Block a user