From aad4bcf17b8d72f9d5f73ff9cd68d0b40f1f14a6 Mon Sep 17 00:00:00 2001 From: tiny-craft <137850705+tiny-craft@users.noreply.github.com> Date: Thu, 5 Oct 2023 19:38:33 +0800 Subject: [PATCH] fix: incorrect status display in connection dialog. --- frontend/src/components/dialogs/ConnectionDialog.vue | 4 +++- frontend/src/langs/en.json | 1 + frontend/src/langs/zh-cn.json | 1 + 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/frontend/src/components/dialogs/ConnectionDialog.vue b/frontend/src/components/dialogs/ConnectionDialog.vue index 525e527..e7ea165 100644 --- a/frontend/src/components/dialogs/ConnectionDialog.vue +++ b/frontend/src/components/dialogs/ConnectionDialog.vue @@ -126,6 +126,7 @@ const onSaveConnection = async () => { const resetForm = () => { generalForm.value = connectionStore.newDefaultConnection() generalFormRef.value?.restoreValidation() + testing.value = false showTestResult.value = false testResult.value = '' tab.value = 'general' @@ -135,6 +136,7 @@ watch( () => dialogStore.connDialogVisible, (visible) => { if (visible) { + resetForm() editName.value = get(dialogStore.connParam, 'name', '') generalForm.value = dialogStore.connParam || connectionStore.newDefaultConnection() generalForm.value.ssh.loginType = generalForm.value.ssh.loginType || 'pwd' @@ -286,7 +288,7 @@ const onClose = () => { + :placeholder="$t('dialogue.connection.ssh_addr_tip')" /> :