F
Filament9mo ago
Panda

Updating input after saving the form

Hi, I want to disable this input when user selects a value and submits the form, I've tried to chain the the disabled method with condition but it only disables it after a fresh page reload. I've also tried adding the live method on the chain but still it has same behaviour.
Section::make('Event')->columnSpanFull()->schema([
Select::make('event_id')
->live()
->label('Event')
->options(fn () => Event::get(['id', 'name'])
->mapWithKeys(fn (Event $event) => [$event->id => $event->name]))
->disabled(fn (Novel $record) => $record->event_id)
->searchable(false)
->native(false)
->helperText('Please check the event details ...')
Section::make('Event')->columnSpanFull()->schema([
Select::make('event_id')
->live()
->label('Event')
->options(fn () => Event::get(['id', 'name'])
->mapWithKeys(fn (Event $event) => [$event->id => $event->name]))
->disabled(fn (Novel $record) => $record->event_id)
->searchable(false)
->native(false)
->helperText('Please check the event details ...')
No description
0 Replies
No replies yetBe the first to reply to this messageJoin
Want results from more Discord servers?
Add your server