From 77859c7daa67069d24b8a4c65a3aefaf791bfafc Mon Sep 17 00:00:00 2001 From: Soulter <905617992@qq.com> Date: Thu, 27 Nov 2025 16:39:36 +0800 Subject: [PATCH] feat: enhance provider status display in ProviderPage - Added a tooltip to show detailed provider status, including availability and error messages. - Refactored item details template to include status chips for better visual representation. - Removed unused status section to streamline the UI. --- dashboard/src/views/ProviderPage.vue | 99 ++++++++++++---------------- 1 file changed, 43 insertions(+), 56 deletions(-) diff --git a/dashboard/src/views/ProviderPage.vue b/dashboard/src/views/ProviderPage.vue index 32f5a60a8..a5716f7bf 100644 --- a/dashboard/src/views/ProviderPage.vue +++ b/dashboard/src/views/ProviderPage.vue @@ -69,6 +69,25 @@ :loading="isProviderTesting(provider.id)" @toggle-enabled="providerStatusChange" :bglogo="getProviderIcon(provider.provider)" @delete="deleteProvider" @edit="configExistingProvider" @copy="copyProvider" :show-copy-button="true"> + - - - - mdi-heart-pulse - {{ tm('availability.title') }} - - - mdi-refresh - {{ tm('availability.refresh') }} - - - {{ showStatus ? tm('logs.collapse') : tm('logs.expand') }} - {{ showStatus ? 'mdi-chevron-up' : 'mdi-chevron-down' }} - - - - - - - - {{ tm('availability.noData') }} - - - - - - - - mdi-check-circle - mdi-alert-circle - - - {{ status.id }} - - - {{ getStatusText(status.status) }} - - - - {{ tm('availability.errorMessage') }}: {{ status.error }} - - - - - - - - - - @@ -751,11 +735,14 @@ export default { return this.testingProviders.includes(providerId); }, + getProviderStatus(providerId) { + return this.providerStatuses.find(s => s.id === providerId); + }, + async testSingleProvider(provider) { if (this.isProviderTesting(provider.id)) return; this.testingProviders.push(provider.id); - this.showStatus = true; // 自动展开状态部分 // 更新UI为pending状态 const statusIndex = this.providerStatuses.findIndex(s => s.id === provider.id);