Files
riksdagen-app/app/Models/DokIntressent.php

32 lines
579 B
PHP

<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Model;
class DokIntressent extends Model
{
protected $table = 'dokintressent';
public $timestamps = false;
protected $fillable = [
'hangar_id',
'intressent_id',
'namn',
'partibet',
'ordning',
'roll',
];
public function dokument()
{
return $this->belongsTo(Dokument::class, 'hangar_id', 'hangar_id');
}
public function person()
{
return $this->belongsTo(Person::class, 'intressent_id', 'intressent_id');
}
}