fix: remove old modal

This commit is contained in:
Andras Bacsai
2023-07-28 13:31:47 +02:00
parent 331b85c57e
commit 0d56d3a555
14 changed files with 86 additions and 99 deletions

View File

@@ -1,14 +1,17 @@
<div x-data="{ deleteDestination: false }">
<x-naked-modal show="deleteDestination" title="Delete Destination"
message='This destination will be deleted. It is not reversible. <br>Please think again.' />
<div>
<x-modal yesOrNo modalId="deleteDestination" modalTitle="Delete Destination">
<x-slot:modalBody>
<p>This destination will be deleted. It is not reversible. <br>Please think again.</p>
</x-slot:modalBody>
</x-modal>
<form class="flex flex-col">
<div class="flex items-center gap-2">
<h1>Destination</h1>
<x-forms.button wire:click.prevent='submit' type="submit">
Save
</x-forms.button>
@if ($destination->server->id === 0 && $destination->network !== 'coolify')
<x-forms.button x-on:click.prevent="deleteDestination = true">
@if ($destination->network !== 'coolify')
<x-forms.button isError isModal modalId="deleteDestination">
Delete
</x-forms.button>
@endif

View File

@@ -6,7 +6,7 @@
<x-forms.input id="name" label="Name" required />
<x-forms.input id="network" label="Network" required />
</div>
<x-forms.select id="server_id" label="Select a server" required>
<x-forms.select id="server_id" label="Select a server" required wire:change="generate_name">
<option disabled>Select a server</option>
@foreach ($servers as $server)
<option value="{{ $server->id }}">{{ $server->name }}</option>