<?php

namespace App;

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

class SystemPhysic extends Model 
{

    protected $table = 'system_physics';
    public $timestamps = true;

    use SoftDeletes;

    protected $dates = ['deleted_at'];
    protected $fillable = array('name', 'specialty_id');

    public function specialty()
    {
        return $this->belongsTo('App\Specialty');
    }

    
     public function physicals()
    {
        return $this->belongsToMany('App\Physical','system_physics_physical','system_physic_id','physical_id');
    }

}