diff --git a/pages/ChatDetail/index.vue b/pages/ChatDetail/index.vue index f977d71..e25ce95 100644 --- a/pages/ChatDetail/index.vue +++ b/pages/ChatDetail/index.vue @@ -96,7 +96,8 @@ export default { }, onLoad(options) { let user = uni.getStorageSync('user'); - if(user.is_waitstaff !== 1 ){ + console.log(user) + if(user.is_waitstaff !== 1 && user.is_waitstaff !== 3){ this.getToken(options.id, options.type ?? 1); }else if(options.is_seize == 1){ this.connectChat(options.id); diff --git a/pages/FeedLog/components/FeedLog.vue b/pages/FeedLog/components/FeedLog.vue new file mode 100644 index 0000000..8bba986 --- /dev/null +++ b/pages/FeedLog/components/FeedLog.vue @@ -0,0 +1,507 @@ + + + + + \ No newline at end of file diff --git a/pages/FeedLog/index.vue b/pages/FeedLog/index.vue index bb46ef8..9e4e44b 100644 --- a/pages/FeedLog/index.vue +++ b/pages/FeedLog/index.vue @@ -1,511 +1,27 @@ - - \ No newline at end of file + \ No newline at end of file diff --git a/pages/Index/components/ChatPage/index.vue b/pages/Index/components/ChatPage/index.vue index 99bac64..2055af8 100644 --- a/pages/Index/components/ChatPage/index.vue +++ b/pages/Index/components/ChatPage/index.vue @@ -94,7 +94,7 @@ } }, chatDetail(item){ - let url = (this.$store.state.userInfo.is_waitstaff === 1)?'/pages/ChatDetail/index?id='+item.chat_id:'/pages/ChatDetail/index?id='+item.order_service_id; + let url = (this.$store.state.userInfo.is_waitstaff === 1 || this.$store.state.userInfo.is_waitstaff === 3)?'/pages/ChatDetail/index?id='+item.chat_id:'/pages/ChatDetail/index?id='+item.order_service_id; uni.navigateTo({ url:url }); diff --git a/pages/Index/components/OrderPage/index.vue b/pages/Index/components/OrderPage/index.vue index d237377..9736bc7 100644 --- a/pages/Index/components/OrderPage/index.vue +++ b/pages/Index/components/OrderPage/index.vue @@ -76,13 +76,13 @@ button-color="#F7E1C3" button-width="100%"> - - - - - - - + + + { - // this.getCountBadges(type); - this.footGroup[2].badge = res.data.count_user; - this.footGroup[1].badge = res.data.count_worker; - this.kFbadge = res.data.count_kf; + this.getCountBadges(type); + // this.footGroup[2].badge = res.data.count_user; + // this.footGroup[1].badge = res.data.count_worker; + // this.kFbadge = res.data.count_kf; },5000) } }, diff --git a/pages/OrderConfirm/end.vue b/pages/OrderConfirm/end.vue index caddd99..308fa97 100644 --- a/pages/OrderConfirm/end.vue +++ b/pages/OrderConfirm/end.vue @@ -20,587 +20,202 @@ border-bottom > - - - - - - - - - - - - - - - 门窗、灯、空调、水电等情况 - - - - - - - - - - - - - {{item}} - - - - - - - - - - - - - - - - - - - - - - 入户前萌宠家居情况 - - - - - - - - - - - - - {{item}} - - - - - - - - - - - - - - - - - - - - - - 萌宠生活区情况 - - - - - - - - - - - - - - - - - - - 萌宠食物剩余情况 - - - - - - - - - - - - - - - - - {{item}} - - - - - - - - - - - - - - - - - - - - - - - - {{item}} - - - - - - - - - - - - - - - - - - - - - - - - 是否有萌宠呕吐物 - - - - - - - - - - - - - - - - - - - - - - - - - - 萌宠排泄物情况 - - - - - - - - - - - - - - - - - - - - - - - - - - - 其他情况反馈 - - - - - - - - - - - - - - - - + + + - + + - + - 食盆清洗并擦干水渍 - + + 门窗、灯、空调、水电等情况 + + - + - - + + + + + + + {{ item }} + + + + + + + + - + - 水盆清理 - + + 入户前萌宠家居情况 + + - + - - + + + + + + + {{ item }} + + + + + + + + - + - 萌宠主食 - + + 萌宠生活区情况 + + - + - - - - - @@ -610,62 +225,110 @@ > - + - 萌宠饮用水 - + + 萌宠食物剩余情况 + + - + - + - - - - + + + + + + + + {{ item }} + + + + + + + + + + + + - + - - - - - - + + + + + + + + {{ item }} + + + + + + + + + + + @@ -675,59 +338,56 @@ > - + - 零食、药品及其他 - + + 是否有萌宠呕吐物 + + - + - - - - - - + - - - - @@ -737,47 +397,58 @@ > - + - 窝窝整理 - + + 萌宠排泄物情况 + + - + - - + - - + + + @@ -787,90 +458,95 @@ > - + - 笼笼清理 - + + 其他情况反馈 + + - + - - - - - + + + + + + + + - + - 周边毛发 - + + 食盆清洗并擦干水渍 + + - + + + + - - - - - - + - 屋内排泄物清理 - + + 水盆清理 + + - + - - + + + + + + + + + + + + + + + + 萌宠主食 + + + + + + + + + - - - + - 屋内呕吐物清理 - + + 萌宠饮用水 + + - + - - + + + + - - + + + + + + + + + - + - 猫砂盆整理及猫砂更换 - + + 零食、药品及其他 + + - + - - + - - - + - - + + - + - 其他需求反馈 - + + 窝窝整理 + + - + + + + + + - - - - - - - - - - - + - 基础检查 - + + 笼笼清理 + + - + - - - - - - + - - - + + + + + + + + + + + + + + 周边毛发 + + + + + + + + + - - + + + + + + + + + + + + + 屋内排泄物清理 + + + + + + + + + + + + + + + + + + + + + + + + + + 屋内呕吐物清理 + + + + + + + + + + + + + + + + + + + + + + + + + + 猫砂盆整理及猫砂更换 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 其他需求反馈 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 基础检查 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 健康情况 + + + + + + + + + + + + + + {{ item }} + + + + + + + + + + + + + + + + + + + + + 其他 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 萌宠清洁 + + + + + + + + + + + + + + + + + + + + + + + + + + + + 萌宠美容 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 在家互动 + + + + + + + + + + + + + + + + + + + 外出遛弯 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 垃圾携带 + + + + + + + + @@ -1159,42 +1779,72 @@ > - + - 健康情况 - + + 门窗、灯、空调、水电等状态 + + - + + - + - + - - {{item}} + + {{ item }} - - - - - - + + + + + + + + - + - 其他 - + + 离开时萌宠安全确认 + + - + - - - - - - - - - - - - - - - - - - - - 萌宠清洁 - - - - - - - - - - - - - - - - - - - - - - - - - - 萌宠美容 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 在家互动 - - - - - - - - - - - - - - - - - 外出遛弯 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 垃圾携带 - - - - - - - - - - - - - - - - - - - 门窗、灯、空调、水电等状态 - - - - - - + > + + + + + + + - - - - - - - {{item}} + + + + 关闭房门安全离开 + + + + + - - - - - - - - - - - - - - - - - - - - 离开时萌宠安全确认 - - - - - - - - - - - - - - - - - - - 关闭房门安全离开 - - - - - - - - - - - - + + + + + - - - - {{item}} + > + + + + {{ item }} + - - - - - - - - - --> + + + + + + + - - - - - - + + + + + - - - - {{item}} + > + + + + {{ item }} + - - - - - - - - - --> + + + + + + + - - - - - - - - - - - 房门钥匙 - - - - - - + > + + + + + + + + + + + + 房门钥匙 + + + + + + + - - - + + - - - - {{item}} + > + + + + {{ item }} + - - - - - - - - - - - --> + + + + + + + + + - - - - - - - - - - - 离开时间 - - - + > + + + + + + + + + + + + 离开时间 + + + + + + + + + + + + + + - - - - - - - - - - @@ -1978,8 +2161,8 @@ export default { }, data() { return { - shows:{ - leave:'', + shows: { + leave: '', }, value: 1, title: '结束服务', @@ -2079,13 +2262,13 @@ export default { trigger: ['blur', 'change'] }, }, - collapseChecked:'0', + collapseChecked: '0', } }, onLoad(option) { this.model.order_service_id = option.id; this.model.leave = uni.$u.timeFormat(null, 'yyyy-mm-dd hh:MM'); - if(option.type === 'edit'){ + if (option.type === 'edit') { this.getServiceTable(option.id); } }, @@ -2095,78 +2278,78 @@ export default { }, }, methods: { - beforeStatusChange(e){ - if(this.model.before_status.option === e){ + beforeStatusChange(e) { + if (this.model.before_status.option === e) { this.model.before_status.option = ''; - }else{ + } else { this.model.before_status.option = e; } }, - foodChange(e){ - if(this.model.food_status.food_option === e){ - this.model.food_status.food_option = ''; - }else{ + foodChange(e) { + if (this.model.food_status.food_option === e) { + this.model.food_status.food_option = ''; + } else { this.model.food_status.food_option = e; } }, - waterChange(e){ - if(this.model.food_status.water_option === e){ + waterChange(e) { + if (this.model.food_status.water_option === e) { this.model.food_status.water_option = ''; - }else{ + } else { this.model.food_status.water_option = e; } }, - applianceChange(e){ - if(this.model.appliance.option === e){ + applianceChange(e) { + if (this.model.appliance.option === e) { this.model.appliance.option = ''; - }else{ + } else { this.model.appliance.option = e; } }, - healthChange(e){ - if(this.model.health.option === e){ + healthChange(e) { + if (this.model.health.option === e) { this.model.health = ''; - }else{ + } else { this.model.health = e; } }, - applianceInfoChange(e){ - if(this.model.appliance_info.option === e){ + applianceInfoChange(e) { + if (this.model.appliance_info.option === e) { this.model.appliance_info.option = ''; - }else{ + } else { this.model.appliance_info.option = e; } }, - closeChange(e){ - if(this.model.close.option === e){ + closeChange(e) { + if (this.model.close.option === e) { this.model.close.option = ''; - }else{ + } else { this.model.close.option = e; } }, - closeMimaChange(e){ - if(this.model.close_mima.option === e){ + closeMimaChange(e) { + if (this.model.close_mima.option === e) { this.model.close_mima.option = ''; - }else{ + } else { this.model.close_mima.option = e; } }, - keyChange(e){ - if(this.model.key.option === e){ + keyChange(e) { + if (this.model.key.option === e) { this.model.key.option = ''; - }else{ + } else { this.model.key.option = e; } }, - changeCollapse(name){ - if(this.collapseChecked === name){ + changeCollapse(name) { + if (this.collapseChecked === name) { this.collapseChecked = ''; - }else{ + } else { this.collapseChecked = name; } this.goTop(); }, - getServiceTable(id){ + getServiceTable(id) { let that = this; let images = [ 'appliance', @@ -2209,41 +2392,41 @@ export default { this.model = data.data.endservice; this.model.order_service_id = id; images.forEach((item) => { - that.uploadShow(data.data.endservice[item].upload,item); + that.uploadShow(data.data.endservice[item].upload, item); }); }) }, timeConfirm(e) { console.log(e) - this.model.leave = uni.$u.timeFormat(null,'yyyy-mm-dd') + ' ' +e.value; + 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){ + if (item.url.indexOf('wxfile') !== -1) { item.url = ''; } - if(item.status === 'uploading'){ - uni.showToast({title:'上传中,请稍后'}) - return ; + if (item.status === 'uploading') { + uni.showToast({title: '上传中,请稍后'}) + return; } - return {url: item.url, type: item.type}; + return {url: item.url, type: item.type, thumb:(item.thumb || item.url)}; }) }, uploadShow(data, fileName = '') { let result = []; try { data.forEach(item => { - result.push({url: item.url, type: item.type}) + result.push({url: item.url, type: item.type,thumb:(item.thumb || item.url)}) }) } catch (e) { this.images[fileName] = []; } this.images[fileName] = result; }, - uploadPut(event, fileName = '') { - console.log('event',event) + async uploadPut(event, fileName = '') { + console.log('event', event) let lists = [].concat(event.file); - console.log('lists',lists) + console.log('lists', lists) let fileListLen = this.images[fileName].length; lists.map((item) => { this.images[fileName].push({ @@ -2256,19 +2439,20 @@ export default { for (let i = 0; i < lists.length; i++) { const fileType = api.getFileType(lists[i].url); console.log(fileType) - api.uploadOssFile(lists[i].url).then(res => { - let item = this.images[fileName][fileListLen]; - - this.images[fileName].splice(fileListLen, 1, { - ...item, - status: 'success', - message: '', - url: res.show_path, - thumb: res.show_path, - type: fileType - }); - fileListLen++; - }) + let thumb; + const file = await api.uploadOssFile(lists[i].url); + if(fileType === 'video')thumb = await api.uploadOssFile(lists[i].thumb); + let item = this.images[fileName][fileListLen]; + + this.images[fileName].splice(fileListLen, 1, { + ...item, + status: 'success', + message: '', + url: file.show_path, + thumb: thumb.show_path || file.show_path, + type: fileType + }); + fileListLen++; } }, uploadDel(fileIndex, fileName = '') { @@ -2376,16 +2560,16 @@ export default { } }) }, - goTop(){ - uni.pageScrollTo({ - scrollTop: 0, - success:(res)=>{ - console.log('res',res) - }, - fail:(err) => { - console.log('err',err) - } - }); + goTop() { + uni.pageScrollTo({ + scrollTop: 0, + success: (res) => { + console.log('res', res) + }, + fail: (err) => { + console.log('err', err) + } + }); } }, onPageScroll(res) { @@ -2403,7 +2587,8 @@ export default { \ No newline at end of file diff --git a/pages/OrderDetail/components/fomItem.vue b/pages/OrderDetail/components/fomItem.vue index 2b0983c..7db03a7 100644 --- a/pages/OrderDetail/components/fomItem.vue +++ b/pages/OrderDetail/components/fomItem.vue @@ -25,12 +25,20 @@ export default { return { imageUrl: '', imageShow: false, + videoUrl: '', + videoShow: false, } }, methods: { showBigImage(imgUrl) { this.imageUrl = imgUrl; this.imageShow = true; + this.$emit('showBigImage',imgUrl) + }, + showBigVideo(videoUrl) { + this.videoUrl = videoUrl; + this.videoShow = true; + this.$emit('showBigVideo',videoUrl) }, getString(value) { let typeStr = typeof value; @@ -90,11 +98,12 @@ export default { - + - + + + @@ -106,11 +115,16 @@ export default { - - - - - + + + + + + + + + +