修改页面
This commit is contained in:
@@ -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>
|
||||
Reference in New Issue
Block a user