优化客服售后电话拨打
parent
0205c7eac7
commit
8330c423f9
|
@ -444,23 +444,23 @@ const tools = {
|
||||||
* @description 拨打电话
|
* @description 拨打电话
|
||||||
* @param {Number} phone
|
* @param {Number} phone
|
||||||
*/
|
*/
|
||||||
countCustomer(phone1=10086,phone2=10010){
|
countCustomer(phone1,phone2){
|
||||||
const res = uni.getSystemInfoSync();
|
const res = uni.getSystemInfoSync();
|
||||||
|
let phoneList = [];
|
||||||
|
if(phone1!==''){
|
||||||
|
phoneList.push(phone1);
|
||||||
|
}
|
||||||
|
if(phone2!==''){
|
||||||
|
phoneList.push(phone2);
|
||||||
|
}
|
||||||
uni.showActionSheet({
|
uni.showActionSheet({
|
||||||
itemList:[phone1,phone2],
|
itemList:phoneList,
|
||||||
itemColor:'#3875F6',
|
itemColor:'#3875F6',
|
||||||
success: (res) => {
|
success: (res) => {
|
||||||
if(res.tapIndex==0){
|
|
||||||
uni.makePhoneCall({
|
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
|
@ -4585,22 +4585,22 @@ Object.defineProperty(exports, "__esModule", { value: true });exports.default =
|
||||||
* @description 拨打电话
|
* @description 拨打电话
|
||||||
* @param {Number} phone
|
* @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 res = uni.getSystemInfoSync();
|
||||||
|
var phoneList = [];
|
||||||
|
if (phone1 !== '') {
|
||||||
|
phoneList.push(phone1);
|
||||||
|
}
|
||||||
|
if (phone2 !== '') {
|
||||||
|
phoneList.push(phone2);
|
||||||
|
}
|
||||||
uni.showActionSheet({
|
uni.showActionSheet({
|
||||||
itemList: [phone1, phone2],
|
itemList: phoneList,
|
||||||
itemColor: '#3875F6',
|
itemColor: '#3875F6',
|
||||||
success: function success(res) {
|
success: function success(res) {
|
||||||
if (res.tapIndex == 0) {
|
|
||||||
uni.makePhoneCall({
|
uni.makePhoneCall({
|
||||||
phoneNumber: phone1 });
|
phoneNumber: phoneList[res.tapIndex] });
|
||||||
|
|
||||||
}
|
|
||||||
if (res.tapIndex == 1) {
|
|
||||||
uni.makePhoneCall({
|
|
||||||
phoneNumber: phone2 });
|
|
||||||
|
|
||||||
}
|
|
||||||
} });
|
} });
|
||||||
|
|
||||||
},
|
},
|
||||||
|
|
Loading…
Reference in New Issue