Bulletinboard/app/Models/TimePeriod.php

20 lines
311 B
PHP

<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
class TimePeriod extends Model
{
use HasFactory;
protected $fillable = [
"name"
];
public function post(){
return $this->hasMany(Post::class);
}
}