mirror of
https://git.meshkee.com/cssd/cssd-back.git
synced 2026-10-10 23:21:06 +03:30
27 lines
607 B
PHP
27 lines
607 B
PHP
<?php
|
|
|
|
namespace App;
|
|
|
|
use Illuminate\Database\Eloquent\Model;
|
|
|
|
class TestResult extends Model
|
|
{
|
|
public $fillable = ['result','verified','autoclave_id','test_type_id','user_id'];
|
|
public function test_type()
|
|
{
|
|
return $this->belongsTo('App\TestType');
|
|
}
|
|
public function user()
|
|
{
|
|
return $this->belongsTo('App\User');
|
|
}
|
|
public function input_values()
|
|
{
|
|
return $this->hasMany('App\InputValue');
|
|
}
|
|
public function TitleImage()
|
|
{
|
|
return $this->morphToMany('App\Gallery', 'uploadable')->wherePivot('image_role', 'TitleImage');
|
|
}
|
|
}
|