How to enable/disable field when another field is null/filled

DateTimePicker::make('starts_at'),
DateTimePicker::make('ends_at')
->disabled(fn (Get $get): bool => empty($get('starts_at'))),
DateTimePicker::make('starts_at'),
DateTimePicker::make('ends_at')
->disabled(fn (Get $get): bool => empty($get('starts_at'))),
Solution:
starts_at should be ->live()
Jump to solution
2 Replies
Solution
LeandroFerreira
LeandroFerreira5mo ago
starts_at should be ->live()
@ryanvelbon
@ryanvelbon5mo ago
That did the trick! Cheers!