Tables\Actions\AttachAction::make()
->form(fn (AttachAction $action): array => [
Forms\Components\Select::make('recordId')
->preload()
->options(fn() => \App\Models\MyModel::query()
->get()
->mapWithKeys(fn($item) => [$item->id => $item->title . ' - ' . $item->part])
->toArray()
)
]),
Tables\Actions\AttachAction::make()
->form(fn (AttachAction $action): array => [
Forms\Components\Select::make('recordId')
->preload()
->options(fn() => \App\Models\MyModel::query()
->get()
->mapWithKeys(fn($item) => [$item->id => $item->title . ' - ' . $item->part])
->toArray()
)
]),