拨打电话bug
This commit is contained in:
parent
b4c3c8002c
commit
8e6600ade6
@ -584,11 +584,11 @@ export default {
|
|||||||
this.visiblemediatRecord = true;
|
this.visiblemediatRecord = true;
|
||||||
this.visiblemediatRecordObj = obj;
|
this.visiblemediatRecordObj = obj;
|
||||||
},
|
},
|
||||||
startOutboundCall(phone, contactId) {
|
startOutboundCall(params, contactId) {
|
||||||
let params = {
|
// let params = {
|
||||||
phone: phone || null,
|
// phone: phone || null,
|
||||||
contactId: contactId || null
|
// contactId: contactId || null
|
||||||
}
|
// }
|
||||||
this.$emit('startOutboundCall', params)
|
this.$emit('startOutboundCall', params)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -669,28 +669,31 @@ export default {
|
|||||||
if (this.queue) {
|
if (this.queue) {
|
||||||
for (let i=0; i < this.queueList.length; i++) {
|
for (let i=0; i < this.queueList.length; i++) {
|
||||||
if (this.queueList[i].status.code === 1) {
|
if (this.queueList[i].status.code === 1) {
|
||||||
console.log('定位到可拨打的案件',i)
|
console.log('定位到可拨打的案件',i,this.queueList[i])
|
||||||
this.index = i
|
this.index = i
|
||||||
this.startOutboundCall()
|
this.startOutboundCall()
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
this.startOutboundCall()
|
|
||||||
|
let phone = this.baseInfo.debtorEntityList.find(item => (item.role == 'DEBTOR' && item.type == '本人')).phone
|
||||||
|
let contactId = this.baseInfo.debtorEntityList.find(item => (item.role == 'DEBTOR' && item.type == '本人')).id
|
||||||
|
this.startOutboundCall({phone:phone,contactId:contactId})
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
// 电话呼出
|
// 电话呼出
|
||||||
async startOutboundCall(phone, contactId) {
|
async startOutboundCall(params) {
|
||||||
// this.phoneNumber = this.queue ? this.queueList[this.index].phone : this.baseInfo.phone
|
// this.phoneNumber = this.queue ? this.queueList[this.index].phone : this.baseInfo.phone
|
||||||
if (this.calling) return
|
if (this.calling) return
|
||||||
this.phoneNumber = phone
|
this.phoneNumber = params.phone
|
||||||
if (contactId) this.contactId=contactId
|
this.contactId= params.contactId
|
||||||
|
|
||||||
console.log('进入呼叫电话:', this.phoneNumber)
|
// console.log('进入呼叫电话:', this.phoneNumber)
|
||||||
try {
|
try {
|
||||||
let res = await window.tccc.Call.startOutboundCall({phoneNumber: this.phoneNumber})
|
let res = await window.tccc.Call.startOutboundCall({phoneNumber: this.phoneNumber})
|
||||||
this.sessionId = res.data.sessionId
|
this.sessionId = res.data.sessionId
|
||||||
console.log('呼叫成功', res.data)
|
// console.log('呼叫成功', res.data)
|
||||||
this.calling = true
|
this.calling = true
|
||||||
if (res.status === 'success') {
|
if (res.status === 'success') {
|
||||||
this.callingSuccess()
|
this.callingSuccess()
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user