//调用拨打电话api
makePhone() {
let that = this
uni.makePhoneCall({
phoneNumber: '114',
success(e) {
that.$message.info(JSON.stringify(e) + 'makePhoneCall---seccess1111');
},
fail(e) {
that.$message.info(JSON.stringify(e) + 'makePhoneCall---fail2222');
},
complete(e) {
that.$message.info(JSON.stringify(e) + 'makePhoneCall---complete33333');
}
})
},
//拦截拨打电话api
uni.addInterceptor('makePhoneCall', {
invoke(res) {
},
success(e) {
// 没有权限
// message.info(JSON.stringify(e) + 'addInterceptor---seccess1111');
console.log(e, 'success makePhoneCall')
},
fail(e) {
// message.info(JSON.stringify(e) + 'addInterceptor---fail222');
// 没有权限
noPerTips(e, '请打开拨打电话权限')
},
complete(e) {
// message.info(JSON.stringify(e) +'addInterceptor---complete33333');
console.log(e, 'complete');
completeFun()
}
})