nanosanteservice/app/Models/NhMedicalPrescription.php

55 lines
1.1 KiB
PHP

<?php
/**
* Created by Reliese Model.
*/
namespace App\Models;
use Carbon\Carbon;
use Illuminate\Database\Eloquent\Model;
/**
* Class NhMedicalPrescription
*
* @property int $id
* @property int $drug_or_device_id
* @property string $dosage
* @property int $quantity
* @property float $unit_price
* @property float $insured_paid_amount
* @property float $insurer_paid_amount
* @property Carbon $created_at
* @property Carbon $updated_at
*
* @package App\Models
*/
class NhMedicalPrescription extends Model
{
protected $table = 'nh_medical_prescriptions';
protected $casts = [
'drug_or_device_id' => 'int',
'quantity' => 'int',
'unit_price' => 'float',
'insured_paid_amount' => 'float',
'insurer_paid_amount' => 'float'
];
protected $fillable = [
'drug_or_device_id',
'dosage',
'quantity',
'unit_price',
'insured_paid_amount',
'insurer_paid_amount',
'created_at',
'updated_at'
];
public function drug_or_device()
{
return $this->belongsTo(NhDrugsAndDevice::class, 'drug_or_device_id');
}
}