修改页面
This commit is contained in:
+27
@@ -77,6 +77,15 @@
|
||||
"enablePullDownRefresh": false,
|
||||
"navigationStyle":"custom"// 去掉微信小程序顶部导航
|
||||
}
|
||||
},
|
||||
{
|
||||
"path" : "pages/index/webview",
|
||||
"style" :
|
||||
{
|
||||
"navigationBarTitleText" : "",
|
||||
"enablePullDownRefresh": false,
|
||||
"navigationStyle":"custom"// 去掉微信小程序顶部导航
|
||||
}
|
||||
}
|
||||
],
|
||||
"subPackages":[
|
||||
@@ -203,6 +212,24 @@
|
||||
"enablePullDownRefresh": false,
|
||||
"navigationStyle":"custom"// 去掉微信小程序顶部导航
|
||||
}
|
||||
},
|
||||
{
|
||||
"path" : "recyclebin",
|
||||
"style" :
|
||||
{
|
||||
"navigationBarTitleText" : "",
|
||||
"enablePullDownRefresh": false,
|
||||
"navigationStyle":"custom"// 去掉微信小程序顶部导航
|
||||
}
|
||||
},
|
||||
{
|
||||
"path" : "recyclebindetil",
|
||||
"style" :
|
||||
{
|
||||
"navigationBarTitleText" : "",
|
||||
"enablePullDownRefresh": false,
|
||||
"navigationStyle":"custom"// 去掉微信小程序顶部导航
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
@@ -282,6 +282,32 @@
|
||||
});
|
||||
},
|
||||
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(){
|
||||
|
||||
var that = this
|
||||
uni.getLocation({
|
||||
type: 'wgs84', // 默认为 wgs84 坐标系,可选 gcj02
|
||||
@@ -406,7 +432,7 @@
|
||||
var that = this;
|
||||
uni.uploadFile({
|
||||
// url: 'http://api.crm.hnxinyouhe.com/upload',
|
||||
url: 'http://219.157.255.213:9007',
|
||||
url: 'http://219.157.255.213:9007/upload/uploadImage',
|
||||
filePath: imgUrl,
|
||||
name: 'files',
|
||||
header:{'content-type': 'application/x-www-form-urlencoded','Authorization': 'Bearer ' + uni.getStorageSync('token')},
|
||||
|
||||
+59
-12
@@ -7,17 +7,19 @@
|
||||
<view class="content">
|
||||
<view class="contop">
|
||||
<view class="">
|
||||
<!-- <image class="userimg" :src="userinfo.avatar" mode=""></image> -->
|
||||
<image class="userimg" src="/static/image/mine/user.png" mode=""></image>
|
||||
<image class="userimg" :src="userinfo.avatar==''||userinfo.avatar==null||userinfo.avatar=='null'?'/static/image/mine/user.png':userinfo.avatar" mode=""></image>
|
||||
<!-- <image class="userimg" src="/static/image/mine/user.png" mode=""></image> -->
|
||||
</view>
|
||||
<!-- <view class="right" @click="changinfo"> -->
|
||||
<view class="right">
|
||||
<view class="">
|
||||
<text>{{userinfo.email}}</text>
|
||||
<!-- <image src="/static/image/mine/edit.png" mode=""></image> -->
|
||||
<!-- <view class="right"> -->
|
||||
<view class="" @click="changinfo">
|
||||
<text>{{userinfo.name}}</text>
|
||||
<image src="/static/image/mine/edit.png" mode=""></image>
|
||||
</view>
|
||||
<view class="mineid">
|
||||
ID:{{userinfo.id}}
|
||||
<view class="minemp">
|
||||
<view class="mineid">ID:{{userinfo.id}}</view>
|
||||
<!-- <view class="mp" @click="gomymp">{{$t('auth')}}</view> -->
|
||||
<view v-if="!isopenid" class="mp" @click="gomyauth">{{$t('auth')}}</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
@@ -32,11 +34,11 @@
|
||||
<uni-icons type="right" class="icon" size="18"></uni-icons>
|
||||
</view>
|
||||
</view> -->
|
||||
<!-- <view class="sonContent" @click="navTo('/pages/mine/resetPwd')">
|
||||
<view class="sonContent" @click="navTo('/pages/mine/resetPwd')">
|
||||
<image class="son-img-bg" src="/static/image/mine/icon2.png"></image>
|
||||
<span>{{$t('mine.cpassword')}}</span>
|
||||
<uni-icons type="right" class="icon" size="18"></uni-icons>
|
||||
</view> -->
|
||||
</view>
|
||||
<view class="sonContent" @click="show=true">
|
||||
<image class="son-img-bg" src="/static/image/mine/icon3.png"></image>
|
||||
<span>{{$t('mine.contact')}}</span>
|
||||
@@ -57,6 +59,11 @@
|
||||
<span>{{$t('mine.logoff')}}</span>
|
||||
<uni-icons type="right" class="icon" size="18"></uni-icons>
|
||||
</view> -->
|
||||
<!-- <view class="sonContent" @click="navTo('/pages/mine/recyclebin')">
|
||||
<image class="son-img-bg" src="/static/image/mine/icon8.png"></image>
|
||||
<span>{{$t('mine.recyclebin')}}</span>
|
||||
<uni-icons type="right" class="icon" size="18"></uni-icons>
|
||||
</view> -->
|
||||
<view class="sonContent" @click="logout">
|
||||
<image class="son-img-bg" src="/static/image/mine/icon7.png"></image>
|
||||
<span>{{$t('mine.logout')}}</span>
|
||||
@@ -84,15 +91,41 @@
|
||||
data() {
|
||||
return {
|
||||
userinfo:'',
|
||||
show: false
|
||||
show: false,
|
||||
isopenid:false,
|
||||
}
|
||||
},
|
||||
onLoad() {
|
||||
this.userinfo =JSON.parse(uni.getStorageSync('userinfo'))
|
||||
// this.userinfo =JSON.parse(uni.getStorageSync('userinfo'))
|
||||
|
||||
},
|
||||
onShow() {
|
||||
this.getuserinfo()
|
||||
},
|
||||
methods: {
|
||||
getuserinfo(){
|
||||
|
||||
request({
|
||||
url:'user/getInfo',
|
||||
method:'get',
|
||||
}).then(res => {
|
||||
this.userinfo = res.data.data;
|
||||
if(this.userinfo.feishu_openid&&this.userinfo.feishu_openid!=null&&this.userinfo.feishu_openid!='null'&&this.userinfo.feishu_openid!=''){
|
||||
this.isopenid=true
|
||||
}
|
||||
|
||||
})
|
||||
},
|
||||
gomymp(){
|
||||
uni.navigateTo({
|
||||
url: '/pages/mine/webview'
|
||||
})
|
||||
},
|
||||
gomyauth(){
|
||||
uni.navigateTo({
|
||||
url: '/pages/index/webview'
|
||||
})
|
||||
},
|
||||
changinfo(){
|
||||
uni.navigateTo({
|
||||
url: '/pages/mine/changinfo'
|
||||
@@ -173,6 +206,7 @@
|
||||
font-size: 34rpx;
|
||||
color: white;
|
||||
.right{
|
||||
flex: 2;
|
||||
margin-left: 15px;
|
||||
image{
|
||||
width: 32rpx;
|
||||
@@ -182,9 +216,22 @@
|
||||
view{
|
||||
line-height: 30px;
|
||||
}
|
||||
.minemp{
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
.mp{
|
||||
font-size: 28rpx;
|
||||
background: #fff;
|
||||
color: #3471FF;
|
||||
padding: 1px 15px;
|
||||
border-radius: 5px 15px 15px 15px;
|
||||
}
|
||||
}
|
||||
.mineid{
|
||||
font-size: 24rpx;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,65 @@
|
||||
<template>
|
||||
<view>
|
||||
<web-view style="background-color: #fafafa;height: 100vh;" ref="webview" :src="webUrl"></web-view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { request,showToast } from '@/api/apiT.js'
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
webUrl:''
|
||||
}
|
||||
},
|
||||
onLoad(options) {
|
||||
console.log(options);
|
||||
this.feishugetAuth()
|
||||
if(options.code){
|
||||
request({
|
||||
url:'feishu/getAuth',
|
||||
method:'post',
|
||||
data:{
|
||||
code:options.code
|
||||
}
|
||||
}).then(res => {
|
||||
uni.showToast({
|
||||
title: res.data.message,
|
||||
icon: 'none'
|
||||
});
|
||||
if(res.data.code ==0){
|
||||
setTimeout(() => {
|
||||
uni.reLaunch({
|
||||
url: '/pages/index/mine',// 替换为你要跳转的页面路径
|
||||
});
|
||||
}, 1000);
|
||||
}
|
||||
})
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
feishugetAuth(){
|
||||
const pages = getCurrentPages();
|
||||
const currentPage = pages[pages.length - 1];
|
||||
const route = currentPage.route; // 页面路径
|
||||
const options = currentPage.options; // 页面参数
|
||||
const fullUrl = `${route}?${Object.keys(options).map(key => `${key}=${options[key]}`).join('&')}`;
|
||||
console.log('当前页面完整 URL:', fullUrl);
|
||||
request({
|
||||
url:'feishu/getinfo',
|
||||
method:'post',
|
||||
}).then(res => {
|
||||
var data = res.data.data;
|
||||
var urls = data.url+fullUrl
|
||||
console.log(data)
|
||||
this.webUrl = 'https://open.feishu.cn/open-apis/authen/v1/authorize?app_id='+data.app_id+'&redirect_uri='+urls+'&scope='+data.scope+'&state='+data.state
|
||||
console.log(this.webUrl)
|
||||
})
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style>
|
||||
|
||||
</style>
|
||||
@@ -117,6 +117,7 @@
|
||||
})
|
||||
},
|
||||
getVcode() {
|
||||
|
||||
if(this.email==''){
|
||||
uni.showToast({
|
||||
title:this.$t('emailerr'),
|
||||
|
||||
+121
-27
@@ -3,16 +3,18 @@
|
||||
<uni-nav-bar leftText=" " :fixed="true" :border="false" leftIcon="back" @clickLeft="leftClick" color="#000000" backgroundColor="#fff" :statusBar="true" :title="$t('navbar.persondata')"></uni-nav-bar>
|
||||
<view class="content">
|
||||
<view class="topimg">
|
||||
<image class="user" src="/static/image/mine/user.png" mode=""></image>
|
||||
<image class="xj" src="/static/image/mine/xiangji.png" mode=""></image>
|
||||
<view>{{$t('mine.changeavatar')}}</view>
|
||||
<uni-file-picker fileMediatype="image" limit="1" :list-styles="imageStyles" :del-icon="false" disable-preview @select="select" @delete="delfn('picture')">
|
||||
<image class="user" :src="userinfo.avatar==''||userinfo.avatar==null||userinfo.avatar=='null'?'/static/image/mine/user.png':userinfo.avatar"mode=""></image>
|
||||
<!-- <image class="xj" src="/static/image/mine/xiangji.png" mode=""></image> -->
|
||||
</uni-file-picker>
|
||||
<view>{{$t('mine.changeavatar')}}</view>
|
||||
</view>
|
||||
<view class="cell1">
|
||||
<view class="item">{{$t('gender')}}</view>
|
||||
<view class="right">
|
||||
<u-radio-group v-model="userinfo.gender">
|
||||
<u-radio name="1" class="m-r-10">{{$t('gender1')}}</u-radio>
|
||||
<u-radio name="2">{{$t('gender2')}}</u-radio>
|
||||
<u-radio-group v-model="userinfo.sex">
|
||||
<u-radio :name="Number(1)" class="m-r-10">{{$t('gender1')}}</u-radio>
|
||||
<u-radio :name="Number(2)">{{$t('gender2')}}</u-radio>
|
||||
</u-radio-group>
|
||||
</view>
|
||||
</view>
|
||||
@@ -20,28 +22,53 @@
|
||||
<view class="cell1">
|
||||
<view class="item">{{$t('mine.nickname')}}</view>
|
||||
<view class="right">
|
||||
<input :placeholder="$t('mine.nicknameinputhd')" v-model="userinfo.nickname"></input>
|
||||
<input :placeholder="$t('mine.nicknameinputhd')" v-model="userinfo.name"></input>
|
||||
</view>
|
||||
</view>
|
||||
<u-divider text=""></u-divider>
|
||||
<view class="cell1">
|
||||
<view class="item">{{$t('mine.lxcall')}}</view>
|
||||
<view class="right">
|
||||
<input :placeholder="$t('mine.lxcallinputhd')" type="number" v-model="userinfo.phone"></input>
|
||||
<input :placeholder="$t('mine.lxcallinputhd')" type="number" v-model="userinfo.mobile"></input>
|
||||
</view>
|
||||
</view>
|
||||
<u-divider text=""></u-divider>
|
||||
<view class="cell1">
|
||||
<view class="item">{{$t('mine.position')}}</view>
|
||||
<view class="right">
|
||||
<input :placeholder="$t('mine.positioninput')" type="text" v-model="userinfo.position"></input>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- <view class="cell1">
|
||||
<view class="item">{{$t('Region')}}</view>
|
||||
<view class="right select">
|
||||
<input :placeholder="$t('Regioninputhd')" v-model="userinfo.company"></input>
|
||||
<u-icon class="arrowright" name="arrow-right" size="18" color="#747474"></u-icon>
|
||||
</view>
|
||||
</view> -->
|
||||
<view class="cell1">
|
||||
<view class="item">{{$t('customer.Company')}}</view>
|
||||
<view class="right select" @click="showcomp = true">
|
||||
<view class="" :class="['content2', { placeholder: !company_name }]">{{company_name || $t('inputnl')}}</view>
|
||||
<u-icon class="arrowright" name="arrow-right" size="18" color="#747474"></u-icon>
|
||||
</view>
|
||||
</view>
|
||||
<u-divider text=""></u-divider>
|
||||
<view class="cell1">
|
||||
<view class="item">{{$t('customer.Country')}}</view>
|
||||
<view class="right select" @click="showarea = true">
|
||||
<view class="" :class="['content2', { placeholder: !country_name }]">{{country_name || $t('customer.Countryinput')}}</view>
|
||||
<u-icon class="arrowright" name="arrow-right" size="18" color="#747474"></u-icon>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="foot">
|
||||
<button class="btn" @click="bcFn">{{$t('save')}}</button>
|
||||
</view>
|
||||
<u-picker closeOnClickOverlay :cancel-text="$t('cancel')" :confirm-text="$t('confirm')" :defaultIndex="defaultIndexgj" :show="showarea" @cancel="cancel('showarea')" @close="close('showarea')" :columns="areaList" keyName="name" @confirm="areaChange"></u-picker>
|
||||
<u-picker closeOnClickOverlay :cancel-text="$t('cancel')" :confirm-text="$t('confirm')" :defaultIndex="defaultIndexgs" :show="showcomp" @cancel="cancel('showcomp')" @close="close('showcomp')" :columns="company" keyName="name" @confirm="companyChange"></u-picker>
|
||||
|
||||
</view>
|
||||
</template>
|
||||
<script>
|
||||
@@ -49,39 +76,94 @@
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
showarea: false,
|
||||
showcomp: false,
|
||||
country_name:'',
|
||||
areaList1:[],
|
||||
areaList:[],
|
||||
defaultIndexgj:[0],
|
||||
company_name:'',
|
||||
company:[],
|
||||
company1:[],
|
||||
defaultIndexgs:[0],
|
||||
imageStyles: {
|
||||
width: 40,
|
||||
height: 40,
|
||||
border: {
|
||||
radius: '50%'
|
||||
}
|
||||
},
|
||||
userinfo:{
|
||||
nickname:'',
|
||||
avatar:'',
|
||||
company:'',
|
||||
phone:'',
|
||||
border: true,
|
||||
},
|
||||
userinfo:{},
|
||||
|
||||
}
|
||||
},
|
||||
onLoad() {
|
||||
this.area()
|
||||
this.companyfn()
|
||||
this.getinfo()
|
||||
},
|
||||
methods: {
|
||||
getinfo(){
|
||||
var that= this;
|
||||
request({
|
||||
url:'api/user/info',
|
||||
method:'POST',
|
||||
url:'user/getInfo',
|
||||
method:'get',
|
||||
}).then(res => {
|
||||
that.userinfo = res.data.data
|
||||
that.userinfo = res.data.data;
|
||||
that.select1()
|
||||
})
|
||||
},
|
||||
select1(){
|
||||
var that=this;
|
||||
that.areaList1.forEach((item,index) => {
|
||||
if(item.id == that.userinfo.country_id){
|
||||
that.country_name = item.name
|
||||
that.defaultIndexgj=[index]
|
||||
console.log(that.country_name)
|
||||
}
|
||||
})
|
||||
that.company1.forEach((item,index) => {
|
||||
if(item.id == that.userinfo.sign){
|
||||
that.company_name = item.name
|
||||
that.defaultIndexgs=[index]
|
||||
}
|
||||
})
|
||||
},
|
||||
//国家切换事件
|
||||
areaChange(val){
|
||||
this.userinfo.country_id = val.value[0].id
|
||||
this.country_name = val.value[0].name
|
||||
this.showarea = false
|
||||
},
|
||||
//国家
|
||||
area(){
|
||||
request({
|
||||
url:'area/getCountry',
|
||||
method:'get',
|
||||
}).then(res => {
|
||||
var list = res.data.data
|
||||
this.areaList1 = list
|
||||
this.areaList = [list]
|
||||
this.select1()
|
||||
})
|
||||
},
|
||||
//公司
|
||||
companyfn(){
|
||||
request({
|
||||
url:'feishu/getSign',
|
||||
method:'get',
|
||||
}).then(res => {
|
||||
var list = res.data.data
|
||||
this.company1 = list
|
||||
this.company = [list]
|
||||
this.select1()
|
||||
})
|
||||
},
|
||||
companyChange(val){
|
||||
this.userinfo.sign = val.value[0].id
|
||||
this.company_name = val.value[0].name
|
||||
this.showcomp = false
|
||||
},
|
||||
uploadfn(imgUrl){
|
||||
var that = this;
|
||||
uni.uploadFile({
|
||||
url: 'https://api.collect.hs.hnzhwlkj.club/api/upload/image',
|
||||
url: 'http://219.157.255.213:9007/upload/uploadImage',
|
||||
filePath: imgUrl,
|
||||
name: 'image',
|
||||
header:{'content-type': 'application/x-www-form-urlencoded','Authorization': 'Bearer ' + uni.getStorageSync('token')},
|
||||
@@ -92,6 +174,12 @@
|
||||
}
|
||||
});
|
||||
},
|
||||
cancel(val){
|
||||
this[val] = false
|
||||
},
|
||||
close(val){
|
||||
this[val] = false
|
||||
},
|
||||
delfn(){
|
||||
that.userinfo.avatar =''
|
||||
},
|
||||
@@ -105,13 +193,16 @@
|
||||
},
|
||||
bcFn(){
|
||||
request({
|
||||
url:'api/user/update',
|
||||
url:'user/save',
|
||||
method:'POST',
|
||||
data:{
|
||||
nickname:this.userinfo.nickname,
|
||||
avatar:this.userinfo.avatar,
|
||||
company:this.userinfo.company,
|
||||
phone:this.userinfo.phone
|
||||
sex:this.userinfo.sex,
|
||||
name:this.userinfo.name,
|
||||
mobile:this.userinfo.mobile,
|
||||
position:this.userinfo.position,
|
||||
country_id:this.userinfo.country_id,
|
||||
sign:this.userinfo.sign,
|
||||
}
|
||||
}).then(res => {
|
||||
uni.showToast({
|
||||
@@ -133,6 +224,9 @@
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
.uni-file-picker {
|
||||
margin-left: 33.3%;
|
||||
}
|
||||
.m-r-10{
|
||||
margin-right: 10px;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,139 @@
|
||||
<template>
|
||||
<view>
|
||||
<z-paging ref="paging" v-model="datalist" @query="queryList" empty-view-text='暂无数据!'>
|
||||
<template #top>
|
||||
<uni-nav-bar leftText=" " :fixed="true" :border="false" leftIcon="back" @clickLeft="leftClick" color="#000000"
|
||||
backgroundColor="#fff" :statusBar="true" :title="$t('mine.recyclebin')"></uni-nav-bar>
|
||||
</template>
|
||||
<view class="contents" >
|
||||
<view class="colls" v-for="(item, index) in datalist" :key="index" >
|
||||
<view class="" @click="detileClick(item)">
|
||||
<view class="top">
|
||||
<view class="name">{{item.contacts}}</view>
|
||||
<view class="right">
|
||||
<text class="medal" :style="{color:(item.magnitude == 0 ?'#F5AB00' : item.magnitude == 1 ?'#8495B8': '#9B7200')}">{{item.magnitude_txt}}</text>
|
||||
</view>
|
||||
</view>
|
||||
<u-line margin="20rpx 0px" color="#fff" :hairline="false"></u-line>
|
||||
<view class="cont">
|
||||
<view class="title">
|
||||
<view class=""><text class="name">{{item.phone}}</text></view>
|
||||
<view class="ststus">{{item.grade_txt}}</view>
|
||||
</view>
|
||||
<view class="info"><text class="sex">{{item.sex_txt}}</text> | <text class="addr">{{item.country_name}}</text><text class="type">{{item.car_type_name}}</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="edt">
|
||||
<view class="btn" @click="editFn"><text> {{$t('mine.restore')}}</text></view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</z-paging>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { request,showToast } from '@/api/apiT.js'
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
datalist:[]
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
//客户列表数据
|
||||
queryList(pageNo, pageSize) {
|
||||
var that = this;
|
||||
request({
|
||||
url:'customer/list',
|
||||
method:'get',
|
||||
data: {
|
||||
page:pageNo,
|
||||
per_page:10,
|
||||
}
|
||||
}).then(res => {
|
||||
console.log(res.data)
|
||||
if(res.data.code ==0){
|
||||
var datas = res.data.data.list;
|
||||
this.$refs.paging.complete(datas);
|
||||
}else{
|
||||
// this.$refs.paging.complete(null);
|
||||
// that.listlength=0
|
||||
}
|
||||
uni.stopPullDownRefresh();
|
||||
})
|
||||
},
|
||||
detileClick(item){
|
||||
uni.navigateTo({
|
||||
url: '/pages/mine/recyclebindetil?id='+item.id
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
.contents{
|
||||
background-color: #FFFFFF;
|
||||
padding: 15px;
|
||||
.colls{
|
||||
|
||||
background: #F6F6F6;
|
||||
border-radius: 10px;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
.top{
|
||||
padding: 10px 15px 0px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
}
|
||||
.name{
|
||||
font-size: 32rpx;
|
||||
font-weight: bold;
|
||||
margin-right: 10px;
|
||||
}
|
||||
.cont{
|
||||
padding: 0px 15px 10px;
|
||||
font-size: 24rpx;
|
||||
.title{
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
color: #222222;
|
||||
}
|
||||
.ststus{
|
||||
color: #666666;
|
||||
}
|
||||
.info,.desc{
|
||||
color: #78758E;
|
||||
line-height: 26px;
|
||||
}
|
||||
.sex{
|
||||
margin-right: 5px;
|
||||
}
|
||||
.addr{
|
||||
margin-left: 5px;
|
||||
}
|
||||
.type{
|
||||
margin-left: 5px;
|
||||
color: #3471FF;
|
||||
}
|
||||
}
|
||||
.edt{
|
||||
display: flex;
|
||||
justify-content: right;
|
||||
padding-bottom: 10px;
|
||||
padding-right: 15px;
|
||||
}
|
||||
|
||||
.btn{
|
||||
background: linear-gradient(to right, #3471FF, #6776FF);
|
||||
color: white;
|
||||
border-radius: 50px;
|
||||
text-align: right;
|
||||
padding: 5px 15px;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,333 @@
|
||||
<template>
|
||||
<view>
|
||||
<uni-nav-bar leftText=" " :fixed="true" :border="false" leftIcon="back" @clickLeft="leftClick" color="#000000" backgroundColor="#fff" :statusBar="true" :title="$t('details')"></uni-nav-bar>
|
||||
<view class="content">
|
||||
<view class="contents" >
|
||||
<view class="top">
|
||||
<view class="name">{{datas.contacts}}</view>
|
||||
<view class="right">
|
||||
<text class="medal" :style="{color:(datas.magnitude == 0 ?'#F5AB00' : datas.magnitude == 1 ?'#8495B8': '#9B7200')}">{{datas.magnitude_txt}}</text>
|
||||
</view>
|
||||
</view>
|
||||
<u-line margin="20rpx 0px" color="#fff" :hairline="false"></u-line>
|
||||
<view class="cont">
|
||||
<view class="title">
|
||||
<view class=""><text class="name">{{datas.phone}}</text></view>
|
||||
<view class="ststus">渠道:{{datas.channel_name}}</view>
|
||||
</view>
|
||||
<view class="info"><text class="sex">{{datas.sex_txt}}</text> | <text class="addr">{{datas.country_name}}</text><text class="type">{{datas.car_type_name}}</text>
|
||||
</view>
|
||||
<view v-if="datas.email!=''">Email: {{datas.email}}</view>
|
||||
<view v-if="datas.WhatsApp!=''">WhatsAPP: {{datas.WhatsApp}}</view>
|
||||
<view v-if="datas.address!=''">公司: {{datas.address}}</view>
|
||||
<view v-if="datas.describe!=''">备注: {{datas.describe}}</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="cell">
|
||||
<view class="item">{{$t('customer.Cstomerfj')}}</view>
|
||||
<view class="right select">
|
||||
<view class="" :class="['content2', { placeholder: !datas.grade_txt }]">{{datas.grade_txt || $t('customer.Cstomerfjinput')}}</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<u-gap height="10" bgColor="#F6F6F6"></u-gap>
|
||||
<view class="steps">
|
||||
<view class="title">
|
||||
<view class="">
|
||||
{{$t('customer.followrecord')}} <text class="status" :style="{color:(datas.follow == 0 ?'#3471FF' : datas.follow == 1 ?'#27C89C': '#FF4040')}">{{datas.follow_txt}}</text>
|
||||
</view>
|
||||
</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">
|
||||
<view slot="desc" class="desc">
|
||||
<view class="" v-if="item.type==0">
|
||||
<view class="">
|
||||
<view class="">
|
||||
{{$t('times')}} :{{item.created_at}}
|
||||
</view>
|
||||
<view class="">{{$t('address')}}:{{item.address}}</view>
|
||||
<view class="">{{$t('customer.Visitcontent')}}:{{item.audio_text}}</view>
|
||||
</view>
|
||||
<view class="">
|
||||
<image :src="item.oss_picture" mode=""></image>
|
||||
</view>
|
||||
</view>
|
||||
<view class="" v-else>
|
||||
<view class="">
|
||||
{{$t('times')}}:{{item.created_at}}
|
||||
</view>
|
||||
<view class="">
|
||||
<image :src="item.oss_picture" mode=""></image>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</u-steps-item>
|
||||
</u-steps>
|
||||
<empty :list="followList"></empty>
|
||||
</view>
|
||||
<view class="zw"></view>
|
||||
<view class="foot">
|
||||
<button class="btn" @click="nextFn">{{$t('mine.restore')}}</button>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { request,showToast } from '@/api/apiT.js'
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
id:'',
|
||||
followList:[],
|
||||
grade_name:'',
|
||||
form: {
|
||||
grade:'',
|
||||
},
|
||||
datas:''
|
||||
|
||||
}
|
||||
},
|
||||
onLoad(options) {
|
||||
console.log(options);
|
||||
this.id = options.id;
|
||||
var that = this
|
||||
this.customerdetailfn()
|
||||
|
||||
},
|
||||
onShow() {
|
||||
this.followlistfn()
|
||||
},
|
||||
methods: {
|
||||
leftClick(){
|
||||
uni.navigateBack({})
|
||||
},
|
||||
gomap(){
|
||||
uni.navigateTo({
|
||||
url: '/pages/customer/map'
|
||||
});
|
||||
},
|
||||
//客户详情
|
||||
customerdetailfn(){
|
||||
var that=this;
|
||||
request({
|
||||
url:'customer/detail',
|
||||
method:'get',
|
||||
data: {
|
||||
id:this.id,
|
||||
}
|
||||
}).then(res => {
|
||||
that.datas = res.data.data
|
||||
that.form = res.data.data
|
||||
})
|
||||
},
|
||||
// 跟进记录
|
||||
followlistfn(){
|
||||
request({
|
||||
url:'follow/list',
|
||||
method:'get',
|
||||
data: {
|
||||
customer_id:this.id,
|
||||
}
|
||||
}).then(res => {
|
||||
this.followList = res.data.data
|
||||
console.log(res.data.data)
|
||||
})
|
||||
},
|
||||
nextFn(){
|
||||
// request({
|
||||
// url:'customer/save',
|
||||
// method:'post',
|
||||
// data:this.form
|
||||
// }).then(res => {
|
||||
// uni.showToast({
|
||||
// title: res.data.message,
|
||||
// icon: 'none'
|
||||
// });
|
||||
// if(res.data.code ==0){
|
||||
// setTimeout(() => {
|
||||
// uni.reLaunch({
|
||||
// url: '/pages/index/customer',// 替换为你要跳转的页面路径
|
||||
// });
|
||||
// }, 1000);
|
||||
// }
|
||||
// })
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
.u-m-lr-10{
|
||||
margin: 0px 10px;
|
||||
}
|
||||
.placeholder {
|
||||
color: #999; /* 占位符颜色 */
|
||||
}
|
||||
textarea {
|
||||
min-height: 200rpx;// 设置默认高度 ,解决设置自适应高度之后高度无效问题
|
||||
margin-top: 15px;
|
||||
background-color: #F6F6F6;
|
||||
padding: 15px;
|
||||
border-radius: 10px;
|
||||
}
|
||||
.red{
|
||||
color: red;
|
||||
}
|
||||
.zw{
|
||||
height: 120px;
|
||||
}
|
||||
.uniui-right{
|
||||
position: absolute;
|
||||
top: 2px;
|
||||
}
|
||||
.cell{
|
||||
position: relative;
|
||||
display: flex;
|
||||
justify-content:space-between;
|
||||
padding: 18px 20px;
|
||||
align-items: center;
|
||||
font-weight: 500;
|
||||
.item{
|
||||
width: 90px;
|
||||
color: #666666;
|
||||
}
|
||||
background: #f6f6f6;
|
||||
border-radius: 10px;
|
||||
}
|
||||
.arrowright{
|
||||
margin-right: -15px;
|
||||
}
|
||||
.right{
|
||||
text-align: right;
|
||||
}
|
||||
.select{
|
||||
display: flex;
|
||||
position: relative;
|
||||
margin-right: 10px;
|
||||
}
|
||||
.content{
|
||||
padding: 10px 15px;
|
||||
background: #FFFFFF;
|
||||
.contents{
|
||||
background-color:#F6F6F6;
|
||||
border-radius: 10px;
|
||||
margin-bottom: 10px;
|
||||
.edt{
|
||||
display: flex;
|
||||
justify-content: right;
|
||||
padding-bottom: 10px;
|
||||
image{
|
||||
width: 14px;
|
||||
height: 14px;
|
||||
margin-right: 5px;
|
||||
vertical-align: middle;
|
||||
}
|
||||
}
|
||||
|
||||
.btn{
|
||||
color: #3471FF;
|
||||
text-align: right;
|
||||
padding: 0px 15px 0px;
|
||||
}
|
||||
.top{
|
||||
padding: 10px 15px 0px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
.tag{
|
||||
color: white;
|
||||
border-radius: 20px 0px 0px 20px;
|
||||
padding: 3px 10px;
|
||||
margin-right: -15px;
|
||||
}
|
||||
.right{
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
}
|
||||
.name{
|
||||
font-size: 32rpx;
|
||||
font-weight: bold;
|
||||
margin-right: 10px;
|
||||
}
|
||||
.cont{
|
||||
padding: 0px 15px 10px;
|
||||
font-size: 24rpx;
|
||||
|
||||
.title{
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
color: #222222;
|
||||
}
|
||||
.ststus{
|
||||
color: #666666;
|
||||
}
|
||||
.info,.desc{
|
||||
color: #78758E;
|
||||
line-height: 26px;
|
||||
}
|
||||
.sex{
|
||||
margin-right: 5px;
|
||||
}
|
||||
.addr{
|
||||
margin-left: 5px;
|
||||
}
|
||||
.type{
|
||||
margin-left: 5px;
|
||||
color: #3471FF;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.steps{
|
||||
padding: 15px;
|
||||
background: #fff;
|
||||
image{
|
||||
width: 44px;
|
||||
height:44px;
|
||||
}
|
||||
.desc{
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
color: #999999;
|
||||
}
|
||||
.title{
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
color: #666666;
|
||||
font-size: 32rpx;
|
||||
margin-bottom: 15px;
|
||||
.status{
|
||||
font-size: 28rpx;
|
||||
margin-left: 10px;
|
||||
}
|
||||
.btnjl{
|
||||
background: linear-gradient(to right, #3471FF, #6776FF);
|
||||
color: white;
|
||||
padding: 4px 10px;
|
||||
border-radius: 20px;
|
||||
font-size: 28rpx;
|
||||
}
|
||||
}
|
||||
}
|
||||
.foot{
|
||||
position: fixed;
|
||||
bottom: 0px;
|
||||
width: 100%;
|
||||
height: 160rpx;
|
||||
background: #FFFFFF;
|
||||
z-index: 1;
|
||||
}
|
||||
.btn{
|
||||
background: linear-gradient(to right, #3471FF, #6776FF);
|
||||
color: white;
|
||||
border-radius: 50px;
|
||||
width: 92%;
|
||||
margin-bottom: 40px;
|
||||
margin: 15px 4%;
|
||||
}
|
||||
</style>
|
||||
+47
-1
@@ -1,5 +1,8 @@
|
||||
<template>
|
||||
<view class="page">
|
||||
<view class="leftback">
|
||||
<u-icon name="arrow-left" color="#000" size="20" @click="leftClick"></u-icon>
|
||||
</view>
|
||||
<view class="title">
|
||||
<image src="/static/image/lingke.png" mode=""></image>
|
||||
</view>
|
||||
@@ -12,6 +15,7 @@
|
||||
<view class="vcode">
|
||||
<u--input
|
||||
type="text"
|
||||
v-model="email"
|
||||
:placeholder="$t('emailinput')"
|
||||
border="none"
|
||||
></u--input>
|
||||
@@ -21,6 +25,7 @@
|
||||
<view class="password">
|
||||
<u--input
|
||||
type="text"
|
||||
v-model="code"
|
||||
:placeholder="$t('code')"
|
||||
border="none"
|
||||
></u--input>
|
||||
@@ -29,6 +34,7 @@
|
||||
<view class="account">
|
||||
<u--input
|
||||
type="password"
|
||||
v-model="password"
|
||||
:placeholder="$t('newpassword')"
|
||||
border="none"
|
||||
></u--input>
|
||||
@@ -36,6 +42,7 @@
|
||||
<view class="password">
|
||||
<u--input
|
||||
type="password"
|
||||
v-model="password1"
|
||||
:placeholder="$t('Confirmpassword')"
|
||||
border="none"
|
||||
></u--input>
|
||||
@@ -58,7 +65,9 @@
|
||||
data() {
|
||||
return {
|
||||
email: "",
|
||||
code: "",
|
||||
password: "",
|
||||
password1: "",
|
||||
pactChecked: false,
|
||||
vcodeTime: 0,
|
||||
vcodeTimer: null
|
||||
@@ -86,8 +95,38 @@
|
||||
});
|
||||
return false
|
||||
}
|
||||
if(this.password != this.password1){
|
||||
uni.showToast({
|
||||
title:this.$t('passworerr1'),
|
||||
icon: 'none'
|
||||
});
|
||||
return false
|
||||
}
|
||||
request({
|
||||
url:'user/savePassword',
|
||||
method:'POST',
|
||||
data:{
|
||||
email: this.email,
|
||||
password: this.password,
|
||||
code: this.code,
|
||||
}
|
||||
}).then(res => {
|
||||
uni.showToast({
|
||||
title: res.data.message,
|
||||
icon: 'none'
|
||||
});
|
||||
if(res.data.code ==0){
|
||||
uni.clearStorageSync();
|
||||
setTimeout(() => {
|
||||
uni.reLaunch({
|
||||
url: '/pages/login/index',// 替换为你要跳转的页面路径
|
||||
});
|
||||
}, 1000);
|
||||
}
|
||||
})
|
||||
},
|
||||
getVcode() {
|
||||
console.log(this.email)
|
||||
if(this.email==''){
|
||||
uni.showToast({
|
||||
title:this.$t('emailerr'),
|
||||
@@ -131,7 +170,14 @@
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
|
||||
.leftback{
|
||||
position: fixed;
|
||||
/* #ifdef APP-PLUS */
|
||||
top: 44px;
|
||||
/* #endif */
|
||||
top: 30px;
|
||||
left: 15px;
|
||||
}
|
||||
.title {
|
||||
padding-top: 220rpx;
|
||||
text-align: center;
|
||||
|
||||
Reference in New Issue
Block a user