36 lines
2.2 KiB
PHP

<x-layouts.admin>
<x-slot name="title">修改系统数据库</x-slot>
<x-slot name="content">
<div class="my-6">
@include('system_settings.partials.navigation')
<form method="POST" action="{{ route('system-settings.databases.system.update') }}" class="max-w-xl rounded-xl border border-[#D8D2C7] bg-white p-6">
@csrf
@method('PATCH')
@if ($errors->any())
<div class="mb-5 rounded-lg bg-red-50 px-4 py-3 text-sm text-[#B80000]" role="alert">
@foreach ($errors->all() as $error)<p>{{ $error }}</p>@endforeach
</div>
@endif
<div class="mb-6 rounded-lg bg-[#F7F0DE] px-4 py-3 text-sm leading-6 text-[#856632]">
只需填写负责人提供的系统数据库密码。连接地址、账号和加密方式由系统自动设置。
</div>
<label class="block">
<span class="text-xs font-medium text-[#171717]">系统数据库密码</span>
<input type="password" name="password" required maxlength="1000" autocomplete="current-password" autofocus class="mt-1 h-[34px] w-full rounded-lg border border-[#D8D2C7] bg-white px-3 text-[13px] text-[#171717] focus:border-[#856632] focus:outline-none focus:ring-2 focus:ring-[#856632]/20">
<span class="mt-2 block text-xs leading-5 text-[#595959]">密码不会显示,也不会提交到 Git。连接失败时仍保留当前数据库。</span>
</label>
<div class="mt-6 flex justify-end gap-3 border-t border-gray-100 pt-5">
<a href="{{ route('system-settings.databases.index') }}" class="inline-flex h-[34px] items-center rounded-lg px-4 text-[13px] font-medium text-[#595959] hover:bg-[#F8F6F1] focus:outline-none focus:ring-2 focus:ring-[#856632]/20">取消</a>
<button type="submit" class="h-[34px] rounded-lg bg-[#856632] px-4 text-[13px] font-medium text-white hover:bg-[#6A5129] focus:outline-none focus:ring-2 focus:ring-[#856632]/20 focus:ring-offset-2">连接系统数据库</button>
</div>
</form>
</div>
</x-slot>
</x-layouts.admin>