diff --git a/pages/shop/afterService.vue b/pages/shop/afterService.vue index 942462f..624e478 100644 --- a/pages/shop/afterService.vue +++ b/pages/shop/afterService.vue @@ -394,7 +394,10 @@ callPlatformService() { let regionId = this.getCurrentRegionId(); if (!regionId) { - this.tui.toast("请选择校区"); + uni.showToast({ + title: "请选择校区", + icon: 'none' + }) return; } let that = this; diff --git a/pages/worker/index.vue b/pages/worker/index.vue index 7162aeb..13704db 100644 --- a/pages/worker/index.vue +++ b/pages/worker/index.vue @@ -39,18 +39,13 @@ alt="" style="width: 80rpx;height: 14rpx;position: absolute;bottom: 4rpx;left: 32rpx;" /> - + + + @@ -940,7 +935,10 @@ let worker = uni.getStorageSync('worker') if (worker == '' || worker == undefined || worker == null) { - this.tui.toast('您还没有注册兼职') + uni.showToast({ + title: '您还没有注册兼职', + icon: 'none' + }); return } this.isOnLine = uni.getStorageSync('worker').isOnLine @@ -994,6 +992,11 @@ } }).exec(); }, + goMyCenter(){ + uni.navigateTo({ + url: '/pages/worker/partTimeJobCenter' + }) + }, getHomeAdImageCache() { const cache = uni.getStorageSync(HOME_AD_IMAGE_CACHE_KEY) return cache && typeof cache === 'object' ? cache : {} @@ -1079,7 +1082,10 @@ that.$forceUpdate() } } else { - that.tui.toast(res.message) + uni.showToast({ + title: res.message, + icon: 'none' + }); return } uni.hideLoading() @@ -1229,7 +1235,7 @@ const redirectUrl = '/pages/index/index' + (!isNaN(index) && index > 0 ? '?tabIndex=' + index : '') uni.setStorageSync(redirectKey, redirectUrl) uni.navigateTo({ - url: '/package2/login/login?redirect=' + redirectKey + url: '/pages/login/login?redirect=' + redirectKey }) return false }, @@ -1257,7 +1263,10 @@ const diff = now - this.lastRefreshTime; if (diff < refreshInterval) { const waitSeconds = Math.ceil((refreshInterval - diff) / 1000); - this.tui.toast(waitSeconds + '秒后再刷新'); + uni.showToast({ + title: waitSeconds + '秒后再刷新', + icon: 'none' + }); return; } this.lastRefreshTime = now; @@ -1312,6 +1321,13 @@ this.getDelivery() this.$forceUpdate() }, + resetDeliveryQuery() { + this.deliveryQueryVersion++ + this.searchForm.pageNum = 1 + this.totalPages = 1 + this.deliveryItem = [] + this.resetSwipeOrder() + }, getOrder(item, index) { if (!this.requireLogin(0)) { this.resetSwipeOrder() @@ -1338,10 +1354,16 @@ that.$refs.tabBar.indexWorkerCount ++ }else{ if(res.message == '接单成功'){ - that.tui.toast(res.message); + uni.showToast({ + title: res.message, + icon: 'none' + }); that.$refs.tabBar.indexWorkerCount ++ }else{ - that.tui.toast(res.message,2000); + uni.showToast({ + title: res.message, + icon: 'none' + }); } } that.deliveryItem.splice(index, 1) @@ -1364,7 +1386,10 @@ that.$forceUpdate(); } else { that.resetSwipeOrder(); - that.tui.toast(res.message); + uni.showToast({ + title: res.message, + icon: 'none' + }); return; } }) @@ -1450,7 +1475,7 @@ const redirectKey = 'login_redirect_' + Date.now() uni.setStorageSync(redirectKey, target) uni.navigateTo({ - url: '/package2/login/login?redirect=' + redirectKey, + url: '/pages/login/login?redirect=' + redirectKey, complete: () => { setTimeout(() => { this.loginRedirecting = false @@ -1464,13 +1489,13 @@ }, goDeliveryRanking() { uni.navigateTo({ - url: '/package2/shop/ranking' + url: '/pages/worker/ranking' }) }, goPartTimeRegister() { if (uni.getStorageSync('worker')) { uni.navigateTo({ - url: '/package2/myCenter/partTimeJobRegister' + url: '/pages/worker/partTimeJobRegister' }) return } @@ -1482,7 +1507,7 @@ if (worker) { this.$refs.jianzhiPopup.close() uni.navigateTo({ - url: '/package2/myCenter/partTimeJobRegister' + url: '/pages/worker/partTimeJobRegister' }) return } @@ -1498,10 +1523,13 @@ } this.$refs.jianzhiPopup.close() uni.navigateTo({ - url: '/package2/myCenter/partTimeJobRegister' + url: '/pages/worker/partTimeJobRegister' }) } else { - this.tui.toast(res.message) + uni.showToast({ + title: res.message, + icon: 'none' + }); } uni.hideLoading() }) @@ -1525,7 +1553,10 @@ that.$refs.carPopup.open() } } else { - this.tui.toast(res.message) + uni.showToast({ + title: res.message, + icon: 'none' + }); } uni.hideLoading() }) @@ -1636,7 +1667,10 @@ that.totalPages = res.result.pages; // pages = 总页数 that.$forceUpdate(); } else { - this.tui.toast(res.message) + uni.showToast({ + title: res.message, + icon: 'none' + }); } if (that.refreshLoading) { that.finishRefreshLoading() @@ -1810,7 +1844,15 @@ }) }, checkArea() { - this.isArea = !this.isArea + this.NB.sendRequest("/app/shopArea/getByParentId/0", {}, true, 'POST', 'application/x-www-form-urlencoded').then(res => { + if (res.code == 200) { + this.areaList = res.result + this.areaKeyword = '' + this.$refs.areaPopup.open(); + } else { + this.tui.toast(res.message) + } + }) }, openPickupCodePopup(index, item, regionId) { if (this.pickupCodePopupVisible || this.pickupCodePopupOpening) return @@ -1851,7 +1893,10 @@ }, true, 'POST', 'application/x-www-form-urlencoded').then(res => { if (res.code == 200) { that.deliveryItem.splice(index, 1) - that.tui.toast(res.message); + uni.showToast({ + title: res.message, + icon: 'none' + }); if (item.workerId != null && item.workerId != undefined && item.workerId != '') { that.zhipaiCount -= 1 } else { @@ -1865,7 +1910,10 @@ } that.$forceUpdate(); } else { - that.tui.toast(res.message); + uni.showToast({ + title: res.message, + icon: 'none' + }); return; } uni.hideLoading() @@ -1921,7 +1969,10 @@ if (res.code == 200) { this.pageData.splice(context.index, 1) this.decreaseDeliveryStatusCount(2) - this.tui.toast(res.message, 200) + uni.showToast({ + title: res.message, + icon: 'none' + }); this.$refs.pickupCodePopup.close() this.pickupCode = '' this.pickupCodeContext = null @@ -1946,7 +1997,10 @@ if (!this.ensureLogin()) return if (status == 3) { if (this.completingDeliveryIds[item.id]) { - this.tui.toast('送达处理中,请勿重复提交 ') + uni.showToast({ + title: '送达处理中,请勿重复提交', + icon: 'none' + }); return } this.$set(this.completingDeliveryIds, item.id, true) @@ -1983,12 +2037,16 @@ } else { that.pageData[index].arriveTime = "qq" } - that.tui.toast(res.message, 200); - /* that.searchForm.pageNum = 1 - that.getDelivery() */ + uni.showToast({ + title: res.message, + icon: 'none' + }); that.$forceUpdate(); } else { - that.tui.toast(res.message, 200); + uni.showToast({ + title: res.message, + icon: 'none' + }); return; } uni.hideLoading(); @@ -2008,7 +2066,10 @@ that.putshopArea = res.result } } else { - that.tui.toast(res.message) + uni.showToast({ + title: res.message, + icon: 'none' + }); return } }).catch((res) => {}); @@ -2089,7 +2150,10 @@ if (!this.ensureLogin()) return const worker = uni.getStorageSync('worker') if (!worker || !worker.workerId) { - this.tui.toast('您还没有注册兼职') + uni.showToast({ + title: '您还没有注册兼职', + icon: 'none' + }); return } let url = '' @@ -2116,9 +2180,15 @@ worker.isOnLine = value; this.isOnLine = value uni.setStorageSync('worker', worker); - this.tui.toast(value == 0 ? '下线后不再接收新订单通知' : res.message) + uni.showToast({ + title: value == 0 ? '下线后不再接收新订单通知' : res.message, + icon: 'none' + }); } else { - this.tui.toast(res.message) + uni.showToast({ + title: res.message, + icon: 'none' + }); } uni.hideLoading() }) @@ -2161,7 +2231,7 @@ } .delivery-title-tabs { - width: 600rpx; + width: 100%; display: flex; align-items: center; }