refactor: restrict intern dashboard updates to pending status and automate username assignment from email

This commit is contained in:
Ümit Tunç
2026-07-01 17:06:11 +03:00
parent 32c556a87b
commit 5b46b4ac9e
3 changed files with 23 additions and 24 deletions
@@ -107,13 +107,16 @@ class InternApplicationResource extends Resource
TextInput::make('username')
->label('Kullanıcı Adı')
->unique(ignoreRecord: true)
->nullable(),
->default(fn ($record) => $record?->email)
->disabled()
->dehydrated()
->autocomplete('new-username'),
TextInput::make('password')
->label('Şifre')
->password()
->revealable()
->autocomplete('new-password')
->formatStateUsing(fn () => null)
->dehydrateStateUsing(fn ($state) => filled($state) ? Hash::make($state) : null)
->dehydrated(fn ($state) => filled($state))