instalasi-sim-rs/app/Models/Insurance.php

48 lines
1.1 KiB
PHP

<?php
namespace App\Models;
use App\Traits\InteractsWithUuid;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
class Insurance extends Model
{
use HasFactory, InteractsWithUuid;
protected $table = 'm_insurance';
protected $primaryKey = 'id';
public $incrementing = false;
protected $keyType = 'string';
protected $fillable = [
'id',
'code',
'name',
'address',
'phone_number',
'email',
'contact_person',
'contact_person_phone',
'coverage_percentage',
'coverage_description',
'agreement_details',
'agreement_start_date',
'agreement_end_date',
'agreement_file_path',
'is_active'
];
protected $casts = [
'coverage_percentage' => 'decimal:2',
'agreement_start_date' => 'date',
'agreement_end_date' => 'date',
'is_active' => 'boolean',
];
protected $attributes = [
'coverage_percentage' => 100.00,
'is_active' => true,
];
}