去掉打印 和改接口地址
This commit is contained in:
+17
-24
@@ -199,7 +199,6 @@
|
||||
}
|
||||
},
|
||||
onLoad(options) {
|
||||
console.log(options);
|
||||
this.getlocahost()
|
||||
this.id = options.id;
|
||||
this.form.customer_id = options.id;
|
||||
@@ -292,13 +291,13 @@
|
||||
success: (res) => {
|
||||
if (res.data.results && res.data.results.length > 0) {
|
||||
this.form.address = res.data.results[0].formatted_address; // 获取格式化地址
|
||||
console.log(res.data.results[0].formatted_address)
|
||||
// console.log(res.data.results[0].formatted_address)
|
||||
} else {
|
||||
console.error('未找到地址');
|
||||
// console.error('未找到地址');
|
||||
}
|
||||
},
|
||||
fail: (err) => {
|
||||
console.error('请求失败:', err);
|
||||
// console.error('请求失败:', err);
|
||||
},
|
||||
});
|
||||
},
|
||||
@@ -307,17 +306,15 @@
|
||||
uni.getLocation({
|
||||
type: 'wgs84', // 默认为 wgs84 坐标系,可选 gcj02
|
||||
success: function (res) {
|
||||
console.log('当前位置的经度:' + res.longitude);
|
||||
console.log('当前位置的纬度:' + res.latitude);
|
||||
that.getarrd(res.longitude,res.latitude)
|
||||
// 如果需要将经纬度转换为具体地址,可以使用逆地理编码
|
||||
// 这里调用 uni.chooseLocation 或第三方地图服务(如高德、腾讯地图)
|
||||
},
|
||||
fail: function (err) {
|
||||
console.log('获取位置失败:', err);
|
||||
// console.log('获取位置失败:', err);
|
||||
},
|
||||
complete: function () {
|
||||
console.log('获取位置完成');
|
||||
// console.log('获取位置完成');
|
||||
}
|
||||
});
|
||||
},
|
||||
@@ -325,11 +322,11 @@
|
||||
if (navigator.geolocation) {
|
||||
navigator.geolocation.getCurrentPosition(
|
||||
(position) => {
|
||||
console.log('当前位置的经度:' + position.coords.longitude);
|
||||
console.log('当前位置的纬度:' + position.coords.latitude);
|
||||
// console.log('当前位置的经度:' + position.coords.longitude);
|
||||
// console.log('当前位置的纬度:' + position.coords.latitude);
|
||||
this.getarrd(position.coords.longitude,position.coords.latitude)
|
||||
this.error = '';
|
||||
console.log("获取位置成功:", position);
|
||||
// console.log("获取位置成功:", position);
|
||||
},
|
||||
(error) => {
|
||||
this.unigetLocation()
|
||||
@@ -338,7 +335,7 @@
|
||||
// title: this.error,
|
||||
// icon: 'none'
|
||||
// });
|
||||
console.error("获取位置失败:", error);
|
||||
// console.error("获取位置失败:", error);
|
||||
},
|
||||
{
|
||||
enableHighAccuracy: true,
|
||||
@@ -353,7 +350,7 @@
|
||||
// title: this.error,
|
||||
// icon: 'none'
|
||||
// });
|
||||
console.error("浏览器不支持 Geolocation API");
|
||||
// console.error("浏览器不支持 Geolocation API");
|
||||
}
|
||||
},
|
||||
getErrorMessage(error) {
|
||||
@@ -379,7 +376,7 @@
|
||||
}).then(res => {
|
||||
this.datas = res.data.data
|
||||
this.followList = res.data.data
|
||||
console.log(res.data.data)
|
||||
// console.log(res.data.data)
|
||||
})
|
||||
},
|
||||
//保存跟进
|
||||
@@ -421,7 +418,6 @@
|
||||
confirm(e) {
|
||||
this.show = false
|
||||
this.form.firstFollowtime = this.result(e.value, e.mode)
|
||||
console.log(this.result(e.value, e.mode))
|
||||
},
|
||||
cancelnext() {
|
||||
this.shownexttime = false
|
||||
@@ -429,7 +425,6 @@
|
||||
confirmnext(e) {
|
||||
this.shownexttime = false
|
||||
this.nexttime = this.result(e.value, e.mode)
|
||||
console.log(this.nexttime)
|
||||
request({
|
||||
url:'customer/followNext',
|
||||
method:'post',
|
||||
@@ -451,18 +446,17 @@
|
||||
|
||||
},
|
||||
change(e) {
|
||||
// console.log('change', e)
|
||||
},
|
||||
|
||||
delfn(name){
|
||||
console.log(name)
|
||||
that.carinfo[name] =''
|
||||
},
|
||||
uploadfn(imgUrl,name){
|
||||
var that = this;
|
||||
uni.uploadFile({
|
||||
// url: 'http://api.crm.hnxinyouhe.com/upload',
|
||||
url: 'http://219.157.255.213:9007/upload/uploadImage',
|
||||
// url: 'https://api.fcrm.hnxinyouhe.com/upload/uploadImage',
|
||||
url: 'https://crm-server.smt.hnxinyouhe.com/upload/uploadImage',
|
||||
filePath: imgUrl,
|
||||
name: 'files',
|
||||
header:{'Authorization': 'Bearer ' + uni.getStorageSync('token')},
|
||||
@@ -470,7 +464,6 @@
|
||||
const path=JSON.parse(uploadFileRes.data)
|
||||
if(path.code==0){
|
||||
that.form[name] = path.data.path
|
||||
console.log(that.form)
|
||||
}else{
|
||||
uni.showToast({
|
||||
title: path.message,
|
||||
@@ -503,10 +496,10 @@
|
||||
options.engine = 'baidu';
|
||||
that.form.audio_text = "";
|
||||
plus.speech.startRecognize(options, function (s) {
|
||||
console.log(s);
|
||||
// console.log(s);
|
||||
that.form.audio_text += s;
|
||||
}, function (e) {
|
||||
console.log("语音识别失败:" + e.message);
|
||||
// console.log("语音识别失败:" + e.message);
|
||||
});
|
||||
},
|
||||
async startRecognize () {
|
||||
@@ -524,12 +517,12 @@
|
||||
options.punctuation = false; // 是否需要标点符号
|
||||
options.timeout = 10 * 1000; //语音录入持续时长
|
||||
plus.speech.startRecognize(options, function(s) {
|
||||
console.log(s);
|
||||
// console.log(s);
|
||||
that.form.remark += s;
|
||||
// 关闭语音
|
||||
plus.speech.stopRecognize();
|
||||
}, function (e) {
|
||||
console.log("语音识别失败:" + e.message);
|
||||
// console.log("语音识别失败:" + e.message);
|
||||
});
|
||||
},
|
||||
// #ifdef APP-PLUS
|
||||
|
||||
Reference in New Issue
Block a user