base commit

This commit is contained in:
Mekan1206
2026-07-30 17:24:40 +05:00
commit a794dacd39
345 changed files with 29597 additions and 0 deletions

View File

@@ -0,0 +1,32 @@
<?php
namespace App\Filament\Resources\EmployeeDocuments\Schemas;
use App\Enums\DocumentType;
use App\Filament\Support\HrForm;
use Filament\Forms\Components\Select;
use Filament\Forms\Components\TextInput;
use Filament\Schemas\Schema;
class EmployeeDocumentForm
{
public static function configure(Schema $schema): Schema
{
return $schema
->components([
HrForm::employeeSelect(),
Select::make('document_type')
->options(DocumentType::class)
->required()
->native(false),
TextInput::make('title')
->required()
->maxLength(255),
HrForm::fileUpload('file_path')
->label('Document')
->required()
->acceptedFileTypes(['application/pdf', 'image/*', 'application/msword', 'application/vnd.openxmlformats-officedocument.wordprocessingml.document'])
->maxSize(15360),
]);
}
}

View File

@@ -0,0 +1,34 @@
<?php
namespace App\Filament\Resources\EmployeeDocuments\Schemas;
use App\Models\EmployeeDocument;
use Filament\Infolists\Components\TextEntry;
use Filament\Schemas\Schema;
class EmployeeDocumentInfolist
{
public static function configure(Schema $schema): Schema
{
return $schema
->components([
TextEntry::make('employee.id')
->label('Employee'),
TextEntry::make('document_type')
->badge(),
TextEntry::make('title'),
TextEntry::make('file_path'),
TextEntry::make('uploaded_at')
->dateTime(),
TextEntry::make('created_at')
->dateTime()
->placeholder('-'),
TextEntry::make('updated_at')
->dateTime()
->placeholder('-'),
TextEntry::make('deleted_at')
->dateTime()
->visible(fn (EmployeeDocument $record): bool => $record->trashed()),
]);
}
}