<?php

namespace Modules\Lpj\Models;

use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Modules\Lpj\Database\Factories\ObjekJaminanFactory;

class ObjekJaminan extends Base
{
    use HasFactory;

    protected $table = 'objek_jaminan';
    /**
     * The attributes that are mass assignable.
     */
    protected $fillable = ['name_objek', 'foto_jaminan_id', 'foto_objek'];



    public function lantaiUnit(){
        return $this->hasMany(LantaiUnit::class, 'objek_jaminan_id', 'foto_jaminan_id');
    }

    protected static function newFactory(): ObjekJaminanFactory
    {
        //return ObjekJaminanFactory::new();
    }
}
