<?php

namespace App\Models\Tenancy;

use App\Models\Doctor;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\Relations\HasOne;

class Employee extends Model
{
    protected $hidden = [
        'position_id',
        'indoor',
        'work_days',
        'working_hours',
        'start_date',
        'creator_id',
        'is_user',
        'status',
        'publish',
        'agree',
        'visibility',
        'visits_control',
        'technician',
        'cashier_sms_enabled',
        'ehr_control',
        'is_resident',
        'doctor_id',
        'sms_position_id',
        'sort_id',
    ];

    public function doctor(): HasOne
    {
        return $this->hasOne(Doctor::class, 'id', 'doctor_id');
    }
}
