Files
streakfit-api/app/Filament/Resources/Routines/Schemas/RoutineForm.php
T
2026-07-19 05:09:29 +02:00

33 lines
928 B
PHP

<?php
namespace App\Filament\Resources\Routines\Schemas;
use Filament\Forms\Components\Select;
use Filament\Forms\Components\Textarea;
use Filament\Forms\Components\TextInput;
use Filament\Forms\Components\Toggle;
use Filament\Schemas\Schema;
class RoutineForm
{
public static function configure(Schema $schema): Schema
{
return $schema
->components([
Select::make('user_id')
->relationship('user', 'name')
->required(),
TextInput::make('name')
->required(),
TextInput::make('slug')
->required(),
Textarea::make('description')
->columnSpanFull(),
Toggle::make('is_public')
->required(),
TextInput::make('estimated_minutes')
->numeric(),
]);
}
}