<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;

class Regency extends Model
{
    use HasFactory;

    protected $table = 'regencies';
    protected $guarded = [];

    public function districts()
    {
        return $this->hasMany(District::class);
    }

    public function district()
    {
        return $this->hasOne(District::class);
    }
}
