Commit f9881f94 authored by 潘永坪's avatar 潘永坪

电话回复处理

parent a2afcd08
...@@ -121,38 +121,45 @@ export default{ ...@@ -121,38 +121,45 @@ export default{
if(list.length>0){ if(list.length>0){
this.firstData=list[0] this.firstData=list[0]
list.forEach(item=>{ list.forEach(item=>{
if(item.commentText){ //游客发起数据
//游客发起 let imgList1=[]
let imgList=[] let imgList2=[]
item.commentImgList.forEach(item2=>{ item.commentImgList.forEach(item2=>{
if(item2.imgCommentType==0){ if(item2.imgCommentType==0){
//游客发送的图片 //游客发送的图片
imgList.push(item2) imgList1.push(item2)
} }
}) if(item2.imgCommentType==1){
this.detailList.push({ //商家发送的图片
title:'您发起投诉', imgList2.push(item2)
text:item.commentText, }
time:item.createTime, })
imgList this.detailList.push({
}) title:'您发起投诉',
} text:item.commentText,
if(item.commentReply){ time:item.createTime,
//商家回复 imgList:imgList1
let imgList=[] })
item.commentImgList.forEach(item2=>{ //商家回复数据
if(item2.imgCommentType==1){ if(item.handleType===0){
//商家发送的图片 //商家电话回复
imgList.push(item2) this.detailList.push({
} title:'商家回复',
}) text:item.commentReply||'客服已进行电话回复',
this.detailList.push({ time:item.updateTime,
title:'商家回复', imgList:imgList2
text:item.commentReply, })
time:item.updateTime, }
imgList if(item.handleType===1||item.handleType===2){
}) //商家文字回复,或者电话+文字回复
} this.detailList.push({
title:'商家回复',
text:item.commentReply||'',
time:item.updateTime,
imgList:imgList2
})
}
}) })
this.detailList.reverse() this.detailList.reverse()
} }
......
...@@ -64,44 +64,50 @@ export default{ ...@@ -64,44 +64,50 @@ export default{
this.$request('comment/userComment/loadInfo',data).then((res)=>{ this.$request('comment/userComment/loadInfo',data).then((res)=>{
if(res.code=='00'){ if(res.code=='00'){
let list=res.data||[] let list=res.data||[]
if(list.length>0){ if(list.length>0){
this.firstData=list[0] this.firstData=list[0]
list.forEach(item=>{ list.forEach(item=>{
if(item.commentText){ //游客发起数据
//游客发起 let imgList1=[]
let imgList=[] let imgList2=[]
item.commentImgList.forEach(item2=>{ item.commentImgList.forEach(item2=>{
if(item2.imgCommentType==0){ if(item2.imgCommentType==0){
//游客发送的图片 //游客发送的图片
imgList.push(item2) imgList1.push(item2)
} }
if(item2.imgCommentType==1){
//商家发送的图片
imgList2.push(item2)
}
})
this.detailList.push({
title:'您发起投诉',
text:item.commentText,
time:item.createTime,
imgList:imgList1
})
//商家回复数据
if(item.handleType===0){
this.detailList.push({
title:'商家回复',
text:item.commentReply||'客服已进行电话回复',
time:item.updateTime,
imgList:imgList2
}) })
this.detailList.push({ }
title:'您发起建议', if(item.handleType===1||item.handleType===2){
text:item.commentText, //商家文字回复,或者电话+文字回复
time:item.createTime, this.detailList.push({
imgList title:'商家回复',
}) text:item.commentReply||'',
} time:item.updateTime,
if(item.commentReply){ imgList:imgList2
//商家回复 })
let imgList=[] }
item.commentImgList.forEach(item2=>{
if(item2.imgCommentType==1){ })
//商家发送的图片 this.detailList.reverse()
imgList.push(item2) }
}
})
this.detailList.push({
title:'商家回复',
text:item.commentReply,
time:item.updateTime,
imgList
})
}
})
this.detailList.reverse()
}
}else{ }else{
uni.showToast({ uni.showToast({
title: res.message, title: res.message,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment