<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\Relations\BelongsTo;

class MaintenanceDoc extends Model
{
    protected $table    = 'tbl_upload_docs';
    protected $fillable = [
        'upl_num',
        'project_code',
        'project_id',
        'unit_code',
        'unit_id',
        'upl_ref_id',
        'upl_ref_num',
        'upl_ref_code',
        'upl_date',
        'upl_type',
        'upl_filename',
        'upl_filesize',
        'upl_filetype',
        'upl_filepath'
    ];

    public function unit(): BelongsTo
    {
        return $this->belongsTo(MasterUnit::class);
    }

}
