You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

25 lines
385 B
PHTML

2 years ago
<?php
namespace App\Models;
class SaleItem extends Model
{
protected $fillable = [
'sale_id',
'product_id',
'price',
'cost',
'quantity',
];
public function product()
{
return $this->belongsTo(Product::class)->withTrashed();
2 years ago
}
2 years ago
public function sale()
{
return $this->belongsTo(Sale::class);
}
2 years ago
}