Files

30 lines
805 B
PHP
Raw Permalink Normal View History

2026-05-20 18:25:15 +02:00
<?php
namespace App\Filament\Resources\Games\Schemas;
use Filament\Forms\Components\Select;
use Filament\Forms\Components\TextInput;
use Filament\Schemas\Schema;
class GameForm
{
public static function configure(Schema $schema): Schema
{
return $schema
->components([
TextInput::make('name')
->required()
->maxLength(255),
TextInput::make('slug')
->required()
->maxLength(255),
Select::make('platform_id')
->relationship('platform', 'name')
->required(),
Select::make('genre_id')
->relationship('genre', 'name')
->required(),
]);
}
}