<?php

namespace App\Rules;

use Illuminate\Validation\Rule;

class SitioRules
{
    public static function rules(bool $isUpdate = false, $id = null): array
    {
        return [
            'nombre' => ['required', 'string', 'max:120'],
            'responsable' => ['required', 'string', 'max:20', 'exists:users,cedula'],
            'cantidad_personas' => ['required', 'integer', 'min:1'],
            'activo' => ['required', Rule::in([0, 1])],
        ];
    }
}
