mirror of
https://github.com/vitodeploy/vito.git
synced 2025-04-19 18:01:37 +00:00
fixes #311
This commit is contained in:
parent
7086e84c3c
commit
386d8e73a7
@ -12,10 +12,12 @@ class Install
|
|||||||
{
|
{
|
||||||
public function install(Server $server, array $input): Service
|
public function install(Server $server, array $input): Service
|
||||||
{
|
{
|
||||||
|
$input['type'] = config('core.service_types')[$input['name']];
|
||||||
|
|
||||||
$service = new Service([
|
$service = new Service([
|
||||||
'server_id' => $server->id,
|
'server_id' => $server->id,
|
||||||
'name' => $input['name'],
|
'name' => $input['name'],
|
||||||
'type' => config('core.service_types')[$input['name']],
|
'type' => $input['type'],
|
||||||
'version' => $input['version'],
|
'version' => $input['version'],
|
||||||
'status' => ServiceStatus::INSTALLING,
|
'status' => ServiceStatus::INSTALLING,
|
||||||
]);
|
]);
|
||||||
|
@ -44,6 +44,7 @@ protected function getHeaderActions(): array
|
|||||||
->icon('heroicon-o-archive-box-arrow-down')
|
->icon('heroicon-o-archive-box-arrow-down')
|
||||||
->modalWidth(MaxWidth::Large)
|
->modalWidth(MaxWidth::Large)
|
||||||
->authorize(fn () => auth()->user()?->can('create', [Service::class, $this->server]))
|
->authorize(fn () => auth()->user()?->can('create', [Service::class, $this->server]))
|
||||||
|
->modalSubmitActionLabel('Install')
|
||||||
->form([
|
->form([
|
||||||
Select::make('name')
|
Select::make('name')
|
||||||
->searchable()
|
->searchable()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user