coolify/resources/views/livewire/project/shared/environment-variable/show.blade.php

74 lines
3.5 KiB
PHP
Raw Normal View History

2023-07-13 13:16:24 +02:00
<div>
2023-12-07 19:06:32 +01:00
<form wire:submit='submit'
class="flex flex-col gap-2 p-4 m-2 border lg:items-center border-coolgray-300 lg:m-0 lg:p-0 lg:border-0 lg:flex-row">
2023-10-24 15:41:21 +02:00
@if ($isLocked)
<svg class="icon" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
<g fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2">
<path d="M5 13a2 2 0 0 1 2-2h10a2 2 0 0 1 2 2v6a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2v-6z" />
<path d="M11 16a1 1 0 1 0 2 0a1 1 0 0 0-2 0m-3-5V7a4 4 0 1 1 8 0v4" />
</g>
</svg>
2023-09-27 15:48:19 +02:00
<x-forms.input disabled id="env.key" />
@else
2023-10-24 15:41:21 +02:00
@if ($isDisabled)
<x-forms.input disabled id="env.key" />
<x-forms.input disabled type="password" id="env.value" />
2024-01-23 17:13:23 +01:00
@if ($env->is_shared)
<x-forms.input disabled type="password" id="env.real_value" />
@endif
@if ($type !== 'service' && !$isSharedVariable)
2023-10-24 15:41:21 +02:00
<x-forms.checkbox instantSave id="env.is_build_time" label="Build Variable?" />
@endif
@else
@if ($env->is_multiline)
2024-03-18 12:28:53 +01:00
<x-forms.input isMultiline="{{ $env->is_multiline }}" id="env.key" />
2024-03-15 22:02:37 +01:00
<x-forms.textarea type="password" id="env.value" />
@else
<x-forms.input id="env.key" />
<x-forms.input type="password" id="env.value" />
@endif
2024-01-23 17:13:23 +01:00
@if ($env->is_shared)
<x-forms.input disabled type="password" id="env.real_value" />
2024-03-15 22:02:37 +01:00
@else
<x-forms.checkbox instantSave id="env.is_multiline" label="Is Multiline?" />
2024-01-23 17:13:23 +01:00
@endif
@if ($type !== 'service' && !$isSharedVariable)
2023-10-24 15:41:21 +02:00
<x-forms.checkbox instantSave id="env.is_build_time" label="Build Variable?" />
@endif
2023-09-27 15:48:19 +02:00
@endif
2023-09-22 11:23:49 +02:00
@endif
2023-06-15 09:15:41 +02:00
<div class="flex gap-2">
2023-10-24 15:41:21 +02:00
@if ($isLocked)
2024-03-20 12:54:06 +01:00
<x-modal-confirmation isErrorButton buttonTitle="Delete">
2024-01-31 16:14:12 +01:00
You will delete environment variable <span
class="font-bold text-warning">{{ $env->key }}</span>.
2024-03-20 12:54:06 +01:00
</x-modal-confirmation>
2023-10-24 15:41:21 +02:00
@else
@if ($isDisabled)
<x-forms.button disabled type="submit">
Update
</x-forms.button>
2023-10-26 10:02:45 +02:00
<x-forms.button wire:click='lock'>
Lock
</x-forms.button>
2024-03-20 12:54:06 +01:00
<x-modal-confirmation isErrorButton buttonTitle="Delete">
2024-01-31 16:14:12 +01:00
You will delete environment variable <span
class="font-bold text-warning">{{ $env->key }}</span>.
2024-03-20 12:54:06 +01:00
</x-modal-confirmation>
2023-10-24 15:41:21 +02:00
@else
<x-forms.button type="submit">
Update
</x-forms.button>
<x-forms.button wire:click='lock'>
Lock
</x-forms.button>
2024-03-20 12:54:06 +01:00
<x-modal-confirmation isErrorButton buttonTitle="Delete">
2024-01-31 16:14:12 +01:00
You will delete environment variable <span
class="font-bold text-warning">{{ $env->key }}</span>.
2024-03-20 12:54:06 +01:00
</x-modal-confirmation>
2023-10-24 15:41:21 +02:00
@endif
2023-09-27 15:48:19 +02:00
@endif
2023-05-04 22:29:14 +02:00
</div>
</form>
</div>