Select::make('organization_type')
->live()
->options(OrganizationType::class)
->required()
->afterStateUpdated(function ($state, Set $set) {
$set('organization_type', $state);
}),
TextInput::make('name')
->label('Organization Name')
->default( Filament::getUsername(auth()->user()) . " 's Company")
->visible(fn (Get $get): bool =>
$get('organization_type') === 'company'
),
TextInput::make('name')
->label('Individual Name')
->default( Filament::getUsername(auth()->user()) )
->visible(fn (Get $get): bool =>
$get('organization_type') === 'individual'
),
Select::make('organization_type')
->live()
->options(OrganizationType::class)
->required()
->afterStateUpdated(function ($state, Set $set) {
$set('organization_type', $state);
}),
TextInput::make('name')
->label('Organization Name')
->default( Filament::getUsername(auth()->user()) . " 's Company")
->visible(fn (Get $get): bool =>
$get('organization_type') === 'company'
),
TextInput::make('name')
->label('Individual Name')
->default( Filament::getUsername(auth()->user()) )
->visible(fn (Get $get): bool =>
$get('organization_type') === 'individual'
),