Explorar o código

新建团 不置顶BUG

1
mo %!s(int64=4) %!d(string=hai) anos
pai
achega
ad2b910af4

+ 3 - 1
src/views/teamBuild/components/soundSetComponents/soundSetCore.vue

@@ -137,8 +137,8 @@ export default {
   mounted() {
   mounted() {
     if (this.$route.query.id) {
     if (this.$route.query.id) {
       this.teamid = this.$route.query.id;
       this.teamid = this.$route.query.id;
-      window.addEventListener("scroll", this.getScroll);
     }
     }
+      window.addEventListener("scroll", this.getScroll);
     this.init();
     this.init();
   },
   },
   deactivated() {
   deactivated() {
@@ -149,6 +149,7 @@ export default {
       `${this.teamid}sound`,
       `${this.teamid}sound`,
       JSON.stringify(this.activeSoundList)
       JSON.stringify(this.activeSoundList)
     );
     );
+     window.removeEventListener("scroll", this.getScroll);
   },
   },
   activated() {
   activated() {
     if (
     if (
@@ -621,6 +622,7 @@ export default {
       return obj;
       return obj;
     },
     },
     getScroll() {
     getScroll() {
+
       this.scrollTop =
       this.scrollTop =
         window.pageYOffset ||
         window.pageYOffset ||
         document.documentElement.scrollTop ||
         document.documentElement.scrollTop ||