This commit is contained in:
Andras Bacsai 2023-05-22 09:53:31 +02:00
parent c4397adfce
commit 828ecc6803
2 changed files with 8 additions and 6 deletions

View File

@ -16,12 +16,14 @@ public function isStatic(): Attribute
{
return Attribute::make(
set: function ($value) {
if ($value) {
$this->application->ports_exposes = '80';
} else {
$this->application->ports_exposes = '3000';
if (is_null($this->application->ports_exposes)) {
if ($value) {
$this->application->ports_exposes = '80';
} else {
$this->application->ports_exposes = '3000';
}
$this->application->save();
}
$this->application->save();
return $value;
}
);

View File

@ -55,7 +55,7 @@
<x-inputs.checkbox instantSave id="is_static" label="Static website?" />
<x-inputs.checkbox helper="Git Webhooks won't deploy your application is you turn it off." instantSave
id="is_auto_deploy" label="Auto Deploy?" />
<x-inputs.checkbox helper="Preview deployments" instantSave id="is_previews" label="Previews?" />
{{-- <x-inputs.checkbox helper="Preview deployments" instantSave id="is_previews" label="Previews?" /> --}}
<x-inputs.checkbox instantSave id="is_git_submodules_allowed" label="Git Submodules Allowed?" />
<x-inputs.checkbox instantSave id="is_git_lfs_allowed" label="Git LFS Allowed?" />
{{-- <x-inputs.checkbox disabled instantSave id="is_dual_cert" label="Dual Certs?" />