From 2197b7f12dea22ca664ed95f477e4cab5129e555 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B5=B5=E5=A4=AB=E7=90=B3?= <5356169+zhaofulin@user.noreply.gitee.com> Date: Mon, 1 Apr 2024 11:19:49 +0800 Subject: [PATCH 1/3] =?UTF-8?q?=E4=BC=98=E5=8C=96loading?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/router/index.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/router/index.js b/src/router/index.js index 3fafec3..1f07132 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -18,8 +18,7 @@ const router = new VueRouter({ // 0.8秒后,强制清除loading const hideToastLoading = debounceFun(() => { Vue.prototype.$forceCloseLoading() -}, 3 * 1000, false) -console.log('路由缓存...'); +}, 1000, false) let isFetchPermissionInfo = false const fetchPermissionInfo = async () => { let obj = {} From febee0226eb34dcd1e4addb5bb868bc955db466e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B5=B5=E5=A4=AB=E7=90=B3?= <5356169+zhaofulin@user.noreply.gitee.com> Date: Mon, 1 Apr 2024 11:23:34 +0800 Subject: [PATCH 2/3] =?UTF-8?q?=E4=BC=98=E5=8C=96loading?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/BottomBtn/index.vue | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/components/BottomBtn/index.vue b/src/components/BottomBtn/index.vue index 9b646b8..390b634 100644 --- a/src/components/BottomBtn/index.vue +++ b/src/components/BottomBtn/index.vue @@ -85,20 +85,25 @@ export default { this.$loading(true, 'loadingSb') if (this.key == 2) { approveTask(obj).then(() => { + this.$forceCloseLoading() this.$EventBus.$emit('handleResetLive', 'company-myTrips') this.$EventBus.$emit('handleResetLive', 'company-myClaim') history.back() this.$loading(false, 'loadingSb') }).catch(() => { this.$loading(false, 'loadingSb') + this.$forceCloseLoading() }) } else { rejectTask(obj).then(() => { + this.$forceCloseLoading() this.$EventBus.$emit('handleResetLive', 'company-myTrips') this.$EventBus.$emit('handleResetLive', 'company-myClaim') history.back() this.$loading(false, 'loadingSb') + this.$forceCloseLoading() }).catch(() => { + this.$forceCloseLoading() this.$loading(false, 'loadingSb') }) } From 230d53030d6d5c1b67208964fc988f96df6ece70 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B5=B5=E5=A4=AB=E7=90=B3?= <5356169+zhaofulin@user.noreply.gitee.com> Date: Mon, 1 Apr 2024 11:24:02 +0800 Subject: [PATCH 3/3] =?UTF-8?q?=E4=BC=98=E5=8C=96loading?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/BottomBtn/index.vue | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/components/BottomBtn/index.vue b/src/components/BottomBtn/index.vue index 390b634..b090523 100644 --- a/src/components/BottomBtn/index.vue +++ b/src/components/BottomBtn/index.vue @@ -91,8 +91,8 @@ export default { history.back() this.$loading(false, 'loadingSb') }).catch(() => { - this.$loading(false, 'loadingSb') this.$forceCloseLoading() + this.$loading(false, 'loadingSb') }) } else { rejectTask(obj).then(() => { @@ -101,7 +101,6 @@ export default { this.$EventBus.$emit('handleResetLive', 'company-myClaim') history.back() this.$loading(false, 'loadingSb') - this.$forceCloseLoading() }).catch(() => { this.$forceCloseLoading() this.$loading(false, 'loadingSb')