From b7eb749eb71ae802f9868e3b099aa362e23d7cc0 Mon Sep 17 00:00:00 2001
From: 李凌 <344137771@qq.com>
Date: Sat, 06 Sep 2025 18:33:05 +0800
Subject: [PATCH] 1

---
 src/views/customerService/index.vue |    9 +++++++--
 1 files changed, 7 insertions(+), 2 deletions(-)

diff --git a/src/views/customerService/index.vue b/src/views/customerService/index.vue
index 6d3b92d..60a2619 100644
--- a/src/views/customerService/index.vue
+++ b/src/views/customerService/index.vue
@@ -66,7 +66,7 @@
 import { Uploader, showImagePreview } from 'vant'
 import { _getMsg, _getUnreadMsg, _sendMsg } from '@/service/im.api'
 import { _uploadImage } from '@/service/upload.api'
-import { ref, onMounted, onUnmounted } from "vue";
+import { ref, onMounted, onUnmounted, onBeforeUnmount } from "vue";
 import { useI18n } from "vue-i18n";
 import { throttle } from '@/utils/index'
 import { closeToast, showToast, showLoadingToast } from "vant";
@@ -256,7 +256,12 @@
 onUnmounted(() => {
   clearIntervalTimer()
 })
-
+onBeforeUnmount(() => {
+  let lastTimerId = setInterval(() => {}, 1000);
+  for (let i = 1; i <= lastTimerId; i++) {
+    clearInterval(i);
+  }
+})
 
 </script>
 <style lang="scss" scoped>

--
Gitblit v1.9.3