feat: mysql, mariadb

This commit is contained in:
Andras Bacsai
2023-10-24 14:31:28 +02:00
parent b2d111e49a
commit f801bb98cd
41 changed files with 1309 additions and 88 deletions

View File

@@ -12,7 +12,7 @@
</x-slot:modalSubmit>
</x-modal>
<div class="pt-6">
<livewire:project.database.backup-edit :backup="$backup" :s3s="$s3s" :status="data_get($database,'status')" />
<livewire:project.database.backup-edit :backup="$backup" :s3s="$s3s" :status="data_get($database, 'status')" />
<h3 class="py-4">Executions</h3>
<livewire:project.database.backup-executions :backup="$backup" :executions="$executions" />
</div>

View File

@@ -13,36 +13,48 @@
</x-modal>
<div x-data="{ activeTab: window.location.hash ? window.location.hash.substring(1) : 'general' }" class="flex h-full pt-6">
<div class="flex flex-col gap-4 min-w-fit">
<a :class="activeTab === 'general' && 'text-white'" @click.prevent="activeTab = 'general';
window.location.hash = 'general'" href="#">General</a>
<a :class="activeTab === 'general' && 'text-white'"
@click.prevent="activeTab = 'general';
window.location.hash = 'general'"
href="#">General</a>
<a :class="activeTab === 'environment-variables' && 'text-white'"
@click.prevent="activeTab = 'environment-variables'; window.location.hash = 'environment-variables'"
href="#">Environment
Variables</a>
<a :class="activeTab === 'server' && 'text-white'" @click.prevent="activeTab = 'server';
window.location.hash = 'server'" href="#">Server
<a :class="activeTab === 'server' && 'text-white'"
@click.prevent="activeTab = 'server';
window.location.hash = 'server'"
href="#">Server
</a>
<a :class="activeTab === 'storages' && 'text-white'" @click.prevent="activeTab = 'storages';
window.location.hash = 'storages'" href="#">Storages
<a :class="activeTab === 'storages' && 'text-white'"
@click.prevent="activeTab = 'storages';
window.location.hash = 'storages'"
href="#">Storages
</a>
<a :class="activeTab === 'resource-limits' && 'text-white'" @click.prevent="activeTab = 'resource-limits';
window.location.hash = 'resource-limits'" href="#">Resource Limits
<a :class="activeTab === 'resource-limits' && 'text-white'"
@click.prevent="activeTab = 'resource-limits';
window.location.hash = 'resource-limits'"
href="#">Resource Limits
</a>
<a :class="activeTab === 'danger' && 'text-white'" @click.prevent="activeTab = 'danger';
window.location.hash = 'danger'" href="#">Danger Zone
<a :class="activeTab === 'danger' && 'text-white'"
@click.prevent="activeTab = 'danger';
window.location.hash = 'danger'"
href="#">Danger Zone
</a>
</div>
<div class="w-full pl-8">
<div x-cloak x-show="activeTab === 'general'" class="h-full">
@if ($database->type() === 'standalone-postgresql')
<livewire:project.database.postgresql.general :database="$database" />
@endif
@if ($database->type() === 'standalone-redis')
@elseif ($database->type() === 'standalone-redis')
<livewire:project.database.redis.general :database="$database" />
@elseif ($database->type() === 'standalone-mongodb')
<livewire:project.database.mongodb.general :database="$database" />
@elseif ($database->type() === 'standalone-mysql')
<livewire:project.database.mysql.general :database="$database" />
@elseif ($database->type() === 'standalone-mariadb')
<livewire:project.database.mariadb.general :database="$database" />
@endif
@if ($database->type() === 'standalone-mongodb')
<livewire:project.database.mongodb.general :database="$database" />
@endif
</div>
<div x-cloak x-show="activeTab === 'environment-variables'">
<livewire:project.shared.environment-variable.all :resource="$database" />