diff --git a/pages/index/index.vue b/pages/index/index.vue index 8370e2f..0ed4071 100644 --- a/pages/index/index.vue +++ b/pages/index/index.vue @@ -508,6 +508,8 @@ lastScrollTop: 0, worker:null, isSwitching: true, + indexZhipaiCount:0, + indexWorkerCount:0, getAreaData:{}, putAreaData:{}, yongjin:false, @@ -615,6 +617,7 @@ } this.getDelivery(); this.getShopArea(); + this.getWorkerCounts(); } // 计算导航栏高度用于sticky offset:statusBarHeight + 40px内容区 const info = uni.getSystemInfoSync(); @@ -707,6 +710,30 @@ uni.hideLoading(); }).catch((res) => {}); }, + getWorkerCounts(){ + if(!uni.getStorageSync('worker')){ + return; + } + let that = this + this.tui.request("/mall/delivery/countOrderByStatus", "POST", {workerId:uni.getStorageSync('worker').workerId}, false, true).then((res) => { + if (res.code == 200) { + if(res.result != null){ + for(let i = 0;i {}); + }, checkTab(index) { for (let i = 0; i < this.menuList.length; i++) { this.menuList[i].checked = (i === index);