Browse Source

客户多选

Jyt
jyt 2 years ago
parent
commit
208a26aeb3
4 changed files with 100 additions and 40 deletions
  1. +25
    -23
      pages/center/consumer/edit.vue
  2. +59
    -15
      pages/index/consumer/index.vue
  3. +1
    -1
      pages/index/learning.vue
  4. +15
    -1
      pages/learning/Equinoctial/index.vue

+ 25
- 23
pages/center/consumer/edit.vue View File

@@ -38,9 +38,9 @@
<view class="conmsg-msg-lab"> <view class="conmsg-msg-lab">
<view class="conmsg-msg-lab-1"> <view class="conmsg-msg-lab-1">
联系电话 联系电话
<view class="star">
<!-- <view class="star">
* *
</view>
</view> -->
</view> </view>
<view class="conmsg-msg-lab-inp"> <view class="conmsg-msg-lab-inp">
<input :disabled="userInfo.showPhoneStatus != 0" type="number" placeholder="请输入联系电话" <input :disabled="userInfo.showPhoneStatus != 0" type="number" placeholder="请输入联系电话"
@@ -232,6 +232,7 @@
id: this.customerId id: this.customerId
}) })
.then(res => { .then(res => {
res.phone = res.phone || ''
this.form = res this.form = res
if (this.userInfo.showPhoneStatus == 1) { if (this.userInfo.showPhoneStatus == 1) {
this.showPhone = this.form.phone this.showPhone = this.form.phone
@@ -282,13 +283,14 @@
}) })
return return
} }
if (this.form.phone == '') {
uni.showToast({
title: '请输入手机号',
icon: 'none'
})
return
}
// if (this.form.phone == '') {
// uni.showToast({
// title: '请输入手机号',
// icon: 'none'
// })
// return
// }
// if(!(/^1[3456789]\d{9}$/.test(this.form.phone))){ // if(!(/^1[3456789]\d{9}$/.test(this.form.phone))){
// uni.showToast({ // uni.showToast({
// title: "请检查手机号码格式", // title: "请检查手机号码格式",
@@ -297,20 +299,20 @@
// // this.form.phone='' // // this.form.phone=''
// return false; // return false;
// } // }
if (this.form.phone.length < 5) {
uni.showToast({
icon: "none",
title: "手机号码不能小于5位"
})
return;
}
if (this.form.phone.length > 11) {
uni.showToast({
icon: "none",
title: "手机号码不能大于11位"
})
return;
}
// if (this.form.phone.length < 5) {
// uni.showToast({
// icon: "none",
// title: "手机号码不能小于5位"
// })
// return;
// }
// if (this.form.phone.length > 11) {
// uni.showToast({
// icon: "none",
// title: "手机号码不能大于11位"
// })
// return;
// }


