Squashed commit of the following:
commitf9e9899e0eAuthor: 浅念 <email@sample.com> Date: Fri Mar 28 11:10:56 2025 +0800 设置默认语言为英语 commit303121ba81Author: 浅念 <email@sample.com> Date: Fri Mar 28 11:00:05 2025 +0800 调用接口调整 commit37e0e55d96Author: 浅念 <email@sample.com> Date: Fri Mar 28 10:33:48 2025 +0800 线上接口地址 commit11dd7de521Author: 浅念 <email@sample.com> Date: Thu Mar 27 16:54:52 2025 +0800 修改样式 commit8ceb98b321Author: 浅念 <email@sample.com> Date: Thu Mar 27 16:47:04 2025 +0800 隐藏我的名片 commitf58e712684Author: 浅念 <email@sample.com> Date: Thu Mar 27 16:44:43 2025 +0800 样式调整 commit54ad6c9e37Author: 浅念 <email@sample.com> Date: Thu Mar 27 16:35:21 2025 +0800 修改语言包 commit526f934a75Author: 浅念 <email@sample.com> Date: Thu Mar 27 16:13:47 2025 +0800 标签功能 commit8583ff2543Author: 浅念 <email@sample.com> Date: Wed Mar 26 17:02:04 2025 +0800 标签管理页面 commitbe8674fd51Author: 浅念 <email@sample.com> Date: Tue Mar 25 17:29:37 2025 +0800 样式调整 commita5d5ce4e7cAuthor: 浅念 <email@sample.com> Date: Tue Mar 25 17:23:40 2025 +0800 倒计时组件 commitf88048b876Author: 浅念 <email@sample.com> Date: Tue Mar 25 17:19:43 2025 +0800 首页添加跟进提醒 commitf9a39d5aaaAuthor: 浅念 <email@sample.com> Date: Tue Mar 25 13:13:39 2025 +0800 提交 commite3abe0bf18Author: 浅念 <email@sample.com> Date: Tue Mar 25 13:12:24 2025 +0800 名片部分页面。地图定位。国家下拉搜索 回收站
This commit is contained in:
+89
-54
@@ -13,14 +13,14 @@
|
||||
<view class="cont">
|
||||
<view class="title">
|
||||
<view class=""><text class="name">{{userdatas.phone}}</text></view>
|
||||
<view class="ststus">渠道:{{userdatas.channel_name}}</view>
|
||||
<view class="ststus">{{$t('channel')}}:{{userdatas.channel_name}}</view>
|
||||
</view>
|
||||
<view class="info"><text class="sex">{{userdatas.sex_txt}}</text> | <text class="addr">{{userdatas.country_name}}</text><text class="type">{{userdatas.car_type_name}}</text>
|
||||
</view>
|
||||
<view v-if="userdatas.email!=''">Email: {{userdatas.email}}</view>
|
||||
<view v-if="userdatas.WhatsApp!=''">WhatsAPP: {{userdatas.WhatsApp}}</view>
|
||||
<view v-if="userdatas.address!=''">公司: {{userdatas.address}}</view>
|
||||
<view v-if="userdatas.describe!=''">备注: {{userdatas.describe}}</view>
|
||||
<view v-if="userdatas.address!=''">{{$t('customer.Company')}}: {{userdatas.address}}</view>
|
||||
<view v-if="userdatas.describe!=''">{{$t('remarks')}}: {{userdatas.describe}}</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="cell2">
|
||||
@@ -97,26 +97,36 @@
|
||||
{{$t('customer.followrecord')}} <text class="status" :style="{color:(datas.follow == 0 ?'#3471FF' : datas.follow == 1 ?'#27C89C': '#FF4040')}">{{datas.follow_txt}}</text>
|
||||
</view>
|
||||
<u-steps v-if="followList.length>0" :current="followList.length" direction="column" dot>
|
||||
<u-steps-item :title="item.type_txt" v-for="(item, index) in followList" :key="index">
|
||||
<u-steps-item :title="item.type==1? $t('customer.Online') : $t('customer.Visit') " v-for="(item, index) in followList" :key="index">
|
||||
<view slot="desc" class="desc">
|
||||
<view class="" v-if="item.type==0">
|
||||
<view class="flex" v-if="item.type==0">
|
||||
<view class="">
|
||||
<view class="">
|
||||
<view class="lingh">
|
||||
{{$t('times')}} :{{item.created_at}}
|
||||
</view>
|
||||
<view class="">{{$t('address')}}:{{item.address}}</view>
|
||||
<view class="">{{$t('customer.Visitcontent')}}:{{item.audio_text}}</view>
|
||||
<view class="lingh">{{$t('customer.Visitcontent')}}:{{item.audio_text}}</view>
|
||||
</view>
|
||||
<view class="">
|
||||
<image :src="item.oss_picture" mode=""></image>
|
||||
<!-- <image :src="item.oss_picture" mode=""></image> -->
|
||||
<u-album
|
||||
:urls="isurls(item.oss_picture)"
|
||||
:singleSize="80"
|
||||
keyName="src"
|
||||
></u-album>
|
||||
</view>
|
||||
</view>
|
||||
<view class="" v-else>
|
||||
<view class="">
|
||||
<view class="lingh">
|
||||
{{$t('times')}}:{{item.created_at}}
|
||||
</view>
|
||||
<view class="">
|
||||
<image :src="item.oss_picture" mode=""></image>
|
||||
<!-- <image :src="item.oss_picture" mode=""></image> -->
|
||||
<u-album
|
||||
:urls="isurls(item.oss_picture)"
|
||||
:singleSize="80"
|
||||
keyName="src"
|
||||
></u-album>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
@@ -187,11 +197,12 @@
|
||||
},
|
||||
onLoad(options) {
|
||||
console.log(options);
|
||||
this.getlocahost()
|
||||
this.id = options.id;
|
||||
this.form.customer_id = options.id;
|
||||
var that = this
|
||||
this.getGrade()
|
||||
this.getlocahost()
|
||||
|
||||
this.customerdetailfn()
|
||||
this.followlistfn()
|
||||
},
|
||||
@@ -199,6 +210,13 @@
|
||||
leftClick(){
|
||||
uni.navigateBack({})
|
||||
},
|
||||
isurls(url){
|
||||
var urls=[]
|
||||
var obj={}
|
||||
obj.src = url
|
||||
urls.push(obj)
|
||||
return urls
|
||||
},
|
||||
close(val){
|
||||
this[val]=false
|
||||
},
|
||||
@@ -281,33 +299,7 @@
|
||||
},
|
||||
});
|
||||
},
|
||||
getlocahost(){
|
||||
// 检查定位权限
|
||||
uni.getSetting({
|
||||
success: (res) => {
|
||||
if (!res.authSetting['scope.userLocation']) {
|
||||
// 未授权,请求权限
|
||||
uni.authorize({
|
||||
scope: 'scope.userLocation',
|
||||
success: () => {
|
||||
this.getlocahost();
|
||||
},
|
||||
fail: () => {
|
||||
uni.showToast({
|
||||
title: '定位权限未授权',
|
||||
icon: 'none',
|
||||
});
|
||||
},
|
||||
});
|
||||
} else {
|
||||
// 已授权,直接获取定位
|
||||
this.getlocahost();
|
||||
}
|
||||
},
|
||||
});
|
||||
},
|
||||
getlocahost(){
|
||||
|
||||
unigetLocation(){
|
||||
var that = this
|
||||
uni.getLocation({
|
||||
type: 'wgs84', // 默认为 wgs84 坐标系,可选 gcj02
|
||||
@@ -325,18 +317,53 @@
|
||||
console.log('获取位置完成');
|
||||
}
|
||||
});
|
||||
|
||||
// uni.chooseLocation({
|
||||
// success: function (res) {
|
||||
// console.log('位置名称:' + res.name);
|
||||
// console.log('详细地址:' + res.address);
|
||||
// console.log('经度:' + res.longitude);
|
||||
// console.log('纬度:' + res.latitude);
|
||||
// },
|
||||
// fail: function (err) {
|
||||
// console.log('选择位置失败:', err);
|
||||
// }
|
||||
// });
|
||||
},
|
||||
getlocahost() {
|
||||
if (navigator.geolocation) {
|
||||
navigator.geolocation.getCurrentPosition(
|
||||
(position) => {
|
||||
console.log('当前位置的经度:' + position.coords.longitude);
|
||||
console.log('当前位置的纬度:' + position.coords.latitude);
|
||||
this.getarrd(position.coords.longitude,position.coords.latitude)
|
||||
this.error = '';
|
||||
console.log("获取位置成功:", position);
|
||||
},
|
||||
(error) => {
|
||||
this.unigetLocation()
|
||||
// this.error = this.getErrorMessage(error);
|
||||
// uni.showToast({
|
||||
// title: this.error,
|
||||
// icon: 'none'
|
||||
// });
|
||||
console.error("获取位置失败:", error);
|
||||
},
|
||||
{
|
||||
enableHighAccuracy: true,
|
||||
timeout: 10000,
|
||||
maximumAge: 0
|
||||
}
|
||||
);
|
||||
} else {
|
||||
this.unigetLocation()
|
||||
// this.error = "浏览器不支持 Geolocation API";
|
||||
// uni.showToast({
|
||||
// title: this.error,
|
||||
// icon: 'none'
|
||||
// });
|
||||
console.error("浏览器不支持 Geolocation API");
|
||||
}
|
||||
},
|
||||
getErrorMessage(error) {
|
||||
switch (error.code) {
|
||||
case error.PERMISSION_DENIED:
|
||||
return "用户拒绝了地理位置权限";
|
||||
case error.POSITION_UNAVAILABLE:
|
||||
return "无法获取当前位置";
|
||||
case error.TIMEOUT:
|
||||
return "获取位置超时";
|
||||
default:
|
||||
return "未知错误";
|
||||
}
|
||||
},
|
||||
// 跟进记录
|
||||
followlistfn(){
|
||||
@@ -438,14 +465,14 @@
|
||||
header:{'Authorization': 'Bearer ' + uni.getStorageSync('token')},
|
||||
success: (uploadFileRes) => {
|
||||
const path=JSON.parse(uploadFileRes.data)
|
||||
if(path.code==-1){
|
||||
if(path.code==0){
|
||||
that.form[name] = path.data.path
|
||||
console.log(that.form)
|
||||
}else{
|
||||
uni.showToast({
|
||||
title: path.message,
|
||||
icon: 'none'
|
||||
});
|
||||
}else{
|
||||
that.form[name] = path.data.path
|
||||
console.log(that.form)
|
||||
}
|
||||
}
|
||||
});
|
||||
@@ -733,6 +760,14 @@
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
color: #999999;
|
||||
.lingh{
|
||||
line-height: 40px;
|
||||
}
|
||||
.flex{
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
}
|
||||
}
|
||||
.title{
|
||||
color: #666666;
|
||||
|
||||
Reference in New Issue
Block a user