<?php

namespace App\Models;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Support\Facades\Session;

class Publication extends BaseModel
{
    public $timestamps = false;
    use HasFactory;
    /**
     * The table associated with the model.
     *
     * @var string
     */

    protected $fillable = ['title_en','title_kh','start_date','end_date','description', BaseModel::CREATED_AT_FIELD, BaseModel::CREATED_BY_FIELD, BaseModel::UPDATED_AT_FIELD, BaseModel::UPDATED_BY_FIELD, BaseModel::RECORD_STATUS_FIELD];

    public static function boot()
    {
        parent::boot();
    }

    function receivers(){
        return $this->hasMany(PublicationReceiver::class, 'publication_id', 'id');
    }



}
