优化客服售后电话拨打

master
chen 2022-08-25 14:10:04 +08:00
parent 0205c7eac7
commit 8330c423f9
4 changed files with 25 additions and 25 deletions

View File

@ -444,23 +444,23 @@ const tools = {
* @description 拨打电话
* @param {Number} phone
*/
countCustomer(phone1=10086,phone2=10010){
countCustomer(phone1,phone2){
const res = uni.getSystemInfoSync();
let phoneList = [];
if(phone1!==''){
phoneList.push(phone1);
}
if(phone2!==''){
phoneList.push(phone2);
}
uni.showActionSheet({
itemList:[phone1,phone2],
itemList:phoneList,
itemColor:'#3875F6',
success: (res) => {
if(res.tapIndex==0){
uni.makePhoneCall({
phoneNumber:phone1
phoneNumber:phoneList[res.tapIndex]
})
}
if(res.tapIndex==1){
uni.makePhoneCall({
phoneNumber:phone2
})
}
}
})
},
/**

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -4585,22 +4585,22 @@ Object.defineProperty(exports, "__esModule", { value: true });exports.default =
* @description 拨打电话
* @param {Number} phone
*/
countCustomer: function countCustomer() {var phone1 = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 10086;var phone2 = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 10010;
countCustomer: function countCustomer(phone1, phone2) {
var res = uni.getSystemInfoSync();
var phoneList = [];
if (phone1 !== '') {
phoneList.push(phone1);
}
if (phone2 !== '') {
phoneList.push(phone2);
}
uni.showActionSheet({
itemList: [phone1, phone2],
itemList: phoneList,
itemColor: '#3875F6',
success: function success(res) {
if (res.tapIndex == 0) {
uni.makePhoneCall({
phoneNumber: phone1 });
phoneNumber: phoneList[res.tapIndex] });
}
if (res.tapIndex == 1) {
uni.makePhoneCall({
phoneNumber: phone2 });
}
} });
},