Files
onboard/app/Models/MedicalHistoryCorrection.php

42 lines
958 B
PHP

<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Model;
class MedicalHistoryCorrection extends Model
{
protected $fillable = [
'medical_history_id',
'medical_card_number',
'full_name',
'birth_date',
'recipient_date',
'extract_date',
'death_date',
'male',
'urgency_id',
'hospital_result_id',
'visit_result_id',
'user_id',
'mis_user_id',
'comment',
'delivery_from_address',
'delivery_from_object_id',
];
protected $casts = [
'birth_date' => 'date:Y-m-d',
'recipient_date' => 'datetime:Y-m-d H:i:s',
'extract_date' => 'datetime:Y-m-d H:i:s',
'death_date' => 'datetime:Y-m-d H:i:s',
'male' => 'boolean',
'delivery_from_object_id' => 'integer'
];
public function medicalHistory()
{
return $this->belongsTo(MedicalHistory::class);
}
}