From b11e16b72eb6b2301ca8abc1afa11d86caa5d99c Mon Sep 17 00:00:00 2001 From: Bozhidar Date: Wed, 11 Sep 2024 15:51:42 +0300 Subject: [PATCH] update --- .../Customer/App/Filament/Pages/CloneGitRepository.php | 5 ++--- .../2024_09_10_142433_create_git_repositories_table.php | 2 +- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/web/Modules/Customer/App/Filament/Pages/CloneGitRepository.php b/web/Modules/Customer/App/Filament/Pages/CloneGitRepository.php index ff9d8e1..99fd227 100644 --- a/web/Modules/Customer/App/Filament/Pages/CloneGitRepository.php +++ b/web/Modules/Customer/App/Filament/Pages/CloneGitRepository.php @@ -54,8 +54,7 @@ class CloneGitRepository extends Page ->label('SSH Key') ->options(\App\Models\GitSshKey::all()->pluck('name', 'id')) ->columnSpanFull() - ->live() - ->required(), + ->live(), TextInput::make('url') ->label('URL') @@ -165,7 +164,7 @@ class CloneGitRepository extends Page $newGitRepository->dir = $this->state['dir']; $newGitRepository->clone_from = $this->state['clone_from']; $newGitRepository->domain_id = $this->state['domain_id']; - $newGitRepository->git_ssh_key_id = $this->state['git_ssh_key_id']; + $newGitRepository->git_ssh_key_id = (int) $this->state['git_ssh_key_id']; $newGitRepository->status = GitRepository::STATUS_PENDING; $newGitRepository->save(); diff --git a/web/database/migrations/2024_09_10_142433_create_git_repositories_table.php b/web/database/migrations/2024_09_10_142433_create_git_repositories_table.php index 0bd4839..667aa10 100644 --- a/web/database/migrations/2024_09_10_142433_create_git_repositories_table.php +++ b/web/database/migrations/2024_09_10_142433_create_git_repositories_table.php @@ -29,7 +29,7 @@ return new class extends Migration $table->string('dir')->nullable(); $table->unsignedBigInteger('domain_id'); - $table->unsignedBigInteger('git_ssh_key_id'); + $table->unsignedBigInteger('git_ssh_key_id')->nullable(); $table->timestamps(); });