43 lines
817 B
PHP
43 lines
817 B
PHP
|
|
<?php
|
||
|
|
|
||
|
|
namespace App\Models;
|
||
|
|
|
||
|
|
use Illuminate\Database\Eloquent\Model;
|
||
|
|
|
||
|
|
/**
|
||
|
|
* @property integer $id
|
||
|
|
* @property integer $product_id
|
||
|
|
* @property string $evaluation
|
||
|
|
* @property string $aspect
|
||
|
|
* @property string $taste
|
||
|
|
* @property string $odor
|
||
|
|
* @property string $texture
|
||
|
|
* @property string $created_at
|
||
|
|
* @property string $updated_at
|
||
|
|
* @property Product $product
|
||
|
|
*/
|
||
|
|
class ProductComment extends Model
|
||
|
|
{
|
||
|
|
/**
|
||
|
|
* @var array
|
||
|
|
*/
|
||
|
|
protected $fillable = [
|
||
|
|
'product_id',
|
||
|
|
'evaluation',
|
||
|
|
'aspect',
|
||
|
|
'taste',
|
||
|
|
'odor',
|
||
|
|
'texture',
|
||
|
|
'created_at',
|
||
|
|
'updated_at'
|
||
|
|
];
|
||
|
|
|
||
|
|
/**
|
||
|
|
* @return \Illuminate\Database\Eloquent\Relations\BelongsTo
|
||
|
|
*/
|
||
|
|
public function product()
|
||
|
|
{
|
||
|
|
return $this->belongsTo('App\Models\Product');
|
||
|
|
}
|
||
|
|
}
|