<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;

class EventSubscribe extends Model
{
    use HasFactory;

    protected $guarded = ['id', 'created_at', 'updated_at'];

    public function event()
    {
        return $this->belongsTo(Event::class,'event_id');
    }

    public function parent()
    {
        return $this->belongsTo(User::class,'parent_id');
    }

}
