From 36e0aece06d2fedca12e9390f4b08fe0cfedb6ed Mon Sep 17 00:00:00 2001 From: ssongliu <73214554+ssongliu@users.noreply.github.com> Date: Wed, 7 May 2025 08:03:41 +0800 Subject: [PATCH] style: Adjust the style of the ssh configuration page (#8560) --- .../src/views/container/setting/index.vue | 1 + frontend/src/views/host/ssh/ssh/index.vue | 166 +++++++++--------- .../views/setting/backup-account/index.vue | 7 +- .../setting/backup-account/operate/index.vue | 4 +- 4 files changed, 92 insertions(+), 86 deletions(-) diff --git a/frontend/src/views/container/setting/index.vue b/frontend/src/views/container/setting/index.vue index f3e59fd76..3fc7175c0 100644 --- a/frontend/src/views/container/setting/index.vue +++ b/frontend/src/views/container/setting/index.vue @@ -164,6 +164,7 @@ @@ -140,7 +139,6 @@ import PubKey from '@/views/host/ssh/ssh/pubkey/index.vue'; import Root from '@/views/host/ssh/ssh/root/index.vue'; import Port from '@/views/host/ssh/ssh/port/index.vue'; import Address from '@/views/host/ssh/ssh/address/index.vue'; -import MainDiv from '@/components/main-div/index.vue'; import i18n from '@/lang'; import { MsgSuccess } from '@/utils/message'; import { getSSHConf, getSSHInfo, operateSSH, updateSSH, updateSSHByfile } from '@/api/modules/host'; diff --git a/frontend/src/views/setting/backup-account/index.vue b/frontend/src/views/setting/backup-account/index.vue index 16e5c6819..43a8e8317 100644 --- a/frontend/src/views/setting/backup-account/index.vue +++ b/frontend/src/views/setting/backup-account/index.vue @@ -36,7 +36,7 @@ > @@ -160,6 +160,11 @@ const search = async () => { bac.varsJson = JSON.parse(bac.vars); } } + data.value.sort((a, b) => { + if (a.name === 'localhost') return -1; + if (b.name === 'localhost') return 1; + return 0; + }); paginationConfig.total = res.data.total; }) .catch(() => { diff --git a/frontend/src/views/setting/backup-account/operate/index.vue b/frontend/src/views/setting/backup-account/operate/index.vue index c9a9554fa..0fd04bcb4 100644 --- a/frontend/src/views/setting/backup-account/operate/index.vue +++ b/frontend/src/views/setting/backup-account/operate/index.vue @@ -2,7 +2,9 @@ - {{ dialogData.rowData!.name }} + + {{ dialogData.rowData!.name === 'localhost' ? $t('terminal.local') : dialogData.rowData!.name }} +