From 1dcf7878631b4edf5ccf5f44d635d87708e7aa4a Mon Sep 17 00:00:00 2001 From: 396316021 <396316021@qq.com> Date: Mon, 20 Nov 2023 14:47:09 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- components/RightNav/index.vue | 8 +- pages/FeedLog/index.vue | 88 ++----------------- pages/Index/components/UserPage/index.vue | 8 +- pages/Index/index.vue | 3 +- pages/OrderConfirm/end.vue | 17 +++- pages/OrderConfirm/start.vue | 13 +-- pages/OrderDetail/components/fomItem.vue | 4 +- pages/OrderPage/index.vue | 19 ++-- pages/UserOrderPage/index.vue | 3 +- .../components/uv-calendar/month.vue | 4 +- 10 files changed, 55 insertions(+), 112 deletions(-) diff --git a/components/RightNav/index.vue b/components/RightNav/index.vue index fd7cbea..cac8095 100644 --- a/components/RightNav/index.vue +++ b/components/RightNav/index.vue @@ -56,6 +56,10 @@ let that = this; if(uni.getStorageSync('token')){ that.getMsgNumber(); + setInterval(() => { + that.getMsgNumber(); + },5000) + that.getKFWechat(); } }, methods: { @@ -63,6 +67,8 @@ userChatCount().then(res => { this.msgCount = res.data.count }); + }, + getKFWechat(){ getConfig('kefu_weixin').then((res) => { this.imageUrl = res.data.kefu_weixin; }) @@ -75,7 +81,7 @@ handle(type){ switch (type) { case 'chat': - this.navTo("/pages/ChatDetail/index?id=0",true); + this.navTo("/pages/ChatDetail/index?id=0&type=2",true); break; case 'wechat': // uni.openCustomerServiceChat({ diff --git a/pages/FeedLog/index.vue b/pages/FeedLog/index.vue index 1355e5d..bb46ef8 100644 --- a/pages/FeedLog/index.vue +++ b/pages/FeedLog/index.vue @@ -63,16 +63,6 @@ - - - - - - - - - - @@ -98,16 +88,6 @@ - - - - - - - - - - @@ -133,16 +113,6 @@ - - - - - - - - - - @@ -168,16 +138,6 @@ - - - - - - - - - - @@ -203,16 +163,6 @@ - - - - - - - - - - @@ -238,16 +188,6 @@ - - - - - - - - - - @@ -273,16 +213,6 @@ - - - - - - - - - - @@ -308,16 +238,6 @@ - - - - - - - - - - @@ -399,7 +319,9 @@ MzButton }, onShow(){ - this.feedLog(); + if(this.type === 'detail'){ + this.getFeedLog(this.pet_id); + } }, onReady() { uni.$u.sleep(100).then(() => { @@ -536,7 +458,7 @@ this.detail.feedlist = feedlist; } this.detail = data.data; - if(this.type !== 'detail'){ + // if(this.type !== 'detail'){ let images = [ 'meal_imgs', 'food_imgs', @@ -550,7 +472,7 @@ images.forEach((item,index) => { that.uploadShow(data.data.feedlist[item],item); }); - } + // } }) }, diff --git a/pages/Index/components/UserPage/index.vue b/pages/Index/components/UserPage/index.vue index 77080a9..cf7c1a8 100644 --- a/pages/Index/components/UserPage/index.vue +++ b/pages/Index/components/UserPage/index.vue @@ -94,14 +94,14 @@ - + 待服务 - + @@ -124,7 +124,7 @@ - + @@ -132,7 +132,7 @@ 待服务 - + diff --git a/pages/Index/index.vue b/pages/Index/index.vue index 2689ee5..1054eb6 100644 --- a/pages/Index/index.vue +++ b/pages/Index/index.vue @@ -83,7 +83,7 @@ } }, onLoad(option) { - this.footSelect(option?.foot_check ?? 0); + this.footSelect(option?.foot_check || 0); this.showUserInfo(); }, methods: { @@ -165,6 +165,7 @@ type = 1; } if(this.inter)clearInterval(this.inter); + this.getCountBadges(type); this.inter = setInterval(() => { this.getCountBadges(type); },5000) diff --git a/pages/OrderConfirm/end.vue b/pages/OrderConfirm/end.vue index a15e414..caddd99 100644 --- a/pages/OrderConfirm/end.vue +++ b/pages/OrderConfirm/end.vue @@ -1938,7 +1938,7 @@ - @@ -1978,6 +1978,9 @@ export default { }, data() { return { + shows:{ + leave:'', + }, value: 1, title: '结束服务', loading: true, @@ -2211,10 +2214,18 @@ export default { }) }, timeConfirm(e) { - this.model.leave = uni.$u.timeFormat(e.value, 'yyyy-mm-dd hh:MM'); + console.log(e) + this.model.leave = uni.$u.timeFormat(null,'yyyy-mm-dd') + ' ' +e.value; }, uploadSubmit(data, fileName = '') { this.model[fileName].upload = data.map(item => { + if(item.url.indexOf('wxfile') !== -1){ + item.url = ''; + } + if(item.status === 'uploading'){ + uni.showToast({title:'上传中,请稍后'}) + return ; + } return {url: item.url, type: item.type}; }) }, diff --git a/pages/OrderConfirm/start.vue b/pages/OrderConfirm/start.vue index f8b2bfc..5a7c952 100644 --- a/pages/OrderConfirm/start.vue +++ b/pages/OrderConfirm/start.vue @@ -64,7 +64,7 @@ - + - + - diff --git a/pages/OrderPage/index.vue b/pages/OrderPage/index.vue index c4e2194..c5d763a 100644 --- a/pages/OrderPage/index.vue +++ b/pages/OrderPage/index.vue @@ -243,7 +243,7 @@ - + @@ -266,12 +266,12 @@ - + - 协议内容 + 喂养协议 @@ -620,7 +620,7 @@ ){ if(!this.store_id){ uni.hideLoading(); - api.error('所选位置没有店铺'); + api.error('所选位置超出服务范围'); return; } this.isPay = true; @@ -742,6 +742,7 @@ console.log(this.timeList) // this.timeList = this.timeListTemp; this.$refs.doDatePopup.close() + this.getStoreServiceList(); this.checkOrderData(); }, doTimeSelect(item,index){ @@ -791,7 +792,15 @@ this.checkOrderData(); }, getStoreServiceList(){ - getStoreService({address_id: this.address.id,order_type:this.type}).then(res => { + if(this.timeList.length === 0){ + api.error('请选择服务日期'); + return ; + } + getStoreService({ + address_id: this.address.id, + do_date:this.timeList, + order_type:this.type + }).then(res => { this.store_id = res.data.store_id; this.addServiceList = res.data.add_service.map(item => { item.number = 0; diff --git a/pages/UserOrderPage/index.vue b/pages/UserOrderPage/index.vue index f2f0adb..180b05d 100644 --- a/pages/UserOrderPage/index.vue +++ b/pages/UserOrderPage/index.vue @@ -200,8 +200,7 @@ onLoad(options) { this.screenCheck = options.type || ""; this.is_buy = options.is_buy; - this.navToUrl = option.url || ""; - log(options) + this.navToUrl = options.url || ""; }, methods: { formatDate(date) { diff --git a/uni_modules/uv-calendar/components/uv-calendar/month.vue b/uni_modules/uv-calendar/components/uv-calendar/month.vue index 5521854..1fbc825 100644 --- a/uni_modules/uv-calendar/components/uv-calendar/month.vue +++ b/uni_modules/uv-calendar/components/uv-calendar/month.vue @@ -451,8 +451,8 @@ setDefaultDate() { if (!this.defaultDate) { // 如果没有设置默认日期,则将当天日期设置为默认选中的日期 - const selected = [dayjs().format("YYYY-MM-DD")] - return this.setSelected(selected, false) + // const selected = [dayjs().format("YYYY-MM-DD")] + // return this.setSelected(selected, false) } let defaultDate = [] const minDate = this.minDate || dayjs().format("YYYY-MM-DD")