this.allList.map(item => { this.allList.map(item => {
item.children.map(item1 => { item.children.map(item1 => {


+ 59
- 15
pages/index/consumer/index.vue View File

@@ -126,7 +126,13 @@
客户等级 客户等级
</view> </view>
<view class="screen-record-tab"> <view class="screen-record-tab">
<view :class="[screen.record==0?'screen-record-chose':'screen-record-nochose']"
<block v-for="(item,index) in levelList" :key="index">
<view :class="[item.isShow?'screen-record-chose':'screen-record-nochose']"
@click="choiceLevel(index,item.value)">
{{item.label}}
</view>
</block>
<!-- <view :class="[screen.record==0?'screen-record-chose':'screen-record-nochose']"
@click="recordclick(0)"> @click="recordclick(0)">
A A
</view> </view>
@@ -141,7 +147,7 @@
<view :class="[screen.record==3?'screen-record-chose':'screen-record-nochose']" <view :class="[screen.record==3?'screen-record-chose':'screen-record-nochose']"
@click="recordclick(3)"> @click="recordclick(3)">
D D
</view>
</view> -->
</view> </view>
</view> </view>
<!-- 客户来源 --> <!-- 客户来源 -->
@@ -250,6 +256,7 @@
<u-tabbar :mid-button="true" activeColor="#1296db" inactiveColor="#999999" v-model="current" :list="tabbarList"> <u-tabbar :mid-button="true" activeColor="#1296db" inactiveColor="#999999" v-model="current" :list="tabbarList">
</u-tabbar> </u-tabbar>
</view> </view>

</template> </template>


<script> <script>
@@ -305,7 +312,7 @@
agentId: '', agentId: '',
agentIdtext: '', agentIdtext: '',
visitRecord: [], visitRecord: [],
record: null,
record: [],
cunsumerTips: '', cunsumerTips: '',
cunsumerTipsid: '' cunsumerTipsid: ''
}, },
@@ -362,6 +369,23 @@
value: 4, value: 4,
isShow: false, isShow: false,
}, ], }, ],
levelList: [{
label: 'A',
value: 0,
isShow: false,
}, {
label: 'B',
value: 1,
isShow: false,
}, {
label: 'C',
value: 2,
isShow: false,
}, {
label: 'D',
value: 3,
isShow: false,
}, ],
isRefresh:false isRefresh:false
} }
}, },
@@ -523,6 +547,19 @@
this.screen.visitRecord.push(e) this.screen.visitRecord.push(e)
} }
}, },
choiceLevel(index,e) {
if (this.levelList[index].isShow == true) {
this.levelList[index].isShow = false;
for (var i = 0; i < this.screen.record.length; i++) {
if (this.screen.record[i] === e) {
this.screen.record.splice(i, 1);
}
}
} else {
this.levelList[index].isShow = true;
this.screen.record.push(e)
}
},
screenvisitRecord(i) { screenvisitRecord(i) {
if (this.screen.visitRecord == i) { if (this.screen.visitRecord == i) {
this.screen.visitRecord = '' this.screen.visitRecord = ''
@@ -580,17 +617,20 @@
if (this.screen.visitRecord.length > 0) { if (this.screen.visitRecord.length > 0) {
parames.query.visitRecords = this.screen.visitRecord.join(','); parames.query.visitRecords = this.screen.visitRecord.join(',');
} }
if (this.screen.record == 0) {
parames.query.levels = ["1"]
} else if (this.screen.record == 1) {
parames.query.levels = ["2"]
} else if (this.screen.record == 2) {
parames.query.levels = ["3"]
} else if (this.screen.record == 3) {
parames.query.levels = ["4"]
} else {
parames.query.levels = null
if (this.screen.record.length > 0) {
parames.query.level = this.screen.record.join(',');
} }
// if (this.screen.record == 0) {
// parames.query.levels = ["1"]
// } else if (this.screen.record == 1) {
// parames.query.levels = ["2"]
// } else if (this.screen.record == 2) {
// parames.query.levels = ["3"]
// } else if (this.screen.record == 3) {
// parames.query.levels = ["4"]
// } else {
// parames.query.levels = null
// }
this.$u.post("/customer/customerManagement", parames).then(data => { this.$u.post("/customer/customerManagement", parames).then(data => {
if(this.staTime && this.endtime) { if(this.staTime && this.endtime) {
@@ -665,13 +705,17 @@
agentId: '', agentId: '',
agentIdtext: '', agentIdtext: '',
visitRecord: '', visitRecord: '',
record: null,
record: [],
cunsumerTips: '', cunsumerTips: '',
cunsumerTipsid: ''
cunsumerTipsid: '',
level:''
} }
this.visitList.map(i=>{ this.visitList.map(i=>{
i.isShow = false i.isShow = false
}) })
this.levelList.map(i=>{
i.isShow = false
})
this.nextPage = 1; this.nextPage = 1;
this.recordList = []; this.recordList = [];
// this.screenShow = false; // this.screenShow = false;


+ 1
- 1
pages/index/learning.vue View File

@@ -81,7 +81,7 @@
<view class="infozuochiud1">{{item.jbaName}}</view> <view class="infozuochiud1">{{item.jbaName}}</view>
</view> </view>
<view class="infoyou"> <view class="infoyou">
<view class="infoyouchiud2">未学习</view>
<view class="infoyouchiud2">{{item.studyStatus}}</view>
</view> </view>
</view> </view>
<view class="footerinfo"> <view class="footerinfo">


+ 15
- 1
pages/learning/Equinoctial/index.vue View File

@@ -214,7 +214,8 @@
biaoqianyaisshow:false, biaoqianyaisshow:false,
startFile:'', startFile:'',
num: 0, //上拉 转写文件下标 num: 0, //上拉 转写文件下标
Bnum: 0, //下拉 转写文件下标
Bnum: 0, //下拉 转写文件下标,
timer:null
}; };
}, },
onLoad: function(options) { onLoad: function(options) {
@@ -226,6 +227,10 @@
this.getdianzan() this.getdianzan()
this.getCommentList(); this.getCommentList();
this.getView() this.getView()
let that=this
this.timer=setTimeout(function(){
that.addHot()
},30000)
}, },
onShow: function() { onShow: function() {
this.initRecord(); this.initRecord();
@@ -251,6 +256,15 @@
this.innerAudioContext.destroy(); this.innerAudioContext.destroy();
}, },
methods: { methods: {
addHot(){
// console.log('30')
this.$u.post('/zkstudyrecord',{
targetId: this.customerId
})
.then(res=>{
// console.log(res)
})
},
getView(){ getView(){
this.$u.get('/addtodigest/addPageviews',{ this.$u.get('/addtodigest/addPageviews',{
id:this.customerId id:this.customerId


Loading…
Cancel
Save