<?php

namespace App\Models;

# use Illuminate\Database\Eloquent\Model;

class Erx extends Model
{
    protected $table = "erx";

    public function managerPro(){
        return $this->hasOne(Pro::class, 'id', 'manager_pro_id');
    }

    public function hcpPro(){
        return $this->hasOne(Pro::class, 'id', 'hcp_pro_id');
    }

    public function patient(){
        return $this->hasOne(Client::class, 'id', 'client_id');
    }

    public function client(){
        return $this->hasOne(Client::class, 'id', 'client_id');
    }

    public function note(){
        return $this->hasOne(Note::class, 'id', 'note_id');
    }

}
