From de55f72941e23ae96696d6e9411758022c2cea1c Mon Sep 17 00:00:00 2001 From: nineven Date: Tue, 17 Mar 2020 08:38:51 +0800 Subject: [PATCH] fix refresh app bug --- fir_client/src/components/FirApps.vue | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/fir_client/src/components/FirApps.vue b/fir_client/src/components/FirApps.vue index 8b986ab..de50f25 100644 --- a/fir_client/src/components/FirApps.vue +++ b/fir_client/src/components/FirApps.vue @@ -242,11 +242,12 @@ hdata: {}, willDeleteApp: false, delapp: {}, - has_next:true, + has_next:false, query:{'page':1,size:20}, searchflag:false, uploadflag:false, - autoloadflag:true + autoloadflag:true, + firstloadflag:true, } }, methods: { searchFun(){ @@ -319,6 +320,10 @@ getapps(data => { if (data.code === 1000) { + if(this.firstloadflag){ + window.addEventListener('scroll',this.auto_load); + this.firstloadflag = false + } this.autoloadflag = true; if(this.uploadflag){ @@ -458,11 +463,10 @@ } }, mounted() { - // this.$store.dispatch('dosetAh',this.getBH); - window.addEventListener('scroll',this.auto_load); this.$store.dispatch('doucurrentapp', {}); - this.getappsFun({}); + // window.addEventListener('scroll',this.auto_load); + }, destroyed(){