29 lines
538 B
PHP
29 lines
538 B
PHP
<?php
|
|
|
|
namespace App\Models;
|
|
|
|
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
|
use Illuminate\Database\Eloquent\Model;
|
|
|
|
class HistoryDetail extends Model
|
|
{
|
|
use HasFactory;
|
|
|
|
protected $guarded = [];
|
|
|
|
public function history()
|
|
{
|
|
return $this->belongsTo(History::class, 'history_id', 'id');
|
|
}
|
|
|
|
public function item()
|
|
{
|
|
return $this->belongsTo(Item::class, 'item_id', 'id');
|
|
}
|
|
|
|
public function likert()
|
|
{
|
|
return $this->belongsTo(Likert::class, 'likert_id', 'id');
|
|
}
|
|
}
|