<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\SoftDeletes;

class CorporateVehicle extends Model
{
    use SoftDeletes;

    protected $fillable = [
        'tenant_id',
        'plate_number',
        'model',
        'vehicle_type',
        'ownership_type',
        'year',
        'driver',
        'status',
        'mileage',
        'memo',
        // 법인차량 전용
        'purchase_date',
        'purchase_price',
        // 렌트/리스 전용
        'contract_date',
        'rent_company',
        'rent_company_tel',
        'rent_period',
        'agreed_mileage',
        'vehicle_price',
        'residual_value',
        'deposit',
        'monthly_rent',
        'monthly_rent_tax',
        'insurance_company',
        'insurance_company_tel',
    ];

    protected $casts = [
        'year' => 'integer',
        'mileage' => 'integer',
        'purchase_price' => 'integer',
        'vehicle_price' => 'integer',
        'residual_value' => 'integer',
        'deposit' => 'integer',
        'monthly_rent' => 'integer',
        'monthly_rent_tax' => 'integer',
    ];
}
