add helper text to mounts

This commit is contained in:
Boy132 2024-06-06 10:18:05 +02:00
parent 3010e3d61e
commit e0d7a094ab

View File

@ -576,6 +576,7 @@ class EditServer extends EditRecord
->options(fn (Server $server) => $server->node->mounts->mapWithKeys(fn ($mount) => [$mount->id => $mount->name])) ->options(fn (Server $server) => $server->node->mounts->mapWithKeys(fn ($mount) => [$mount->id => $mount->name]))
->descriptions(fn (Server $server) => $server->node->mounts->mapWithKeys(fn ($mount) => [$mount->id => "$mount->source -> $mount->target"])) ->descriptions(fn (Server $server) => $server->node->mounts->mapWithKeys(fn ($mount) => [$mount->id => "$mount->source -> $mount->target"]))
->label('Mounts') ->label('Mounts')
->helperText(fn (Server $server) => $server->node->mounts->isNotEmpty() ? '' : 'No Mounts exist for this Node')
->columnSpanFull(), ->columnSpanFull(),
]), ]),
Tabs\Tab::make('Databases') Tabs\Tab::make('Databases')