diff --git a/components/brandSelect/index.wxml b/components/brandSelect/index.wxml index f1fd063..1430a5c 100644 --- a/components/brandSelect/index.wxml +++ b/components/brandSelect/index.wxml @@ -23,7 +23,7 @@ - + diff --git a/pages/customer/index.js b/pages/customer/index.js index ba24b85..ff3b362 100644 --- a/pages/customer/index.js +++ b/pages/customer/index.js @@ -96,6 +96,13 @@ Page({ isShowCall:false,//是否显示拨打电话确认弹框 phoneNumber:'',//拨打的电话号码 + + brand_page_show:false, + brand_name:'', + brand_id: '', + series_id: -1, //车系id + modelArray: [], + modelIndex: -1, //车系车型索引 }, onLoad(options) { for (let key in options) { @@ -277,12 +284,12 @@ Page({ if(this.data.level != ''){ params['level'] = this.data.level; } - // if(this.data.brand_id != ''){ - // params['brand_id'] = this.data.brand_id; - // } - // if(this.data.s_id != ''){ - // params['s_id'] = this.data.s_id; - // } + if(this.data.brand_id != ''){ + params['brand_id'] = this.data.brand_id; + } + if(this.data.series_id != ''){ + params['series_id'] = this.data.series_id; + } // if(this.data.v_id != ''){ // params['v_id'] = this.data.v_id; // } @@ -524,7 +531,7 @@ Page({ changeModel(e) { if(this.data.modelIndex != e.detail.value && e.detail.value >= 0){ this.setData({ - s_id:this.data.modelList[e.detail.value].id, + series_id:this.data.modelList[e.detail.value].id, modelIndex:e.detail.value, }) } @@ -583,8 +590,8 @@ Page({ e_time:'', if_driver:'', level:'', - // brand_id:'', - // s_id:'', + brand_id:'', + series_id:'', cfrom:'', of_id:'', of2_id:'', @@ -604,6 +611,7 @@ Page({ city_id:'', countyIndex:-1, county_id:'', + brand_name:'', }) this.getAppCustomersTag() }, @@ -1104,5 +1112,24 @@ Page({ }) this.getAppCustomersList() }, - + bindShowBrand(){ + this.setData({ + brand_page_show:true + }) + }, + //获取品牌信息 + getBrandData(e) { + console.log(e.detail) + if (e.detail.index > -1 && e.detail.item) { + this.setData({ + brand_id: e.detail.item.id, + brand_name: e.detail.item.name, + brandIndex: e.detail.index, + series_id: '', //车系id + modelArray: [], + modelIndex: -1, //车系车型索引 + }) + this.getAppSeries() + } + }, }) \ No newline at end of file diff --git a/pages/customer/index.json b/pages/customer/index.json index 3dcacb2..afde368 100644 --- a/pages/customer/index.json +++ b/pages/customer/index.json @@ -2,6 +2,7 @@ "navigationBarTitleText": "客户", "enablePullDownRefresh": true, "usingComponents": { - "lcb-changeMobile": "/components/changeMobile/index" + "lcb-changeMobile": "/components/changeMobile/index", + "brandSelect": "/components/brandSelect/index" } } \ No newline at end of file diff --git a/pages/customer/index.wxml b/pages/customer/index.wxml index 05ddc41..d05aead 100644 --- a/pages/customer/index.wxml +++ b/pages/customer/index.wxml @@ -298,7 +298,7 @@ - + + + 车辆品牌 + + + {{brand_name||'请选择'}} + 请选择 + + + + + + 车系车型 + + + 请选择 + {{modelArray[modelIndex]}} + + + + @@ -386,6 +406,30 @@ + + + + + 计划回访时间 + + + + + {{item}} + + + + {{cMonth}} + + + {{item.day}} + + + + + + + @@ -424,4 +468,5 @@ - \ No newline at end of file + + \ No newline at end of file diff --git a/pages/order/index.js b/pages/order/index.js index 47193e6..6d31b72 100644 --- a/pages/order/index.js +++ b/pages/order/index.js @@ -35,6 +35,8 @@ Page({ brandIndex:-1,//车辆品牌索引 modelIndex:-1,//车系车型索引 levelIndex:-1,//车辆版本索引 + brand_page_show:false, + brand_name:'' }, onLoad: function (options) { for (let key in options) { @@ -232,6 +234,7 @@ Page({ }) this.setData({ + brand_name:'', brand_id:'', car_id:'', v_id:'', @@ -477,5 +480,27 @@ Page({ }) this.getAppCusorderList() }, - + bindShowBrand(){ + this.setData({ + brand_page_show:true + }) + }, + //获取品牌信息 + getBrandData(e) { + console.log(e.detail) + if (e.detail.index > -1 && e.detail.item) { + this.setData({ + brand_id: e.detail.item.id, + brand_name: e.detail.item.name, + brandIndex: e.detail.index, + series_id: '', //车系id + modelArray: [], + modelIndex: -1, //车系车型索引 + car_id: '', //车系id + carArray: [], //车辆版本列表 + carIndex: -1, //车辆版本索引 + }) + this.getAppSeries() + } + }, }) \ No newline at end of file diff --git a/pages/order/index.json b/pages/order/index.json index f68cfa1..769e43f 100644 --- a/pages/order/index.json +++ b/pages/order/index.json @@ -2,6 +2,7 @@ "navigationBarTitleText": "订单", "enablePullDownRefresh": true, "usingComponents": { - "lcb-changeMobile": "/components/changeMobile/index" + "lcb-changeMobile": "/components/changeMobile/index", + "brandSelect": "/components/brandSelect/index" } } \ No newline at end of file diff --git a/pages/order/index.wxml b/pages/order/index.wxml index 6c097df..6bd385d 100644 --- a/pages/order/index.wxml +++ b/pages/order/index.wxml @@ -208,12 +208,19 @@ 车辆品牌 - + + + {{brand_name||'请选择'}} + 请选择 + + + @@ -264,4 +271,6 @@ - \ No newline at end of file + + + \ No newline at end of file