Browse Source

feat(market): 添加拨打电话功能并记录通话

- 在拨打电话前增加号码非空校验- 添加通过记录到服务器
- 处理通话记录失败的错误提示
master
liutong 12 months ago
parent
commit
9343ebfb2d
  1. 23
      pages/market/clue/add_clues.vue

23
pages/market/clue/add_clues.vue

@ -779,8 +779,29 @@ export default {
}, },
// //
dialTel(item) { async dialTel(item) {
let tel = item.student_phone let tel = item.student_phone
if (!tel) {
uni.showToast({
title: '电话号码为空',
icon: 'none'
});
return;
}
let param = {
sales_id: item.id//线id
}
let res = await marketApi.setCallUp(param)//
if (res.code != 1) {
uni.showToast({
title: res.msg,
icon: 'none'
})
return
}
uni.makePhoneCall({ uni.makePhoneCall({
phoneNumber: tel phoneNumber: tel
}) })

Loading…
Cancel
Save