Files
minicrm/app/Filament/Resources/Customers/Schemas/CustomerForm.php
phuongtc 887765bbd7 feat: AfterSales CRM - SOP compliant real-estate customer care system
- Departments + cross-department transfer workflow
- Role-based closing (staff→resolved, manager→closed) with proof_of_resolution
- Private file storage with collection system + temporary signed URLs
- Dashboard: resolved tickets table, stats, handler performance bar chart
- Spatie RBAC (admin/manager/staff)
- Notifications: TicketTransferred, TicketClosed (database + mail)
- Pest tests: 8 tests, 21 assertions
- Docker production-ready (Dockerfile + compose + entrypoint)
2026-04-27 05:29:48 +00:00

51 lines
1.7 KiB
PHP

<?php
namespace App\Filament\Resources\Customers\Schemas;
use Filament\Forms\Components\Select;
use Filament\Forms\Components\Textarea;
use Filament\Forms\Components\TextInput;
use Filament\Schemas\Components\Section;
use Filament\Schemas\Schema;
class CustomerForm
{
public static function configure(Schema $schema): Schema
{
return $schema
->components([
Section::make('Customer Information')
->schema([
TextInput::make('name')
->required()
->maxLength(255),
TextInput::make('email')
->email()
->maxLength(255),
TextInput::make('phone')
->tel()
->maxLength(255),
Textarea::make('address')
->columnSpanFull(),
Select::make('status')
->options([
'active' => 'Active',
'inactive' => 'Inactive',
])
->default('active')
->required(),
])
->columns(2),
Section::make('Owned Products')
->schema([
Select::make('products')
->relationship('products', 'name')
->multiple()
->preload()
->columnSpanFull(),
]),
]);
}
}