|
@@ -23,7 +23,7 @@
|
|
|
<view class="carinfoBoxTopCont">
|
|
|
<view class="carinfoBoxTopContTop">
|
|
|
<view class="carInfoplateNumber">{{carInfo.plateNumber}}</view>
|
|
|
- <view class="carTnfomilage">{{carInfo.milage?carInfo.milage:0}}km</view>
|
|
|
+ <view class="carTnfomilage" v-if="carInfo.milage">{{carInfo.milage}}km</view>
|
|
|
</view>
|
|
|
<view class="carInfocarModel" v-if="carInfo.carModel">{{carInfo.carModel}}</view>
|
|
|
<view class="carInfocarModel" v-else>暂无</view>
|
|
@@ -61,26 +61,14 @@
|
|
|
</view>
|
|
|
<img src="../../static/timg/icon_arrow_right.png" alt="" class="adviserJt">
|
|
|
</view>
|
|
|
- <!-- 中间轮播模块 -->
|
|
|
+ <!-- 中间功能应用模块 -->
|
|
|
<view class="modular" v-if="homeCardList.application.length>0">
|
|
|
- <swiper class="swiper" circular :autoplay="false" :interval="interval"
|
|
|
- :duration="duration" :indicator-dots="true" indicator-color="#CCCCCC" indicator-active-color="#D53533">
|
|
|
- <swiper-item>
|
|
|
<view class="swiper-item">
|
|
|
<view class="itemLine" @click="goRoter('onlineBooking')" v-for="(item,index) in homeCardList.application">
|
|
|
<view><img :src="item.icon" alt="" class="itemImg"></view>
|
|
|
<view class="Menusline">{{item.name}}</view>
|
|
|
- </view>
|
|
|
-
|
|
|
- </view>
|
|
|
- </swiper-item>
|
|
|
- <!-- <swiper-item>
|
|
|
- <view class="swiper-item">
|
|
|
-
|
|
|
+ </view>
|
|
|
</view>
|
|
|
- </swiper-item> -->
|
|
|
-
|
|
|
- </swiper>
|
|
|
</view>
|
|
|
|
|
|
<view class="advertisement" v-if="homeCardList.ad1.length>0">
|
|
@@ -165,7 +153,7 @@
|
|
|
<!-- 手机号授权 -->
|
|
|
<view class="authorizBox" v-if="authorizShow" @click="authorizShow=false">
|
|
|
<view class="authorizCont" @click.stop="">
|
|
|
- <view class="authorizName">这是小程序名称</view>
|
|
|
+ <view class="authorizName">{{wxOpenData.miniAppName}}</view>
|
|
|
<view class="authorizMs">您好,欢迎访问本店,授权手机号登录能获取我们最新的促销活动哦~</view>
|
|
|
<button class="authorizContbutton" type="default" open-type="getPhoneNumber" @getphonenumber="decryptPhoneNumber">授权</button>
|
|
|
</view>
|
|
@@ -192,6 +180,7 @@
|
|
|
carInfo:'',
|
|
|
homeCardList:'',
|
|
|
authorizShow:false,
|
|
|
+ miniAppName:'',
|
|
|
}
|
|
|
},
|
|
|
onLoad() {
|
|
@@ -222,19 +211,26 @@
|
|
|
}
|
|
|
|
|
|
},
|
|
|
+ onShow() {
|
|
|
+ this.carInfo=this.$store.state.carInfo
|
|
|
+ },
|
|
|
methods: {
|
|
|
addCar(){
|
|
|
if(!this.userInfo){
|
|
|
this.authorizShow=true;
|
|
|
}else{
|
|
|
-
|
|
|
+ uni.navigateTo({
|
|
|
+ url:'../user/addCar/addCar'
|
|
|
+ })
|
|
|
}
|
|
|
},
|
|
|
information(){
|
|
|
|
|
|
},
|
|
|
changeCar(){
|
|
|
-
|
|
|
+ uni.navigateTo({
|
|
|
+ url:'../user/addCar/cailist'
|
|
|
+ })
|
|
|
},
|
|
|
goRoter(url){
|
|
|
if(!this.userInfo){
|
|
@@ -286,7 +282,9 @@
|
|
|
},
|
|
|
getWxOpenID(e){
|
|
|
var that=this;
|
|
|
- // this.code=e.code;
|
|
|
+ uni.showLoading({
|
|
|
+ title: '加载中'
|
|
|
+ })
|
|
|
this.$http('miniApp2/sys/getWxOpenID', {
|
|
|
code:e.code,
|
|
|
unionId:'EEADACCD-8A19-499D-8AD7-6975D2C93243'
|
|
@@ -332,7 +330,8 @@
|
|
|
var data = res.data;
|
|
|
if(data.loginInfo){
|
|
|
this.userInfo=data.loginInfo.openUser;
|
|
|
- this.$store.commit('mutationsuserInfo', this.userInfo)
|
|
|
+ this.$store.commit('mutationsuserInfo', this.userInfo);
|
|
|
+ this.$store.commit('mutationswxOpenData', data.loginInfo)
|
|
|
uni.setStorage({
|
|
|
key: 'userInfo',
|
|
|
data: data.loginInfo.openUser,
|
|
@@ -363,6 +362,7 @@
|
|
|
this.$http('openHome/queryHomeCardList', {
|
|
|
unionId:'EEADACCD-8A19-499D-8AD7-6975D2C93243'
|
|
|
},'GET').then(res => {
|
|
|
+ uni.hideLoading();
|
|
|
this.homeCardList=res.data
|
|
|
})
|
|
|
}
|
|
@@ -562,7 +562,7 @@
|
|
|
margin-top: -200rpx;
|
|
|
}
|
|
|
.shoptopbox2{
|
|
|
- margin-top: -160rpx;
|
|
|
+ margin-top: -170rpx;
|
|
|
}
|
|
|
.adviser{
|
|
|
width: 662rpx;
|
|
@@ -603,11 +603,12 @@
|
|
|
}
|
|
|
.modular{
|
|
|
width: 702rpx;
|
|
|
- height: 313rpx;
|
|
|
+ /* height: 313rpx; */
|
|
|
background: #FFFFFF;
|
|
|
border-radius: 10px;
|
|
|
margin-top: 20rpx;
|
|
|
margin-left: 24rpx;
|
|
|
+ padding-bottom: 40rpx;
|
|
|
}
|
|
|
.swiper-item{
|
|
|
display: flex;
|
|
@@ -622,7 +623,7 @@
|
|
|
color: #333333;
|
|
|
}
|
|
|
.itemLine{
|
|
|
- width: 25%;
|
|
|
+ width: 20%;
|
|
|
text-align: center;
|
|
|
padding-top: 40rpx;
|
|
|
}
|