From bcbcc546577c7c6643e7f0d4ac366f8a013bd306 Mon Sep 17 00:00:00 2001
From: 罗广辉 <guanghui.luo@foxmail.com>
Date: Tue, 20 Jan 2026 13:47:19 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/master'

---
 applications/drone-command/src/page/lock/index.vue |   10 +++++++++-
 1 files changed, 9 insertions(+), 1 deletions(-)

diff --git a/applications/drone-command/src/page/lock/index.vue b/applications/drone-command/src/page/lock/index.vue
index 2215769..9b65ab3 100644
--- a/applications/drone-command/src/page/lock/index.vue
+++ b/applications/drone-command/src/page/lock/index.vue
@@ -45,6 +45,7 @@
   data() {
     return {
       time: '',
+      timeTimer: null,
       passwd: '',
       passwdError: false,
       pass: false,
@@ -52,10 +53,17 @@
   },
   created() {
     this.getTime();
-    setInterval(() => {
+    if (this.timeTimer) clearInterval(this.timeTimer);
+    this.timeTimer = setInterval(() => {
       this.getTime();
     }, 1000);
   },
+  beforeDestroy() {
+    if (this.timeTimer) {
+      clearInterval(this.timeTimer);
+      this.timeTimer = null;
+    }
+  },
   mounted() {},
   computed: {
     ...mapGetters(['userInfo', 'tag', 'lockPasswd']),

--
Gitblit v1.9.3