|
|
@@ -1,97 +1,136 @@ |
|
|
|
<template> |
|
|
|
<view class="cented-box"> |
|
|
|
|
|
|
|
<view class="customer"> |
|
|
|
<view class="customer" v-for="(item,index) in waitCustomList" :key='index'> |
|
|
|
<view class="title"> |
|
|
|
<view class="zuo"> |
|
|
|
<view class="zuoimg">A</view> |
|
|
|
<view class="zuoname">李先生</view> |
|
|
|
<view class="zuoname">{{item.name}}</view> |
|
|
|
</view> |
|
|
|
<view class="you"> |
|
|
|
<view class="youimg1"></view> |
|
|
|
<view class="youtext">接待中</view> |
|
|
|
<view class="youimg1" v-if="item.status!=0"></view> |
|
|
|
<view class="youimg1-1" v-if="item.status==0"></view> |
|
|
|
<view class="youtext">{{item.status==0?"排队中":item.status==1?"接待中":"已完成"}}</view> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
<view class="centerbox"> |
|
|
|
<view class="centerbox-che">手机号码:<text class="shizai">17551333886</text></view> |
|
|
|
<view class="centerbox-che">开始时间:<text class="shizai">2021-07-20 14:00:30</text></view> |
|
|
|
<view class="centerbox-che">顾问姓名:<text class="shizai">毛丫丫</text></view> |
|
|
|
<view class="centerbox-che2"> |
|
|
|
<view class="Workcard">工牌电量:<text class="shizai">56%</text></view> |
|
|
|
<view class="Workcard">录音状态:<text class="shizai">使用中</text></view> |
|
|
|
<view class="centerbox" v-if="item.status!=0"> |
|
|
|
<view class="centerbox-che">手机号码:<text class="shizai">{{item.phone || "--"}}</text></view> |
|
|
|
<view class="centerbox-che">开始时间:<text class="shizai">{{item.createTime}}</text></view> |
|
|
|
<view class="centerbox-che">顾问姓名:<text class="shizai">{{item.agentName}}</text></view> |
|
|
|
<view class="centerbox-che2" v-if="item.zkEquipmentState.audioStatus!=''"> |
|
|
|
<view class="Workcard">工牌电量:<text class="shizai">{{item.zkEquipmentState.electricity}}%</text></view> |
|
|
|
<view class="Workcard">录音状态: |
|
|
|
<text v-if="item.zkEquipmentState.audioStatus=='true'" class="shizai">使用中</text> |
|
|
|
<text v-if="item.zkEquipmentState.audioStatus=='false'" class="shizai">未使用</text> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
<view class="footer-button"> |
|
|
|
<view class="footer-button" v-if="item.status!=0"> |
|
|
|
<view class="footer1">接待延时</view> |
|
|
|
<view class="footer1" @click="goConsultant">重新指派</view> |
|
|
|
<view class="footer3">结束接待</view> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
|
|
|
|
<view class="customer"> |
|
|
|
<view class="title"> |
|
|
|
<view class="zuo"> |
|
|
|
<view class="zuoimg">A</view> |
|
|
|
<view class="zuoname">李先生</view> |
|
|
|
</view> |
|
|
|
<view class="you"> |
|
|
|
<view class="youimg1"></view> |
|
|
|
<view class="youtext">排队中</view> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
<view class="centerbox"> |
|
|
|
<view class="centerbox-che">手机号码:<text class="shizai">--</text></view> |
|
|
|
|
|
|
|
<view class="centerbox" v-if="item.status==0"> |
|
|
|
<view class="centerbox-che">手机号码:<text class="shizai">{{item.phone || "--"}}</text></view> |
|
|
|
</view> |
|
|
|
<view class="footer-button"> |
|
|
|
<view class="footer-button" v-if="item.status==0"> |
|
|
|
<view class="footer3">指派顾问</view> |
|
|
|
</view> |
|
|
|
|
|
|
|
</view> |
|
|
|
|
|
|
|
<view class="customer"> |
|
|
|
<view class="title"> |
|
|
|
<view class="zuo"> |
|
|
|
<view class="zuoimg">A</view> |
|
|
|
<view class="zuoname">李先生</view> |
|
|
|
</view> |
|
|
|
<view class="you"> |
|
|
|
<view class="youimg1"></view> |
|
|
|
<view class="youtext">接待中</view> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
<view class="centerbox"> |
|
|
|
<view class="centerbox-che">手机号码:<text class="shizai">17551333886</text></view> |
|
|
|
<view class="centerbox-che">开始时间:<text class="shizai">2021-07-20 14:00:30</text></view> |
|
|
|
<view class="centerbox-che">顾问姓名:<text class="shizai">毛丫丫</text></view> |
|
|
|
<view class="centerbox-che2"> |
|
|
|
<view class="Workcard">工牌电量:<text class="shizai">56%</text></view> |
|
|
|
<view class="Workcard">录音状态:<text class="shizai">使用中</text></view> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
<view class="footer-button"> |
|
|
|
<view class="footer1">接待延时</view> |
|
|
|
<view class="footer1">重新指派</view> |
|
|
|
<view class="footer3">结束接待</view> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
|
|
|
|
<image @click="addreception()" class="add" src="/static/images/add.png" mode=""></image> |
|
|
|
<image v-if="isAdd == 0&&(dataCode!=6||(dataCode==6&&addAccount==0))" @click="addreception()" class="add" src="/static/images/add.png" mode=""></image> |
|
|
|
</view> |
|
|
|
</template> |
|
|
|
|
|
|
|
<script> |
|
|
|
export default { |
|
|
|
data() { |
|
|
|
return {}; |
|
|
|
return { |
|
|
|
buildingID:'', |
|
|
|
waitCustomList:[], |
|
|
|
isAdd:'', |
|
|
|
dataCode:'' |
|
|
|
}; |
|
|
|
}, |
|
|
|
components: {}, |
|
|
|
onLoad() {}, |
|
|
|
onShow() {}, |
|
|
|
onShow() { |
|
|
|
this.buildingID = uni.getStorageSync('buildingID').id; |
|
|
|
const { |
|
|
|
addAccount, |
|
|
|
dataCode |
|
|
|
} = uni.getStorageSync("weapp_session_userInfo_data"); |
|
|
|
this.addAccount=addAccount |
|
|
|
this.dataCode=dataCode |
|
|
|
this.init() |
|
|
|
this.queryHaveDept() |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
queryHaveDept() { |
|
|
|
return new Promise((resolve, reject) => { |
|
|
|
this.$u.get("/user/queryHaveDept?houseId="+this.buildingID).then(res => { |
|
|
|
this.isAdd=res; |
|
|
|
resolve(); |
|
|
|
}) |
|
|
|
}) |
|
|
|
}, |
|
|
|
init(){ |
|
|
|
this.waitCustomList=[] |
|
|
|
let parames={ |
|
|
|
itemId:this.buildingID |
|
|
|
} |
|
|
|
this.$u.post("/customer/reception", parames).then(data => { |
|
|
|
console.log(data) |
|
|
|
this.waitCustomList=data; |
|
|
|
}); |
|
|
|
}, |
|
|
|
//新增接待 |
|
|
|
addreception(){ |
|
|
|
uni.navigateTo({ |
|
|
|
url: '/pages/mine/reception/addreception' |
|
|
|
}); |
|
|
|
const { |
|
|
|
dataCode,addAccount |
|
|
|
} = uni.getStorageSync("weapp_session_userInfo_data"); |
|
|
|
|
|
|
|
if(dataCode==6){ |
|
|
|
if(addAccount!=0){ |
|
|
|
uni.showToast({ |
|
|
|
title: '不允许自建客户!', |
|
|
|
duration: 2000 |
|
|
|
}); |
|
|
|
return |
|
|
|
} |
|
|
|
console.log(this.waitCustomList.length) |
|
|
|
if(this.waitCustomList.length==0){ |
|
|
|
uni.navigateTo({ |
|
|
|
url: "/pages/customer/add/add" |
|
|
|
}) |
|
|
|
return |
|
|
|
}else{ |
|
|
|
for(var i=0; i<this.waitCustomList.length; i++){ |
|
|
|
if(this.waitCustomList[i].status==1){ |
|
|
|
uni.showLoading({ |
|
|
|
title: '当前还有未完成的客户项' |
|
|
|
}); |
|
|
|
setTimeout(function () { |
|
|
|
uni.hideLoading(); |
|
|
|
}, 1000); |
|
|
|
return |
|
|
|
}else{ |
|
|
|
uni.navigateTo({ |
|
|
|
url: "/pages/customer/add/add" |
|
|
|
}) |
|
|
|
return |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
}else{ |
|
|
|
uni.navigateTo({ |
|
|
|
url: "/pages/customer/add/add" |
|
|
|
}) |
|
|
|
} |
|
|
|
// uni.navigateTo({ |
|
|
|
// url: '/pages/mine/reception/addreception' |
|
|
|
// }); |
|
|
|
}, |
|
|
|
goConsultant(){ |
|
|
|
uni.navigateTo({ |
|
|
@@ -107,7 +146,7 @@ |
|
|
|
.cented-box{ |
|
|
|
background: #F8F8F8; |
|
|
|
width: 100%; |
|
|
|
height: 100%; |
|
|
|
height: 100vh; |
|
|
|
padding-bottom: 30rpx; |
|
|
|
} |
|
|
|
.customer{ |
|
|
@@ -156,6 +195,12 @@ |
|
|
|
border-radius: 50%; |
|
|
|
background: #2B6EFF; |
|
|
|
} |
|
|
|
.youimg1-1{ |
|
|
|
width: 12rpx; |
|
|
|
height: 12rpx; |
|
|
|
border-radius: 50%; |
|
|
|
background: #F2A269; |
|
|
|
} |
|
|
|
.youtext{ |
|
|
|
font-size: 30rpx; |
|
|
|
font-weight: 400; |
|
|
|