xuqiaoying 3 лет назад
Родитель
Сommit
a73309368f
2 измененных файлов с 12 добавлено и 6 удалено
  1. 6 3
      src/pages/course-detail/index.vue
  2. 6 3
      src/pages/live-detail/index.vue

+ 6 - 3
src/pages/course-detail/index.vue

@@ -3137,6 +3137,9 @@ export default {
     // });
   },
   beforeDestroy() {
+    clearInterval(this.answerTimer);
+    clearInterval(this.postTimer);
+    clearInterval(this.livingTimer);
     try {
       this.$msgbox.close();
     } catch (err) {}
@@ -3152,9 +3155,9 @@ export default {
     //     .then((res) => {});
     // }
     this.clears();
-    clearInterval(this.answerTimer);
-    clearInterval(this.postTimer);
-    clearInterval(this.livingTimer);
+    // clearInterval(this.answerTimer);
+    // clearInterval(this.postTimer);
+    // clearInterval(this.livingTimer);
   },
   methods: {
     ...mapMutations(["getCartCount"]),

+ 6 - 3
src/pages/live-detail/index.vue

@@ -2883,6 +2883,9 @@ export default {
     // });
   },
   beforeDestroy() {
+    clearInterval(this.answerTimer);
+    clearInterval(this.postTimer);
+    clearInterval(this.livingTimer);
     try {
       this.$msgbox.close();
     } catch (err) {}
@@ -2898,9 +2901,9 @@ export default {
     //     .then((res) => {});
     // }
     this.clears();
-    clearInterval(this.answerTimer);
-    clearInterval(this.postTimer);
-    clearInterval(this.livingTimer);
+    // clearInterval(this.answerTimer);
+    // clearInterval(this.postTimer);
+    // clearInterval(this.livingTimer);
   },
   methods: {
     ...mapMutations(["getCartCount"]),