Initial commit
This commit is contained in:
30
app/Filament/Resources/Authors/Schemas/AuthorForm.php
Normal file
30
app/Filament/Resources/Authors/Schemas/AuthorForm.php
Normal file
@@ -0,0 +1,30 @@
|
||||
<?php
|
||||
|
||||
namespace App\Filament\Resources\Authors\Schemas;
|
||||
|
||||
use Filament\Forms\Components\TextInput;
|
||||
use Filament\Schemas\Schema;
|
||||
|
||||
class AuthorForm
|
||||
{
|
||||
public static function configure(Schema $schema): Schema
|
||||
{
|
||||
return $schema
|
||||
->components([
|
||||
TextInput::make('name')
|
||||
->maxLength(255)
|
||||
->required(),
|
||||
TextInput::make('slug')
|
||||
->maxLength(255)
|
||||
->unique(ignoreRecord: true)
|
||||
->required(),
|
||||
TextInput::make('website')
|
||||
->url()
|
||||
->maxLength(500)
|
||||
->default(null),
|
||||
TextInput::make('user_id')
|
||||
->numeric()
|
||||
->default(null),
|
||||
]);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user