添加个微
This commit is contained in:
@@ -135,7 +135,7 @@ api = {
|
|||||||
appGoodsRemind:'app/goods/remind', //库存提醒/预警
|
appGoodsRemind:'app/goods/remind', //库存提醒/预警
|
||||||
appGoodsLists:'app/goods/lists', //库存列表
|
appGoodsLists:'app/goods/lists', //库存列表
|
||||||
|
|
||||||
appCustomersOffline_sources:'app/customers/offline_sources', //线索来源
|
appCustomersOffline_sources:'app/customers/offline_sources', //客户来源
|
||||||
appCustomersTag:'app/customers/tag', //客户标签
|
appCustomersTag:'app/customers/tag', //客户标签
|
||||||
|
|
||||||
appCityOncard:'app/city/oncard', //获取上牌城市
|
appCityOncard:'app/city/oncard', //获取上牌城市
|
||||||
|
|||||||
@@ -797,7 +797,7 @@ apiQuery.getAppGoodsLists = function (params) {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
//线索来源
|
//客户来源
|
||||||
apiQuery.getAppCustomersOffline_sources = function (params) {
|
apiQuery.getAppCustomersOffline_sources = function (params) {
|
||||||
return new Promise(function (resolve, reject) {
|
return new Promise(function (resolve, reject) {
|
||||||
HttpRequest(false, Config.api.appCustomersOffline_sources, 2, params, "GET", resolve, reject)
|
HttpRequest(false, Config.api.appCustomersOffline_sources, 2, params, "GET", resolve, reject)
|
||||||
|
|||||||
@@ -37,6 +37,7 @@ Page({
|
|||||||
county_id:'',
|
county_id:'',
|
||||||
|
|
||||||
isShowExist:false, //客户是否已存在
|
isShowExist:false, //客户是否已存在
|
||||||
|
wxgr:0,//是否添加个微
|
||||||
},
|
},
|
||||||
//生命周期函数--监听页面加载
|
//生命周期函数--监听页面加载
|
||||||
onLoad: function (options) {
|
onLoad: function (options) {
|
||||||
@@ -49,7 +50,7 @@ Page({
|
|||||||
// this.getAppSeriesBrands()
|
// this.getAppSeriesBrands()
|
||||||
//获取列表筛选条件-时间
|
//获取列表筛选条件-时间
|
||||||
this.getAppCustomersFilter()
|
this.getAppCustomersFilter()
|
||||||
//线索来源
|
//客户来源
|
||||||
this.getAppCustomersOffline_sources()
|
this.getAppCustomersOffline_sources()
|
||||||
//客户标签
|
//客户标签
|
||||||
this.getAppCustomersTag()
|
this.getAppCustomersTag()
|
||||||
@@ -280,7 +281,7 @@ Page({
|
|||||||
}
|
}
|
||||||
else if (that.data.sources.length>0&&that.data.of_id == '' ) {
|
else if (that.data.sources.length>0&&that.data.of_id == '' ) {
|
||||||
wx.showToast({
|
wx.showToast({
|
||||||
title: '请选择线索来源',
|
title: '请选择客户来源',
|
||||||
icon: 'none'
|
icon: 'none'
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@@ -345,6 +346,7 @@ Page({
|
|||||||
if(this.data.of2_id != ''){
|
if(this.data.of2_id != ''){
|
||||||
params['of2_id'] = this.data.of2_id;
|
params['of2_id'] = this.data.of2_id;
|
||||||
}
|
}
|
||||||
|
params['wxgr'] = this.data.wxgr;
|
||||||
params['city_id'] = this.data.city_id;
|
params['city_id'] = this.data.city_id;
|
||||||
params['county_id'] = this.data.county_id;
|
params['county_id'] = this.data.county_id;
|
||||||
params['buy_time'] = this.data.buy_time;
|
params['buy_time'] = this.data.buy_time;
|
||||||
@@ -419,7 +421,7 @@ Page({
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
//线索来源
|
//客户来源
|
||||||
getAppCustomersOffline_sources(){
|
getAppCustomersOffline_sources(){
|
||||||
let params = {};
|
let params = {};
|
||||||
params['status'] = this.data.status;
|
params['status'] = this.data.status;
|
||||||
@@ -435,7 +437,7 @@ Page({
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
||||||
//线索来源
|
//客户来源
|
||||||
changeOf1(e) {
|
changeOf1(e) {
|
||||||
if(this.data.of1Index!=e.detail.value){
|
if(this.data.of1Index!=e.detail.value){
|
||||||
let of2Arr = []
|
let of2Arr = []
|
||||||
@@ -573,4 +575,11 @@ Page({
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
|
//是否添加个微
|
||||||
|
switchWxgr:function(e){
|
||||||
|
this.setData({
|
||||||
|
wxgr:e.detail.value ? 1 :0
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
})
|
})
|
||||||
@@ -74,7 +74,7 @@
|
|||||||
</view> -->
|
</view> -->
|
||||||
<block wx:if="{{sources.length>0}}">
|
<block wx:if="{{sources.length>0}}">
|
||||||
<view class="relative bbs-1-eb last-b-none pl140 font-28">
|
<view class="relative bbs-1-eb last-b-none pl140 font-28">
|
||||||
<view class="absolute left-0 box-middle">线索来源</view>
|
<view class="absolute left-0 box-middle">客户来源</view>
|
||||||
<view class="pt30 pb30 text-right font-28 color-666">
|
<view class="pt30 pb30 text-right font-28 color-666">
|
||||||
<picker bindchange="changeOf1" value="{{of1Index}}" range="{{of1Arr}}">
|
<picker bindchange="changeOf1" value="{{of1Index}}" range="{{of1Arr}}">
|
||||||
<text class="color-ccc" wx:if="{{of1Index == -1}}">请选择</text>
|
<text class="color-ccc" wx:if="{{of1Index == -1}}">请选择</text>
|
||||||
@@ -124,7 +124,13 @@
|
|||||||
</picker>
|
</picker>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
<view class="relative bbs-1-eb last-b-none pl180 font-28">
|
||||||
|
<view class="absolute left-0 box-middle">是否添加个微</view>
|
||||||
|
<view class="relative pt30 pb30 text-right">
|
||||||
|
<switch checked="{{wxgr==1}}" bindchange="switchWxgr" type="switch" color='#36afa2' style="zoom:0.8" />
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
|
||||||
<block wx:for='{{taglList}}' wx:for-item='list' wx:for-index='i' wx:key='i'>
|
<block wx:for='{{taglList}}' wx:for-item='list' wx:for-index='i' wx:key='i'>
|
||||||
<view class="relative mt40">
|
<view class="relative mt40">
|
||||||
<view class="font-28">
|
<view class="font-28">
|
||||||
@@ -134,37 +140,43 @@
|
|||||||
</view>
|
</view>
|
||||||
<view class="fn-clear" wx:if="{{list.type=='radio'}}">
|
<view class="fn-clear" wx:if="{{list.type=='radio'}}">
|
||||||
<block wx:for='{{list.list}}' wx:for-item='option' wx:for-index='j' wx:key='j'>
|
<block wx:for='{{list.list}}' wx:for-item='option' wx:for-index='j' wx:key='j'>
|
||||||
<view class="inline-block space-nowrap mt20 mr20 pt15 pb15 pl30 pr30 font-22 ulib-r10 {{option.checked?'bg-36afa2 color-fff':'bg-f6 color-666'}}" bindtap="radioPicker" data-i="{{i}}" data-j="{{j}}">{{option.name}}</view>
|
<view class="inline-block space-nowrap mt20 mr20 pt15 pb15 pl30 pr30 font-22 ulib-r10 {{option.checked?'bg-36afa2 color-fff':'bg-f6 color-666'}}" bindtap="radioPicker" data-i="{{i}}" data-j="{{j}}">
|
||||||
|
{{option.name}}
|
||||||
|
</view>
|
||||||
</block>
|
</block>
|
||||||
</view>
|
</view>
|
||||||
<view class="fn-clear" wx:if="{{list.type=='checkbox'}}">
|
<view class="fn-clear" wx:if="{{list.type=='checkbox'}}">
|
||||||
<block wx:for='{{list.list}}' wx:for-item='option' wx:for-index='j' wx:key='j'>
|
<block wx:for='{{list.list}}' wx:for-item='option' wx:for-index='j' wx:key='j'>
|
||||||
<view class="inline-block space-nowrap mt20 mr20 pt15 pb15 pl30 pr30 font-22 ulib-r10 {{option.checked?'bg-36afa2 color-fff':'bg-f6 color-666'}}" bindtap="checkPicker" data-i="{{i}}" data-j="{{j}}">{{option.name}}</view>
|
<view class="inline-block space-nowrap mt20 mr20 pt15 pb15 pl30 pr30 font-22 ulib-r10 {{option.checked?'bg-36afa2 color-fff':'bg-f6 color-666'}}" bindtap="checkPicker" data-i="{{i}}" data-j="{{j}}">
|
||||||
|
{{option.name}}
|
||||||
|
</view>
|
||||||
</block>
|
</block>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</block>
|
</block>
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="mt60 pl60 pr60">
|
<view class="mt60 pl60 pr60">
|
||||||
<button class="wp100 btn-36afa2 pt10 pb10 text-center font-32 color-fff ulib-r750" hover-class="btn-36afa2-hover" disabled="{{submitFlag}}" bindtap="postAppCustomers">确认建卡</button>
|
<button class="wp100 btn-36afa2 pt10 pb10 text-center font-32 color-fff ulib-r750" hover-class="btn-36afa2-hover" disabled="{{submitFlag}}" bindtap="postAppCustomers">
|
||||||
|
确认建卡
|
||||||
|
</button>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<lcb-footer></lcb-footer>
|
<lcb-footer></lcb-footer>
|
||||||
<lcb-backChannel></lcb-backChannel>
|
<lcb-backChannel></lcb-backChannel>
|
||||||
|
<!-- 客户已存在 -->
|
||||||
<!--客户已存在-->
|
|
||||||
<lcb-msg isShow="{{isShowExist}}" isHasClose="{{true}}">
|
<lcb-msg isShow="{{isShowExist}}" isHasClose="{{true}}">
|
||||||
<view slot="content">
|
<view slot="content">
|
||||||
<view class="pt60 pl60 pr60 pb50">
|
<view class="pt60 pl60 pr60 pb50">
|
||||||
<view class="font-36 text-center">{{exist.msg}}</view>
|
<view class="font-36 text-center">{{exist.msg}}</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="pl60 pr60 pb50 text-center font-32 color-666">
|
<view class="pl60 pr60 pb50 text-center font-32 color-666">
|
||||||
<button bindtap="viewDetails" class="inline-block wp50 btn-36afa2 font-28 color-fff ulib-r750" hover-class="btn-36afa2-hover" wx:if="{{exist.data.owner==1}}">前往查看</button>
|
<button bindtap="viewDetails" class="inline-block wp50 btn-36afa2 font-28 color-fff ulib-r750" hover-class="btn-36afa2-hover" wx:if="{{exist.data.owner==1}}">
|
||||||
<button bindtap="colseExist" class="inline-block wp50 btn-36afa2 font-28 color-fff ulib-r750" hover-class="btn-36afa2-hover" wx:else>知道了</button>
|
前往查看
|
||||||
|
</button>
|
||||||
|
<button bindtap="colseExist" class="inline-block wp50 btn-36afa2 font-28 color-fff ulib-r750" hover-class="btn-36afa2-hover" wx:else>
|
||||||
|
知道了
|
||||||
|
</button>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</lcb-msg>
|
</lcb-msg>
|
||||||
@@ -25,6 +25,7 @@ Page({
|
|||||||
city_id:'',
|
city_id:'',
|
||||||
countyIndex:-1,
|
countyIndex:-1,
|
||||||
county_id:'',
|
county_id:'',
|
||||||
|
wxgr:0,//是否添加个微
|
||||||
},
|
},
|
||||||
//生命周期函数--监听页面加载
|
//生命周期函数--监听页面加载
|
||||||
onLoad: function (options) {
|
onLoad: function (options) {
|
||||||
@@ -48,6 +49,7 @@ Page({
|
|||||||
mobile:res.data.baseinfo.mobile.value?res.data.baseinfo.mobile.value:'',
|
mobile:res.data.baseinfo.mobile.value?res.data.baseinfo.mobile.value:'',
|
||||||
of_id:res.data.baseinfo.of_id.of_id?res.data.baseinfo.of_id.of_id:'',
|
of_id:res.data.baseinfo.of_id.of_id?res.data.baseinfo.of_id.of_id:'',
|
||||||
of2_id:res.data.baseinfo.of_id.of2_id?res.data.baseinfo.of_id.of2_id:'',
|
of2_id:res.data.baseinfo.of_id.of2_id?res.data.baseinfo.of_id.of2_id:'',
|
||||||
|
wxgr:res.data.baseinfo.wxgr,
|
||||||
})
|
})
|
||||||
|
|
||||||
//编辑基础信息使用
|
//编辑基础信息使用
|
||||||
@@ -345,7 +347,7 @@ Page({
|
|||||||
}
|
}
|
||||||
else if (that.data.sources.length>0&&that.data.of_id == '' ) {
|
else if (that.data.sources.length>0&&that.data.of_id == '' ) {
|
||||||
wx.showToast({
|
wx.showToast({
|
||||||
title: '请选择线索来源',
|
title: '请选择客户来源',
|
||||||
icon: 'none'
|
icon: 'none'
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@@ -420,6 +422,7 @@ Page({
|
|||||||
// if(that.data.color_id != that.data.baseinfo.color_id.value){
|
// if(that.data.color_id != that.data.baseinfo.color_id.value){
|
||||||
// params['color_id'] = that.data.color_id;
|
// params['color_id'] = that.data.color_id;
|
||||||
// }
|
// }
|
||||||
|
params['wxgr'] = this.data.wxgr;
|
||||||
_.apiQuery.putAppCustomerData(params).then(res => {
|
_.apiQuery.putAppCustomerData(params).then(res => {
|
||||||
|
|
||||||
//刷新列表页
|
//刷新列表页
|
||||||
@@ -469,7 +472,7 @@ Page({
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
//线索来源
|
//客户来源
|
||||||
getAppCustomersOffline_sources(){
|
getAppCustomersOffline_sources(){
|
||||||
_.apiQuery.getAppCustomersOffline_sources().then(res => {
|
_.apiQuery.getAppCustomersOffline_sources().then(res => {
|
||||||
let of1Arr = []
|
let of1Arr = []
|
||||||
@@ -506,7 +509,7 @@ Page({
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
||||||
//线索来源
|
//客户来源
|
||||||
changeOf1(e) {
|
changeOf1(e) {
|
||||||
if(this.data.of1Index!=e.detail.value){
|
if(this.data.of1Index!=e.detail.value){
|
||||||
let of2Arr = []
|
let of2Arr = []
|
||||||
@@ -631,4 +634,11 @@ Page({
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
//是否添加个微
|
||||||
|
switchWxgr:function(e){
|
||||||
|
this.setData({
|
||||||
|
wxgr:e.detail.value ? 1 :0
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
})
|
})
|
||||||
@@ -55,7 +55,7 @@
|
|||||||
</view> -->
|
</view> -->
|
||||||
<block wx:if="{{sources.length>0}}">
|
<block wx:if="{{sources.length>0}}">
|
||||||
<view class="relative bbs-1-eb last-b-none pl140 font-28">
|
<view class="relative bbs-1-eb last-b-none pl140 font-28">
|
||||||
<view class="absolute left-0 box-middle">线索来源</view>
|
<view class="absolute left-0 box-middle">客户来源</view>
|
||||||
<view class="pt30 pb30 text-right font-28 color-666">
|
<view class="pt30 pb30 text-right font-28 color-666">
|
||||||
<picker bindchange="changeOf1" value="{{of1Index}}" range="{{of1Arr}}">
|
<picker bindchange="changeOf1" value="{{of1Index}}" range="{{of1Arr}}">
|
||||||
<text class="color-ccc" wx:if="{{of1Index == -1}}">请选择</text>
|
<text class="color-ccc" wx:if="{{of1Index == -1}}">请选择</text>
|
||||||
@@ -95,6 +95,12 @@
|
|||||||
</picker>
|
</picker>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
<view class="relative bbs-1-eb last-b-none pl180 font-28">
|
||||||
|
<view class="absolute left-0 box-middle">是否添加个微</view>
|
||||||
|
<view class="relative pt30 pb30 text-right">
|
||||||
|
<switch class="{{baseinfo.wxgr==1?'opacity-50':''}}" checked="{{wxgr==1}}" bindchange="switchWxgr" type="switch" color='#36afa2' disabled='{{baseinfo.wxgr==1}}' style="zoom:0.8" />
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
|
||||||
<block wx:for='{{taglList}}' wx:for-item='list' wx:for-index='i' wx:key='i'>
|
<block wx:for='{{taglList}}' wx:for-item='list' wx:for-index='i' wx:key='i'>
|
||||||
<view class="relative mt40">
|
<view class="relative mt40">
|
||||||
@@ -105,23 +111,26 @@
|
|||||||
</view>
|
</view>
|
||||||
<view class="fn-clear" wx:if="{{list.type=='radio'}}">
|
<view class="fn-clear" wx:if="{{list.type=='radio'}}">
|
||||||
<block wx:for='{{list.list}}' wx:for-item='option' wx:for-index='j' wx:key='j'>
|
<block wx:for='{{list.list}}' wx:for-item='option' wx:for-index='j' wx:key='j'>
|
||||||
<view class="inline-block space-nowrap mt20 mr20 pt15 pb15 pl30 pr30 font-22 ulib-r10 {{option.checked?'bg-36afa2 color-fff':'bg-f6 color-666'}}" bindtap="radioPicker" data-i="{{i}}" data-j="{{j}}">{{option.name}}</view>
|
<view class="inline-block space-nowrap mt20 mr20 pt15 pb15 pl30 pr30 font-22 ulib-r10 {{option.checked?'bg-36afa2 color-fff':'bg-f6 color-666'}}" bindtap="radioPicker" data-i="{{i}}" data-j="{{j}}">
|
||||||
|
{{option.name}}
|
||||||
|
</view>
|
||||||
</block>
|
</block>
|
||||||
</view>
|
</view>
|
||||||
<view class="fn-clear" wx:if="{{list.type=='checkbox'}}">
|
<view class="fn-clear" wx:if="{{list.type=='checkbox'}}">
|
||||||
<block wx:for='{{list.list}}' wx:for-item='option' wx:for-index='j' wx:key='j'>
|
<block wx:for='{{list.list}}' wx:for-item='option' wx:for-index='j' wx:key='j'>
|
||||||
<view class="inline-block space-nowrap mt20 mr20 pt15 pb15 pl30 pr30 font-22 ulib-r10 {{option.checked?'bg-36afa2 color-fff':'bg-f6 color-666'}}" bindtap="checkPicker" data-i="{{i}}" data-j="{{j}}">{{option.name}}</view>
|
<view class="inline-block space-nowrap mt20 mr20 pt15 pb15 pl30 pr30 font-22 ulib-r10 {{option.checked?'bg-36afa2 color-fff':'bg-f6 color-666'}}" bindtap="checkPicker" data-i="{{i}}" data-j="{{j}}">
|
||||||
|
{{option.name}}
|
||||||
|
</view>
|
||||||
</block>
|
</block>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</block>
|
</block>
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="mt60 pl60 pr60">
|
<view class="mt60 pl60 pr60">
|
||||||
<button class="wp100 btn-36afa2 pt10 pb10 text-center font-32 color-fff ulib-r750" hover-class="btn-36afa2-hover" disabled="{{submitFlag}}" bindtap="putAppCustomerData">确认</button>
|
<button class="wp100 btn-36afa2 pt10 pb10 text-center font-32 color-fff ulib-r750" hover-class="btn-36afa2-hover" disabled="{{submitFlag}}" bindtap="putAppCustomerData">
|
||||||
|
确认
|
||||||
|
</button>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<lcb-footer></lcb-footer>
|
<lcb-footer></lcb-footer>
|
||||||
|
|||||||
@@ -108,7 +108,7 @@ Page({
|
|||||||
//this.getAppSeriesBrands()
|
//this.getAppSeriesBrands()
|
||||||
//销售顾问
|
//销售顾问
|
||||||
this.getAppUserAdmins()
|
this.getAppUserAdmins()
|
||||||
//线索来源
|
//客户来源
|
||||||
this.getAppCustomersOffline_sources()
|
this.getAppCustomersOffline_sources()
|
||||||
|
|
||||||
this.getTimePicker()
|
this.getTimePicker()
|
||||||
@@ -646,7 +646,7 @@ Page({
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
//线索来源
|
//客户来源
|
||||||
getAppCustomersOffline_sources(){
|
getAppCustomersOffline_sources(){
|
||||||
_.apiQuery.getAppCustomersOffline_sources().then(res => {
|
_.apiQuery.getAppCustomersOffline_sources().then(res => {
|
||||||
let of1Arr = []
|
let of1Arr = []
|
||||||
@@ -660,7 +660,7 @@ Page({
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
||||||
//线索来源
|
//客户来源
|
||||||
changeOf1(e) {
|
changeOf1(e) {
|
||||||
if(this.data.of1Index!=e.detail.value){
|
if(this.data.of1Index!=e.detail.value){
|
||||||
let of2Arr = []
|
let of2Arr = []
|
||||||
|
|||||||
Reference in New Issue
Block a user