<?php

namespace App;

use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\SoftDeletes;

class TrainReservation extends Model
{
    protected $table = 'physical_reservations';
    use SoftDeletes;

    protected $dates = ['deleted_at'];
    
    protected $fillable = array('trainner_id','patient_id','system_physic_id','branch_id', 'dating', 'timing', 'count', 'expired');
    public function system_physic()
    {
        return $this->belongsTo('App\SystemPhysic','system_physic_id');
    }
    public function trainner()
    {
        return $this->belongsTo('App\User','trainner_id');
    }
     public function patient()
    {
        return $this->belongsTo('App\User','patient_id');
    }
    public function branch()
    {
        return $this->belongsTo('App\Branch','branch_id');
    }   
}
