<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Relations\HasMany;
use Illuminate\Database\Eloquent\Relations\HasOne;

class ClientProChange extends Model
{
    protected $table = 'client_pro_change';

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

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

    public function previousPro(){
        return $this->hasOne(Pro::class, 'id', 'previous_pro_id');
    }
    public function newPro(){
        return $this->hasOne(Pro::class, 'id', 'new_pro_id');
    }
    public function creator(){
        return $this->hasOne(Pro::class, 'id', 'created_by_pro_id');
    }
}
