diff --git a/src/components/BottomBtn/index.vue b/src/components/BottomBtn/index.vue index be03d89..ce54ac5 100644 --- a/src/components/BottomBtn/index.vue +++ b/src/components/BottomBtn/index.vue @@ -115,25 +115,51 @@ export default { } this.$loading(true, 'loadingSb') if (this.key == 2) { + /* approveTask(obj) + .then(() => { + this.$EventBus.$emit('handleResetLive', 'company-myTrips') + this.$EventBus.$emit('handleResetLive', 'company-myClaim') + history.back() + this.$loading(false, 'loadingSb') + }) + .catch(() => { + this.$loading(false, 'loadingSb') + }) + } else { + rejectTask(obj) + .then(() => { + this.$EventBus.$emit('handleResetLive', 'company-myTrips') + this.$EventBus.$emit('handleResetLive', 'company-myClaim') + history.back() + this.$loading(false, 'loadingSb') + }) + .catch(() => { + this.$loading(false, 'loadingSb') + }) */ + 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.$forceCloseLoading() this.$loading(false, 'loadingSb') }) } else { rejectTask(obj) .then(() => { + this.$forceCloseLoading() this.$EventBus.$emit('handleResetLive', 'company-myTrips') this.$EventBus.$emit('handleResetLive', 'company-myClaim') history.back() this.$loading(false, 'loadingSb') }) .catch(() => { + this.$forceCloseLoading() this.$loading(false, 'loadingSb') }) } 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 = {}