<?php

namespace App\Filament\Resources\PersonnelEnseignants\Schemas;

use Filament\Forms\Components\Select;
use Filament\Forms\Components\TextInput;
use Filament\Schemas\Schema;

class PersonnelEnseignantForm
{
    public static function configure(Schema $schema): Schema
    {
        return $schema
            ->components([
                Select::make('charge_id')
                    ->relationship('charge', 'libelle')
                    ->required(),
                Select::make('etablissement_id')
                    ->relationship('etablissement', 'libellefr')
                    ->required(),
                Select::make('discipline_id')
                    ->relationship('discipline', 'libelle')
                    ->required(),
                TextInput::make('nombre_profs')
                    ->required()
                    ->numeric(),
                Select::make('annee_id')
                    ->relationship('annee', 'libelle')
                    ->required(),
            ]);
    }
}
