|
@@ -5,7 +5,7 @@
|
|
|
<view class="search-input ddflex fflex">
|
|
<view class="search-input ddflex fflex">
|
|
|
<image src="/static/images/ssico.png"></image>
|
|
<image src="/static/images/ssico.png"></image>
|
|
|
<input @confirm="searchFn" confirm-type="search" @input="searchFn" v-model="searchVal" class="fflex"
|
|
<input @confirm="searchFn" confirm-type="search" @input="searchFn" v-model="searchVal" class="fflex"
|
|
|
- placeholder="请输入关键词" />
|
|
|
|
|
|
|
+ placeholder="请输入客户昵称" />
|
|
|
</view>
|
|
</view>
|
|
|
</view>
|
|
</view>
|
|
|
<view class="filter ddflex">
|
|
<view class="filter ddflex">
|
|
@@ -58,10 +58,17 @@
|
|
|
<view class="flex" style="min-width: 0;">
|
|
<view class="flex" style="min-width: 0;">
|
|
|
<view class="ddflex">
|
|
<view class="ddflex">
|
|
|
<view class="card-name fflex tover">{{item.nickName?item.nickName:''}}</view>
|
|
<view class="card-name fflex tover">{{item.nickName?item.nickName:''}}</view>
|
|
|
|
|
+ <view v-if="item.mobile">
|
|
|
|
|
+ <image style="width: 140rpx;height: 64rpx;margin-left: 20rpx;" src="/mine/static/images/lx.png" @click.stop="goPhone(item.mobile)"></image>
|
|
|
|
|
+ </view>
|
|
|
</view>
|
|
</view>
|
|
|
<view class="ddflex" style="margin-top: 4rpx;">
|
|
<view class="ddflex" style="margin-top: 4rpx;">
|
|
|
- <view class="card-tag">客户</view>
|
|
|
|
|
- <view class="card-tag">高价值</view>
|
|
|
|
|
|
|
+ <block v-if="item.customTypeName&&item.customTypeName.length>0">
|
|
|
|
|
+ <view class="card-tag" v-for="it,idx in item.customTypeName" :key="idx+'s'">{{it}}</view>
|
|
|
|
|
+ </block>
|
|
|
|
|
+ <block v-if="item.labelName&&item.labelName.length>0">
|
|
|
|
|
+ <view class="card-tag card-tag-t" v-for="it,idx in item.labelName" :key="idx+'l'">{{it}}</view>
|
|
|
|
|
+ </block>
|
|
|
</view>
|
|
</view>
|
|
|
<view class="ddflex" style="font-size: 24rpx;color: #999;font-weight: 400;margin: 20rpx 0;">
|
|
<view class="ddflex" style="font-size: 24rpx;color: #999;font-weight: 400;margin: 20rpx 0;">
|
|
|
<text>保单</text><text style="color: #000000;">{{item.warrantyCount?item.warrantyCount:0}}</text>
|
|
<text>保单</text><text style="color: #000000;">{{item.warrantyCount?item.warrantyCount:0}}</text>
|
|
@@ -70,7 +77,7 @@
|
|
|
</view>
|
|
</view>
|
|
|
</view>
|
|
</view>
|
|
|
</view>
|
|
</view>
|
|
|
- <view class="ddflex" style="margin-top: 41rpx;font-size: 24rpx;padding: 0 30rpx;">
|
|
|
|
|
|
|
+ <!-- <view class="ddflex" style="margin-top: 41rpx;font-size: 24rpx;padding: 0 30rpx;">
|
|
|
<view class="ddflex fflex">
|
|
<view class="ddflex fflex">
|
|
|
<view style="color: #999;margin-right: 16rpx;">服务策略</view>
|
|
<view style="color: #999;margin-right: 16rpx;">服务策略</view>
|
|
|
<view style="color: #333333;">刺激消费频率</view>
|
|
<view style="color: #333333;">刺激消费频率</view>
|
|
@@ -78,7 +85,7 @@
|
|
|
<view v-if="item.mobile">
|
|
<view v-if="item.mobile">
|
|
|
<image style="width: 140rpx;height: 64rpx;margin-left: 20rpx;" src="/mine/static/images/lx.png" @click.stop="goPhone(item.mobile)"></image>
|
|
<image style="width: 140rpx;height: 64rpx;margin-left: 20rpx;" src="/mine/static/images/lx.png" @click.stop="goPhone(item.mobile)"></image>
|
|
|
</view>
|
|
</view>
|
|
|
- </view>
|
|
|
|
|
|
|
+ </view> -->
|
|
|
</view>
|
|
</view>
|
|
|
</view>
|
|
</view>
|
|
|
<view v-else class="nodata">
|
|
<view v-else class="nodata">
|
|
@@ -120,8 +127,12 @@
|
|
|
},
|
|
},
|
|
|
]
|
|
]
|
|
|
},{
|
|
},{
|
|
|
|
|
+ title:'客户类型',
|
|
|
|
|
+ key:'custom_type',
|
|
|
|
|
+ option:[]
|
|
|
|
|
+ },{
|
|
|
title:'客户标签',
|
|
title:'客户标签',
|
|
|
- key:'job',
|
|
|
|
|
|
|
+ key:'custom_label',
|
|
|
option:[
|
|
option:[
|
|
|
{
|
|
{
|
|
|
label: '经理',
|
|
label: '经理',
|
|
@@ -144,21 +155,22 @@
|
|
|
value: null
|
|
value: null
|
|
|
},{
|
|
},{
|
|
|
label: '保费从高到低',
|
|
label: '保费从高到低',
|
|
|
- value: 'avage'
|
|
|
|
|
|
|
+ value: 'warranty_money',
|
|
|
|
|
+ behavior:'desc'
|
|
|
},
|
|
},
|
|
|
{
|
|
{
|
|
|
label: '保费从低到高',
|
|
label: '保费从低到高',
|
|
|
- value: 'bCount',
|
|
|
|
|
- behavior:4
|
|
|
|
|
|
|
+ value: 'warranty_money',
|
|
|
|
|
+ behavior:'asc'
|
|
|
},
|
|
},
|
|
|
{
|
|
{
|
|
|
label: '保单从高到低',
|
|
label: '保单从高到低',
|
|
|
- value: 'bCount',
|
|
|
|
|
- behavior:3
|
|
|
|
|
|
|
+ value: 'warranty_count',
|
|
|
|
|
+ behavior:'desc'
|
|
|
},{
|
|
},{
|
|
|
label: '保单从低到高',
|
|
label: '保单从低到高',
|
|
|
- value: 'bCount',
|
|
|
|
|
- behavior:3
|
|
|
|
|
|
|
+ value: 'warranty_count',
|
|
|
|
|
+ behavior:'asc'
|
|
|
}],
|
|
}],
|
|
|
page: 1,
|
|
page: 1,
|
|
|
limit: 10,
|
|
limit: 10,
|
|
@@ -170,6 +182,7 @@
|
|
|
},
|
|
},
|
|
|
async onLoad(options) {
|
|
async onLoad(options) {
|
|
|
await this.getDict()
|
|
await this.getDict()
|
|
|
|
|
+ await this.getDictCustomType()
|
|
|
this.getDataList()
|
|
this.getDataList()
|
|
|
},
|
|
},
|
|
|
onShow() {
|
|
onShow() {
|
|
@@ -190,11 +203,31 @@
|
|
|
url: url
|
|
url: url
|
|
|
})
|
|
})
|
|
|
},
|
|
},
|
|
|
|
|
+ // 客户标签字典
|
|
|
getDict(){
|
|
getDict(){
|
|
|
return new Promise((r,j)=>{
|
|
return new Promise((r,j)=>{
|
|
|
- req.getRequest('/api/other/dict/info',{dictType:'job'},res=>{
|
|
|
|
|
|
|
+ req.getRequest('/api/other/dict/info',{dictType:'custom_label'},res=>{
|
|
|
|
|
+ this.dateList.map(item=>{
|
|
|
|
|
+ if(item.key=='custom_label'){
|
|
|
|
|
+ item.option = []
|
|
|
|
|
+ res.map(it=>{
|
|
|
|
|
+ item.option.push({
|
|
|
|
|
+ label:it.dictName,
|
|
|
|
|
+ value:it.dictValue
|
|
|
|
|
+ })
|
|
|
|
|
+ })
|
|
|
|
|
+ }
|
|
|
|
|
+ })
|
|
|
|
|
+ r(res)
|
|
|
|
|
+ })
|
|
|
|
|
+ })
|
|
|
|
|
+ },
|
|
|
|
|
+ // 客户类型字典
|
|
|
|
|
+ getDictCustomType(){
|
|
|
|
|
+ return new Promise((r,j)=>{
|
|
|
|
|
+ req.getRequest('/api/other/dict/info',{dictType:'custom_type'},res=>{
|
|
|
this.dateList.map(item=>{
|
|
this.dateList.map(item=>{
|
|
|
- if(item.key=='job'){
|
|
|
|
|
|
|
+ if(item.key=='custom_type'){
|
|
|
item.option = []
|
|
item.option = []
|
|
|
res.map(it=>{
|
|
res.map(it=>{
|
|
|
item.option.push({
|
|
item.option.push({
|
|
@@ -236,19 +269,30 @@
|
|
|
this.confirm()
|
|
this.confirm()
|
|
|
},
|
|
},
|
|
|
switchFilterType(index,idx) {
|
|
switchFilterType(index,idx) {
|
|
|
- if(!this.dateList[index].option[idx].isActive){
|
|
|
|
|
- this.dateList[index].option.map(item=>{
|
|
|
|
|
- item.isActive = false
|
|
|
|
|
- })
|
|
|
|
|
- this.dateList[index].option[idx].isActive = true
|
|
|
|
|
|
|
+ // 可多选
|
|
|
|
|
+ if(this.dateList[index].key=='custom_label' || this.dateList[index].key=='custom_type'){
|
|
|
|
|
+ if(!this.dateList[index].option[idx].isActive){
|
|
|
|
|
+ this.dateList[index].option[idx].isActive = true
|
|
|
|
|
+ }else{
|
|
|
|
|
+ this.dateList[index].option[idx].isActive = false
|
|
|
|
|
+ }
|
|
|
}else{
|
|
}else{
|
|
|
- this.dateList[index].option[idx].isActive = false
|
|
|
|
|
|
|
+ if(!this.dateList[index].option[idx].isActive){
|
|
|
|
|
+ this.dateList[index].option.map(item=>{
|
|
|
|
|
+ item.isActive = false
|
|
|
|
|
+ })
|
|
|
|
|
+ this.dateList[index].option[idx].isActive = true
|
|
|
|
|
+ }else{
|
|
|
|
|
+ this.dateList[index].option[idx].isActive = false
|
|
|
|
|
+ }
|
|
|
}
|
|
}
|
|
|
this.dateList = JSON.parse(JSON.stringify(this.dateList))
|
|
this.dateList = JSON.parse(JSON.stringify(this.dateList))
|
|
|
},
|
|
},
|
|
|
confirm() {
|
|
confirm() {
|
|
|
this.hidePop();
|
|
this.hidePop();
|
|
|
this.isLoad = true;
|
|
this.isLoad = true;
|
|
|
|
|
+ this.page=1;
|
|
|
|
|
+ this.isLoad = true
|
|
|
this.getDataList();
|
|
this.getDataList();
|
|
|
},
|
|
},
|
|
|
reset() {
|
|
reset() {
|
|
@@ -272,23 +316,14 @@
|
|
|
longitude: this.longitude,
|
|
longitude: this.longitude,
|
|
|
}
|
|
}
|
|
|
if (this.searchVal) {
|
|
if (this.searchVal) {
|
|
|
- queryParams.realName = this.searchVal
|
|
|
|
|
- }
|
|
|
|
|
- // 筛选
|
|
|
|
|
- if (this.dateIndex != -1) {
|
|
|
|
|
- queryParams.dateType = this.dateList[this.dateIndex].value;
|
|
|
|
|
- }else if (this.dateIndex == -1) {
|
|
|
|
|
- } else {
|
|
|
|
|
- queryParams.dateType = 8
|
|
|
|
|
- queryParams.end = this.endTime?this.endTime:null;
|
|
|
|
|
- queryParams.start = this.startTime?this.startTime:null;
|
|
|
|
|
|
|
+ queryParams.nickName = this.searchVal
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
// 状态筛选
|
|
// 状态筛选
|
|
|
if (this.stateIndex != -1) {
|
|
if (this.stateIndex != -1) {
|
|
|
- queryParams.orderFiled = this.stateList[this.stateIndex].value;
|
|
|
|
|
|
|
+ queryParams.orderField = this.stateList[this.stateIndex].value;
|
|
|
if(this.stateList[this.stateIndex].behavior){
|
|
if(this.stateList[this.stateIndex].behavior){
|
|
|
- queryParams.behavior = this.stateList[this.stateIndex].behavior;
|
|
|
|
|
|
|
+ queryParams.order = this.stateList[this.stateIndex].behavior;
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
this.dateList.map(item=>{
|
|
this.dateList.map(item=>{
|
|
@@ -298,10 +333,17 @@
|
|
|
queryParams.gender = sl[0].value
|
|
queryParams.gender = sl[0].value
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
- if(item.key=="job"){
|
|
|
|
|
|
|
+ if(item.key=="custom_label"){
|
|
|
let jl = item.option.filter(it=>{return it.isActive})
|
|
let jl = item.option.filter(it=>{return it.isActive})
|
|
|
if(jl.length>0){
|
|
if(jl.length>0){
|
|
|
- queryParams.job = jl[0].value
|
|
|
|
|
|
|
+ // queryParams.label = jl[0].value
|
|
|
|
|
+ queryParams.label = jl.map(item => {return item.value}).join(',')
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+ if(item.key=="custom_type"){
|
|
|
|
|
+ let tl = item.option.filter(it=>{return it.isActive})
|
|
|
|
|
+ if(tl.length>0){
|
|
|
|
|
+ queryParams.type = tl.map(item => {return item.value}).join(',')
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
})
|
|
})
|
|
@@ -324,6 +366,7 @@
|
|
|
searchFn() {
|
|
searchFn() {
|
|
|
this.page = 1;
|
|
this.page = 1;
|
|
|
this.isLoad = true;
|
|
this.isLoad = true;
|
|
|
|
|
+ this.page=1;
|
|
|
this.getDataList();
|
|
this.getDataList();
|
|
|
},
|
|
},
|
|
|
// 拨打电话
|
|
// 拨打电话
|