applicant-site/app/Models/Document.php

26 lines
465 B
PHP

<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\Relations\BelongsTo;
class Document extends Model
{
use HasFactory;
protected $fillable = [
'id',
'name',
'file_name',
'url',
'description',
];
public function admission(): BelongsTo
{
return $this->belongsTo(Admission::class);
}
}