<?php

namespace App\Modules\Pilkades\Models;

use App\Core\Concerns\HasUuid;
use App\Modules\Pilkades\Models\Concerns\BelongsToDesa;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\Relations\HasMany;
use Illuminate\Database\Eloquent\SoftDeletes;

class Tps extends Model
{
    use BelongsToDesa, HasFactory, HasUuid, SoftDeletes;

    protected $table = 'tps';

    protected $fillable = [
        'desa_id',
        'nomor',
        'nama_lokasi',
        'alamat',
        'urutan',
    ];

    public function voters(): HasMany
    {
        return $this->hasMany(Voter::class);
    }
}
