File: /www/wwwroot/www.ankua.asia/beike/Models/ProductView.php
<?php
/**
* ProductView.php
*
* @copyright 2023 beikeshop.com - All Rights Reserved
* @link https://beikeshop.com
* @author TL <mengwb@guangda.work>
* @created 2023-11-29 20:22:18
* @modified 2023-11-29 20:22:18
*/
namespace Beike\Models;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Relations\BelongsTo;
class ProductView extends Base
{
use HasFactory;
protected $fillable = ['product_id', 'customer_id', 'ip', 'session_id'];
public function product(): BelongsTo
{
return $this->belongsTo(Product::class);
}
public function customer(): BelongsTo
{
return $this->belongsTo(Customer::class);
}
}