2022-03-22 03:38:06 +00:00
|
|
|
|
<template>
|
2022-03-31 02:38:37 +00:00
|
|
|
|
<view class="content arc-content" >
|
2022-03-28 07:33:10 +00:00
|
|
|
|
<statusNav returnColor="#c2c2c2" navBarTitle="客户详情"></statusNav>
|
2022-06-20 01:01:50 +00:00
|
|
|
|
<container-subgroup-two>
|
|
|
|
|
<view slot="content" style="margin: 0 -30rpx;">
|
|
|
|
|
<view class="details-nav">
|
|
|
|
|
<view class="li" @click="essentialInformation('listOne')">
|
|
|
|
|
<image class="icon" src="../../static/iocn/ty.png" mode=""></image>
|
|
|
|
|
<view class="text">基本信息</view>
|
2022-05-20 09:46:27 +00:00
|
|
|
|
</view>
|
2022-06-20 01:01:50 +00:00
|
|
|
|
<view class="li" @click="essentialInformation('listTwo')">
|
|
|
|
|
<image class="icon" src="../../static/iocn/kh.png" mode=""></image>
|
|
|
|
|
<view class="text">联系人</view>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="li" @click="essentialInformation('listThree ')">
|
|
|
|
|
<image class="icon" src="../../static/iocn/xs.png" mode=""></image>
|
|
|
|
|
<view class="text">项目列表</view>
|
2022-05-20 09:46:27 +00:00
|
|
|
|
</view>
|
|
|
|
|
</view>
|
2022-06-20 01:01:50 +00:00
|
|
|
|
<view class="details-content listOne">
|
|
|
|
|
|
|
|
|
|
<view class="title">
|
|
|
|
|
<image class="img" src="../../static/iocn/dn.png" mode=""></image>
|
|
|
|
|
<text class="text">基本信息</text>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="text-content">
|
|
|
|
|
<view class="li clips1" v-for="(item,index) in dataArr" :key="index">
|
|
|
|
|
{{item.name}}:<text class="cor">{{item.value}}</text>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="details-content listTwo">
|
|
|
|
|
<view class="title">
|
|
|
|
|
<image class="img" src="../../static/iocn/lxr.png" mode=""></image>
|
|
|
|
|
<text class="text">联系人</text>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="text-content">
|
|
|
|
|
<view class="li clips1" v-for="(item,index) in contactArr" :key="index">
|
|
|
|
|
{{item.name}}:<text class="cor">{{item.value}}</text>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="project-list listThree">
|
|
|
|
|
<view class="title-content">
|
|
|
|
|
<view class="title">
|
|
|
|
|
<image class="icon" src="../../static/iocn/xmlb.png" mode=""></image>
|
|
|
|
|
<view class="text" style="font-size: 28rpx;">项目列表</view>
|
|
|
|
|
</view>
|
|
|
|
|
<picker :value="currentyear" :range="yearArr" @change="bindTimeChange">
|
|
|
|
|
<view class="date disac" :style="{color: chooseyear ? '#000000' : '#999999',border: chooseyear ? '2rpx solid #000000' : '2rpx solid #999999'}">
|
|
|
|
|
{{chooseyear ? chooseyear+'年' : '选择年份'}} <i class="icon icon-zsj" style="font-size: 18rpx;"></i>
|
|
|
|
|
<!-- <image class="icon flexs" src="../../static/iocn/sjx.png" mode=""></image> -->
|
|
|
|
|
</view>
|
|
|
|
|
</picker>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="project-list-box">
|
|
|
|
|
<view class="project-list-content" v-for="(item,index) in projectList" :key="index">
|
|
|
|
|
<view class="li">
|
|
|
|
|
<view class="text">{{item.project_name}}</view>
|
|
|
|
|
<view class="date">{{item.create_time}}</view>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
<view v-if="!projectList.length" class="disjcac fc" style="height: 120rpx;">
|
|
|
|
|
<pitera textStr="查询无果"></pitera>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="contact-way" @click="copyWxFun()">
|
|
|
|
|
<view class="title">
|
|
|
|
|
客户微信
|
|
|
|
|
</view>
|
|
|
|
|
<image class="icon" src="../../static/iocn/wx.png" mode=""></image>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="contact-way" @click="telFun()">
|
|
|
|
|
<view class="title">
|
|
|
|
|
客户电话
|
|
|
|
|
</view>
|
|
|
|
|
<image class="icon1" src="../../static/iocn/dh.png" mode=""></image>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
</container-subgroup-two>
|
2022-03-22 03:38:06 +00:00
|
|
|
|
</view>
|
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
<script>
|
2022-06-17 07:54:40 +00:00
|
|
|
|
import containerSubgroupTwo from '@/components/containers/container-subgroup-two.vue';
|
2022-03-25 09:12:59 +00:00
|
|
|
|
import statusNav from '../../components/status-nav.vue';
|
2022-04-18 09:08:12 +00:00
|
|
|
|
import {queryDetail} from '@/jsFile/public-api.js';
|
2022-05-20 09:46:27 +00:00
|
|
|
|
import pitera from '@/components/nothing/pitera.vue';
|
2022-03-25 09:12:59 +00:00
|
|
|
|
export default {
|
|
|
|
|
components: {
|
2022-03-25 09:18:08 +00:00
|
|
|
|
statusNav,
|
2022-05-20 09:46:27 +00:00
|
|
|
|
containerSubgroupTwo,
|
|
|
|
|
pitera
|
2022-03-25 09:12:59 +00:00
|
|
|
|
},
|
2022-03-22 03:38:06 +00:00
|
|
|
|
data() {
|
|
|
|
|
return {
|
2022-06-17 07:48:17 +00:00
|
|
|
|
dataArr:[], //基本信息
|
|
|
|
|
contactArr:[], //联系人
|
2022-05-20 09:46:27 +00:00
|
|
|
|
clientId:'',//客户id
|
|
|
|
|
yearArr:[],//年份
|
|
|
|
|
currentyear: '',//当前年份
|
|
|
|
|
chooseyear:'',//选中的年份
|
2022-06-17 07:48:17 +00:00
|
|
|
|
projectList:[],//项目列表
|
|
|
|
|
phone:'', //客户电话
|
|
|
|
|
wechart:'', //客户微信
|
2022-03-22 03:38:06 +00:00
|
|
|
|
}
|
|
|
|
|
},
|
2022-04-18 09:08:12 +00:00
|
|
|
|
onLoad(op){
|
|
|
|
|
if(op.id!=undefined) {
|
|
|
|
|
this.clientId = op.id;
|
|
|
|
|
console.log(this.clientId);
|
|
|
|
|
// 调用查询客户详情信息事件
|
|
|
|
|
this.queryDetailEv();
|
|
|
|
|
}
|
2022-05-20 09:46:27 +00:00
|
|
|
|
let date = new Date();
|
|
|
|
|
this.currentyear = date.getFullYear();
|
|
|
|
|
for (let i = this.currentyear-10; i <= this.currentyear; i++) {
|
|
|
|
|
this.yearArr.push(i);
|
|
|
|
|
}
|
|
|
|
|
// 调用项目列表查询
|
|
|
|
|
this.getProjectList(this.currentyear);
|
2022-04-18 09:08:12 +00:00
|
|
|
|
},
|
2022-03-22 03:38:06 +00:00
|
|
|
|
methods: {
|
2022-04-18 09:08:12 +00:00
|
|
|
|
// 查询客户详情信息
|
|
|
|
|
queryDetailEv(){
|
|
|
|
|
queryDetail({type_id:1,member_id:this.clientId}).then(res=>{
|
2022-06-17 07:48:17 +00:00
|
|
|
|
console.log(res,'客户详情信息')
|
2022-04-18 09:08:12 +00:00
|
|
|
|
if(res.code) {
|
2022-06-17 07:48:17 +00:00
|
|
|
|
res.data.basic_information.forEach(item=>{
|
|
|
|
|
let obj={
|
|
|
|
|
name:item.name,
|
|
|
|
|
value:item.value
|
|
|
|
|
}
|
|
|
|
|
this.dataArr.push(obj)
|
|
|
|
|
})
|
|
|
|
|
res.data.principal.forEach(item=>{
|
|
|
|
|
let obj={
|
|
|
|
|
name:item.name,
|
|
|
|
|
value:item.value
|
|
|
|
|
}
|
|
|
|
|
this.contactArr.push(obj)
|
|
|
|
|
})
|
|
|
|
|
this.wechart = res.data.wechat;
|
|
|
|
|
this.phone = res.data.phone;
|
2022-04-18 09:08:12 +00:00
|
|
|
|
} else {
|
|
|
|
|
this.$toolAll.tools.showToast(res.msg);
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
},
|
2022-03-31 02:38:37 +00:00
|
|
|
|
// 选择年份
|
|
|
|
|
bindTimeChange(data) {
|
2022-05-20 09:46:27 +00:00
|
|
|
|
let index = data.detail.value;
|
|
|
|
|
this.chooseyear = this.yearArr[index];
|
|
|
|
|
// 调用项目列表查询
|
|
|
|
|
this.getProjectList(this.chooseyear);
|
2022-03-31 02:38:37 +00:00
|
|
|
|
},
|
2022-05-20 09:46:27 +00:00
|
|
|
|
// 项目列表查询
|
|
|
|
|
getProjectList(year) {
|
|
|
|
|
this.$requst.post('/universal/api.search/project_year',{year}).then(res=>{
|
|
|
|
|
if(res.code) {
|
|
|
|
|
this.projectList = res.data;
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
},
|
2022-03-31 02:38:37 +00:00
|
|
|
|
essentialInformation(classText){
|
2022-05-20 09:46:27 +00:00
|
|
|
|
uni.createSelectorQuery().select('.'+classText).boundingClientRect(data=>{//目标位置的节点:类或者id
|
|
|
|
|
uni.createSelectorQuery().select(".arc-content").boundingClientRect(res=>{//最外层盒子的节点:类或者id
|
|
|
|
|
uni.pageScrollTo({
|
|
|
|
|
duration: 100,//过渡时间
|
|
|
|
|
scrollTop:data.top - res.top -uni.getSystemInfoSync().statusBarHeight-50,//到达距离顶部的top值
|
|
|
|
|
})
|
|
|
|
|
}).exec()
|
|
|
|
|
}).exec();
|
2022-03-31 02:38:37 +00:00
|
|
|
|
},
|
|
|
|
|
// 复制微信
|
|
|
|
|
copyWxFun(){
|
2022-06-17 07:48:17 +00:00
|
|
|
|
if(this.wechart !== ''){
|
|
|
|
|
uni.setClipboardData({
|
|
|
|
|
data: this.wechart,
|
|
|
|
|
success: function () {}
|
|
|
|
|
});
|
|
|
|
|
}else{
|
|
|
|
|
this.$toolAll.tools.showToast('客户微信号为空');
|
|
|
|
|
}
|
|
|
|
|
|
2022-05-20 09:46:27 +00:00
|
|
|
|
},
|
|
|
|
|
// 拨打电话
|
|
|
|
|
telFun(){
|
2022-06-17 07:48:17 +00:00
|
|
|
|
if(this.phone !== ''){
|
|
|
|
|
uni.makePhoneCall({
|
|
|
|
|
phoneNumber: this.phone
|
|
|
|
|
});
|
|
|
|
|
}else{
|
|
|
|
|
this.$toolAll.tools.showToast('客户电话号为空');
|
|
|
|
|
}
|
2022-05-20 09:46:27 +00:00
|
|
|
|
}
|
2022-03-22 03:38:06 +00:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
</script>
|
|
|
|
|
|
|
|
|
|
<style>
|
2022-05-20 09:46:27 +00:00
|
|
|
|
.project-list-box {
|
|
|
|
|
min-height: 120rpx;
|
|
|
|
|
max-height: 520rpx;
|
|
|
|
|
overflow: hidden;
|
|
|
|
|
overflow-y: scroll;
|
|
|
|
|
}
|
|
|
|
|
.project-list-box::-webkit-scrollbar{
|
|
|
|
|
display: none;
|
|
|
|
|
}
|
2022-03-22 03:38:06 +00:00
|
|
|
|
.content {
|
|
|
|
|
padding-right: 27rpx;
|
|
|
|
|
padding-left: 27rpx;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.details-nav {
|
|
|
|
|
display: flex;
|
|
|
|
|
justify-content: space-between;
|
|
|
|
|
padding: 23rpx 63rpx;
|
|
|
|
|
background-color: #FFFFFF;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.details-nav .li .icon {
|
|
|
|
|
width: 79rpx;
|
|
|
|
|
height: 79rpx;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.details-nav .li {
|
|
|
|
|
text-align: center;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.details-nav .li .text {
|
|
|
|
|
font-size: 24rpx;
|
|
|
|
|
color: #333333;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.details-content {
|
|
|
|
|
margin-top: 20rpx;
|
|
|
|
|
background-color: #FFFFFF;
|
|
|
|
|
padding: 20rpx 18rpx;
|
|
|
|
|
border-bottom: 2rpx solid #DFDFDF;
|
2022-03-25 09:12:59 +00:00
|
|
|
|
border-radius: 0rpx 0rpx 10rpx 10rpx;
|
2022-03-22 03:38:06 +00:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.details-content .title {
|
|
|
|
|
display: flex;
|
|
|
|
|
align-items: center;
|
|
|
|
|
padding-bottom: 15rpx;
|
|
|
|
|
border-bottom: 2rpx solid #E5E5E5;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.details-content .title .img {
|
|
|
|
|
width: 27rpx;
|
|
|
|
|
height: 26rpx;
|
|
|
|
|
margin-right: 9rpx;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.details-content .title .text {
|
|
|
|
|
font-size: 28rpx;
|
|
|
|
|
color: #999999;
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.text-content {
|
|
|
|
|
display: flex;
|
|
|
|
|
flex-wrap: wrap;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.text-content .li {
|
|
|
|
|
width: 50%;
|
|
|
|
|
font-size: 24rpx;
|
|
|
|
|
color: #999999;
|
|
|
|
|
margin-top: 22rpx;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.cor {
|
|
|
|
|
color: #333333;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.cor1 {
|
|
|
|
|
color: #FF4C4C;
|
|
|
|
|
}
|
2022-03-25 09:12:59 +00:00
|
|
|
|
|
|
|
|
|
.project-list {
|
2022-03-22 03:38:06 +00:00
|
|
|
|
background-color: #FFFFFF;
|
|
|
|
|
padding: 22rpx 18rpx;
|
|
|
|
|
margin-top: 20rpx;
|
|
|
|
|
}
|
2022-03-25 09:12:59 +00:00
|
|
|
|
|
|
|
|
|
.project-list .title-content {
|
2022-03-22 03:38:06 +00:00
|
|
|
|
display: flex;
|
|
|
|
|
justify-content: space-between;
|
2022-03-22 10:10:39 +00:00
|
|
|
|
padding-bottom: 16rpx;
|
2022-03-22 03:38:06 +00:00
|
|
|
|
font-size: 24rpx;
|
2022-03-25 09:12:59 +00:00
|
|
|
|
border-bottom: 2rpx solid #E5E5E5;
|
2022-03-22 03:38:06 +00:00
|
|
|
|
color: #999999;
|
|
|
|
|
}
|
2022-03-25 09:12:59 +00:00
|
|
|
|
|
|
|
|
|
.project-list .title-content .title {
|
2022-03-22 03:38:06 +00:00
|
|
|
|
display: flex;
|
|
|
|
|
align-items: center;
|
|
|
|
|
}
|
2022-03-25 09:12:59 +00:00
|
|
|
|
|
|
|
|
|
.project-list .title-content .title .icon {
|
2022-03-22 03:38:06 +00:00
|
|
|
|
width: 23rpx;
|
|
|
|
|
height: 25rpx;
|
|
|
|
|
margin-right: 10rpx;
|
|
|
|
|
}
|
2022-03-25 09:12:59 +00:00
|
|
|
|
|
|
|
|
|
.project-list .title-content .date {
|
|
|
|
|
height: 40rpx;
|
2022-04-01 10:16:43 +00:00
|
|
|
|
padding: 2rpx 10rpx;
|
2022-03-25 09:12:59 +00:00
|
|
|
|
display: flex;
|
|
|
|
|
justify-content: center;
|
|
|
|
|
align-items: center;
|
|
|
|
|
border-radius: 10rpx;
|
|
|
|
|
font-size: 24rpx;
|
|
|
|
|
display: flex;
|
2022-03-22 03:38:06 +00:00
|
|
|
|
align-items: center;
|
|
|
|
|
}
|
2022-03-25 09:12:59 +00:00
|
|
|
|
|
|
|
|
|
.project-list .title-content .date .icon {
|
2022-05-20 09:46:27 +00:00
|
|
|
|
/* width: 12rpx;
|
|
|
|
|
height: 12rpx; */
|
2022-03-22 03:38:06 +00:00
|
|
|
|
margin-left: 5rpx;
|
|
|
|
|
}
|
2022-03-25 09:12:59 +00:00
|
|
|
|
|
|
|
|
|
.project-list-content .li {
|
2022-03-22 03:38:06 +00:00
|
|
|
|
display: flex;
|
|
|
|
|
justify-content: space-between;
|
2022-03-22 10:10:39 +00:00
|
|
|
|
border-bottom: 2rpx solid #E5E5E5;
|
2022-03-22 03:43:04 +00:00
|
|
|
|
padding: 18rpx;
|
2022-03-22 03:38:06 +00:00
|
|
|
|
}
|
2022-03-25 09:12:59 +00:00
|
|
|
|
|
|
|
|
|
.project-list-content .li .text {
|
2022-03-22 10:10:39 +00:00
|
|
|
|
font-weight: bold;
|
|
|
|
|
color: #4ca5ff;
|
|
|
|
|
font-size: 24rpx
|
|
|
|
|
}
|
2022-03-25 09:12:59 +00:00
|
|
|
|
|
|
|
|
|
.project-list-content .li .date {
|
2022-03-22 10:10:39 +00:00
|
|
|
|
color: #888888;
|
|
|
|
|
font-size: 24rpx
|
|
|
|
|
}
|
2022-03-25 09:12:59 +00:00
|
|
|
|
|
|
|
|
|
.contact-way {
|
2022-03-22 10:10:39 +00:00
|
|
|
|
display: flex;
|
|
|
|
|
align-items: center;
|
|
|
|
|
padding: 40rpx 20rpx 34rpx;
|
|
|
|
|
color: #696666;
|
|
|
|
|
justify-content: space-between;
|
|
|
|
|
font-size: 28rpx;
|
2022-03-25 09:12:59 +00:00
|
|
|
|
border-bottom: 2rpx solid #E5E5E5;
|
2022-03-22 10:10:39 +00:00
|
|
|
|
}
|
2022-03-25 09:12:59 +00:00
|
|
|
|
|
|
|
|
|
.contact-way .icon {
|
2022-03-22 10:10:39 +00:00
|
|
|
|
width: 41rpx;
|
|
|
|
|
height: 32rpx;
|
|
|
|
|
}
|
2022-03-25 09:12:59 +00:00
|
|
|
|
|
|
|
|
|
.contact-way .icon1 {
|
2022-03-22 10:10:39 +00:00
|
|
|
|
width: 35rpx;
|
|
|
|
|
height: 39rpx;
|
|
|
|
|
}
|
2022-03-22 03:38:06 +00:00
|
|
|
|
</style>
|