From 17ac2ce0ed52874616c79c910667e41e34604826 Mon Sep 17 00:00:00 2001
From: wangzhibo <wangzhibo@shsening.com>
Date: 星期一, 31 八月 2026 13:14:12 +0800
Subject: [PATCH] add translation app

---
 xiaozhi-esp32-server/main/manager-web/src/components/CacheViewer.vue |   14 +++++++++++---
 1 files changed, 11 insertions(+), 3 deletions(-)

diff --git a/xiaozhi-esp32-server/main/manager-web/src/components/CacheViewer.vue b/xiaozhi-esp32-server/main/manager-web/src/components/CacheViewer.vue
index 5bd234e..5dfafdb 100644
--- a/xiaozhi-esp32-server/main/manager-web/src/components/CacheViewer.vue
+++ b/xiaozhi-esp32-server/main/manager-web/src/components/CacheViewer.vue
@@ -1,7 +1,7 @@
 <template>
   <el-dialog
     :title="$t('cache.dialogTitle')"
-    :visible.sync="visible"
+    :visible.sync="dialogVisible"
     width="70%"
     :before-close="handleClose"
   >
@@ -88,6 +88,7 @@
   },
   data() {
     return {
+      dialogVisible: this.visible,
       isLoading: true,
       cacheAvailable: false,
       cacheData: {
@@ -100,9 +101,13 @@
   },
   watch: {
     visible(newVal) {
+      this.dialogVisible = newVal;
       if (newVal) {
         this.loadCacheData();
       }
+    },
+    dialogVisible(val) {
+      this.$emit('update:visible', val);
     }
   },
   methods: {
@@ -168,8 +173,11 @@
       window.location.reload();
     },
     
-    handleClose() {
-      this.$emit('update:visible', false);
+    handleClose(done) {
+      this.dialogVisible = false;
+      if (typeof done === 'function') {
+        done();
+      }
     }
   }
 };

--
Gitblit v1.9.1