43 lines
1.5 KiB
PHP
43 lines
1.5 KiB
PHP
<?php
|
|
|
|
namespace App\Filament\Resources\Explanations\Schemas;
|
|
|
|
use App\Models\Explanation;
|
|
use Filament\Infolists\Components\TextEntry;
|
|
use Filament\Schemas\Schema;
|
|
|
|
class ExplanationInfolist
|
|
{
|
|
public static function configure(Schema $schema): Schema
|
|
{
|
|
return $schema
|
|
->components([
|
|
TextEntry::make('employee.id')
|
|
->label(__('hr.fields.employee')),
|
|
TextEntry::make('explanation_date')
|
|
->label(__('hr.fields.explanation_date'))
|
|
->date(),
|
|
TextEntry::make('reason')
|
|
->label(__('hr.fields.reason')),
|
|
TextEntry::make('description')
|
|
->label(__('hr.fields.description'))
|
|
->columnSpanFull(),
|
|
TextEntry::make('attachment_path')
|
|
->label(__('hr.fields.attachment'))
|
|
->placeholder('-'),
|
|
TextEntry::make('created_at')
|
|
->label(__('hr.fields.created_at'))
|
|
->dateTime()
|
|
->placeholder('-'),
|
|
TextEntry::make('updated_at')
|
|
->label(__('hr.fields.updated_at'))
|
|
->dateTime()
|
|
->placeholder('-'),
|
|
TextEntry::make('deleted_at')
|
|
->label(__('hr.fields.deleted_at'))
|
|
->dateTime()
|
|
->visible(fn (Explanation $record): bool => $record->trashed()),
|
|
]);
|
|
}
|
|
}
|