|
@@ -1,5 +1,6 @@
|
|
|
<template>
|
|
|
<view class="content">
|
|
|
+ <homenav :iStatusBarHeight="iStatusBarHeight" :title="'搜索'"></homenav>
|
|
|
<view class="sTopBox">
|
|
|
<view class="searchInputBox" >
|
|
|
<image src="../../static/img/icon_search.png" mode="" class="simg"></image>
|
|
@@ -25,8 +26,8 @@
|
|
|
<view class="ckcarTitle">请选择车型</view>
|
|
|
<image src="../../static/img/icon_quxiao.png" mode="" class="ckcarClose" @click="ckcarClose"></image>
|
|
|
</view>
|
|
|
- <view class="ckcarlineBox">
|
|
|
- <view class="ckcarline flex" v-for="(item,index) in vinList" @click="goDetal(item)">
|
|
|
+ <view class="ckcarlineBox" v-for="(item,index) in vinList" @click="goDetal(item)">
|
|
|
+ <view class="ckcarline flex" >
|
|
|
<view class="ckcarLeft">{{item.title}}</view>
|
|
|
<image src="../../static/img/icon_arrow.png" mode="" class="ckcarJtimg"></image>
|
|
|
</view>
|
|
@@ -67,9 +68,10 @@
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
+ import homenav from "../../components/homenav/nav.vue"
|
|
|
export default {
|
|
|
components: {
|
|
|
-
|
|
|
+ homenav
|
|
|
},
|
|
|
data() {
|
|
|
return {
|
|
@@ -89,10 +91,11 @@
|
|
|
carSeries:'',
|
|
|
isVin:'',
|
|
|
vin:'',
|
|
|
+ iStatusBarHeight:'',
|
|
|
}
|
|
|
},
|
|
|
onLoad(opt) {
|
|
|
-
|
|
|
+ this.iStatusBarHeight = uni.getSystemInfoSync().statusBarHeight;
|
|
|
},
|
|
|
methods: {
|
|
|
goDetal(e){
|
|
@@ -115,7 +118,7 @@
|
|
|
this.brand=e.brand
|
|
|
this.carSeries=e.carSeries
|
|
|
this.manufactor=e.manufactor
|
|
|
- this.getpopuponeList()
|
|
|
+ this.getpopuponeList(e)
|
|
|
}
|
|
|
},
|
|
|
popuponeBtn(item){
|
|
@@ -130,40 +133,69 @@
|
|
|
popupcTwo(){
|
|
|
this.popupTwoShow=false;
|
|
|
},
|
|
|
- getpopuponeList(){
|
|
|
+ getpopuponeList(e){
|
|
|
uni.showLoading({ title: '加载中'});
|
|
|
if(this.type==1){
|
|
|
var params={
|
|
|
manufactor: this.manufactor,type:this.type
|
|
|
}
|
|
|
- }else{
|
|
|
+ this.$http('matchingByOpen/queryCarModelGroupIiPackageSecond', params,'POST').then(res => {
|
|
|
+ uni.hideLoading();
|
|
|
+ this.popuponeList=res.data;
|
|
|
+ this.popuponeShow=true;
|
|
|
+ })
|
|
|
+ }else if(this.type==2){
|
|
|
var params={
|
|
|
manufactor: this.manufactor,type:this.type,carSeries:this.carSeries,brand:this.brand
|
|
|
}
|
|
|
+ this.$http('matchingByOpen/queryCarModelGroupIiPackageSecond', params,'POST').then(res => {
|
|
|
+ uni.hideLoading();
|
|
|
+ this.popuponeList=res.data;
|
|
|
+ this.popuponeShow=true;
|
|
|
+ })
|
|
|
+ }else{
|
|
|
+ uni.hideLoading();
|
|
|
+ console.log(e)
|
|
|
+ this.displacementList=e.displacementList;
|
|
|
+ this.popupTwoShow=true;
|
|
|
}
|
|
|
|
|
|
- this.$http('matchingByOpen/queryCarModelGroupIiPackageSecond', params,'POST').then(res => {
|
|
|
- uni.hideLoading();
|
|
|
- this.popuponeList=res.data;
|
|
|
- this.popuponeShow=true;
|
|
|
- })
|
|
|
+
|
|
|
},
|
|
|
popupc(){
|
|
|
this.popuponeShow=false;
|
|
|
},
|
|
|
searchFn(){
|
|
|
console.log(this.value.length)
|
|
|
+ if(!this.value){
|
|
|
+ uni.showToast({
|
|
|
+ title: '请输入车辆品牌、车系或VIN码',
|
|
|
+ icon:'none',
|
|
|
+ duration: 3000,
|
|
|
+ });
|
|
|
+ return false
|
|
|
+ }
|
|
|
if(this.value.length==17){
|
|
|
uni.showLoading({ title: '加载中'});
|
|
|
this.isVin=1;
|
|
|
- this.vin=this.value
|
|
|
+ this.vin=this.value;
|
|
|
+ this.vinList=[];
|
|
|
this.$http('matchingByOpen/queryCarModelGroupByVinAggregation', {
|
|
|
vin: this.value,type:2
|
|
|
},'POST').then(res => {
|
|
|
uni.hideLoading();
|
|
|
- this.vinList=res.data;
|
|
|
- this.ckCarShow=true;
|
|
|
- this.carMshow=false;
|
|
|
+ if(res.code==0){
|
|
|
+
|
|
|
+ this.vinList=res.data;
|
|
|
+ if(this.vinList.length==1){
|
|
|
+ this.goDetal(this.vinList[0])
|
|
|
+ }else{
|
|
|
+ this.ckCarShow=true;
|
|
|
+ this.carMshow=false;
|
|
|
+ }
|
|
|
+
|
|
|
+ }
|
|
|
+
|
|
|
})
|
|
|
}else{
|
|
|
uni.showLoading({ title: '加载中'});
|
|
@@ -288,7 +320,7 @@
|
|
|
width: 600rpx;
|
|
|
}
|
|
|
.simg{
|
|
|
- width: 34rpx;height: 34rpx;margin-top: 23rpx;margin-left:30rpx;
|
|
|
+ width: 36rpx;height: 34rpx;margin-top: 23rpx;margin-left:30rpx;
|
|
|
}
|
|
|
.historylinecarImg{
|
|
|
width: 46rpx;
|