199 lines
4.3 KiB
Vue
199 lines
4.3 KiB
Vue
<template>
|
|
<view>
|
|
<uni-nav-bar leftText=" " :fixed="true" :border="false" leftIcon="back" @clickLeft="leftClick" color="#000000" backgroundColor="#fff" :statusBar="true" :title="$t('navbar.carinfo')"></uni-nav-bar>
|
|
<view class="content">
|
|
<view class="cell">
|
|
<view>{{$t('carinfo.productName')}}</view>
|
|
<view class="right">
|
|
<text>{{cont.name}}</text>
|
|
</view>
|
|
</view>
|
|
<view class="cell">
|
|
<view>{{$t('carinfo.product_image')}}</view>
|
|
<view class="right">
|
|
<image :src="cont.cover_full" mode="" @click="previewImage(cont.cover_full)"></image>
|
|
</view>
|
|
</view>
|
|
<view class="cell">
|
|
<view>{{$t('carinfo.vin')}}</view>
|
|
<view class="right">
|
|
<text>{{cont.vin}}</text>
|
|
</view>
|
|
</view>
|
|
<view class="cell">
|
|
<view>{{$t('carinfo.brand')}}</view>
|
|
<view class="right ">
|
|
<text>{{cont.brand_name}}</text>
|
|
</view>
|
|
</view>
|
|
<view class="cell">
|
|
<view>{{$t('carinfo.model')}}</view>
|
|
<view class="right ">
|
|
<text>{{cont.model_name}}</text>
|
|
</view>
|
|
</view>
|
|
<view class="cell">
|
|
<view>{{$t('carinfo.price')}}</view>
|
|
<view class="right">
|
|
<text>{{cont.price}}</text>
|
|
</view>
|
|
</view>
|
|
<view class="cell">
|
|
<view>{{$t('carinfo.type')}}</view>
|
|
<view class="right">
|
|
<text>{{cont.type_name}}</text>
|
|
</view>
|
|
</view>
|
|
<view class="cell">
|
|
<view>{{$t('carinfo.energy')}}</view>
|
|
<view class="right">
|
|
<text>{{cont.energy_name}}</text>
|
|
</view>
|
|
</view>
|
|
<view class="cell">
|
|
<view>{{$t('carinfo.mileage')}}</view>
|
|
<view class="right">
|
|
<text>{{cont.mileage}}</text>
|
|
</view>
|
|
</view>
|
|
<view class="cell">
|
|
<view>{{$t('carinfo.store_status')}}</view>
|
|
<view class="right">
|
|
<text>{{cont.store_status_name}}</text>
|
|
</view>
|
|
</view>
|
|
<view class="cell">
|
|
<view>{{$t('carinfo.location')}}</view>
|
|
<view class="right">
|
|
<text>{{cont.location_name}}</text>
|
|
</view>
|
|
</view>
|
|
<view class="cell1">
|
|
<view>{{$t('carinfo.age')}}</view>
|
|
<view class="right">
|
|
<text>{{cont.vehicle_age}}</text>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
<view class="zw"></view>
|
|
<view class="foot">
|
|
<button class="btn" @click="nextFn">{{$t('button.next')}}</button>
|
|
</view>
|
|
</view>
|
|
</template>
|
|
|
|
<script>
|
|
import { request,showToast } from '@/api/apiT.js'
|
|
export default {
|
|
data() {
|
|
return {
|
|
id:'',
|
|
cont:{
|
|
}
|
|
}
|
|
},
|
|
onLoad(options) {
|
|
console.log(options);
|
|
this.id = options.id;
|
|
this.getcontList()
|
|
},
|
|
methods: {
|
|
leftClick(){
|
|
uni.navigateBack({})
|
|
},
|
|
getcontList(){
|
|
request({
|
|
url:'vehicle/detail/'+this.id,
|
|
data:{id:this.id},
|
|
method:'get',
|
|
}).then(res => {
|
|
this.cont = res.data.data
|
|
const carinfo = JSON.stringify(this.cont);
|
|
// console.log(carinfo)
|
|
uni.setStorageSync('carlistinfo', carinfo);
|
|
})
|
|
},
|
|
nextFn(){
|
|
uni.navigateTo({
|
|
url: '/pages/mine/soldList/soldcarinfo1?id='+this.id
|
|
});
|
|
},
|
|
previewImage(url) {
|
|
uni.previewImage({
|
|
current: url, // 当前显示图片
|
|
urls: [url], // 需要预览的图片列表
|
|
indicator: "number", // 显示指示器
|
|
loop: true // 是否可循环预览
|
|
})
|
|
}
|
|
}
|
|
}
|
|
</script>
|
|
|
|
<style lang="less">
|
|
.content{
|
|
margin: 20px 12px;
|
|
background: #FFFFFF;
|
|
border-radius: 10px;
|
|
}
|
|
.cell{
|
|
display: flex;
|
|
justify-content:space-between;
|
|
padding: 18px 20px;
|
|
/* border-bottom: 1px solid #C3C3C3; */
|
|
align-items: center;
|
|
position: relative;
|
|
font-weight: 500;
|
|
image{
|
|
width: 40px;
|
|
height: 40px;
|
|
}
|
|
}
|
|
.cell::after{
|
|
content : '';
|
|
position : absolute;
|
|
width : 200%;
|
|
height : 200%;
|
|
top : 0;
|
|
left : 0;
|
|
transform-origin: 0 0;
|
|
border-width: 0;
|
|
border-bottom-width:1px;
|
|
border-style : solid;
|
|
transform : scale(0.5, 0.5);
|
|
border-radius : 1px;
|
|
box-sizing : border-box;
|
|
pointer-events : none;
|
|
border-color:#C3C3C3;
|
|
}
|
|
.cell1{
|
|
display: flex;
|
|
justify-content:space-between;
|
|
padding: 18px 20px;
|
|
align-items: center;
|
|
font-weight: 500;
|
|
}
|
|
.right{
|
|
text-align: right;
|
|
}
|
|
.foot{
|
|
position: fixed;
|
|
bottom: 0px;
|
|
width: 100%;
|
|
height: 240rpx;
|
|
background: #FFFFFF;
|
|
z-index: 1;
|
|
}
|
|
.btn{
|
|
background-color: #3F435B;
|
|
color: white;
|
|
border-radius: 50px;
|
|
width: 84%;
|
|
margin-bottom: 40px;
|
|
margin: 15px 8%;
|
|
}
|
|
.zw{
|
|
height: 120px;
|
|
}
|
|
</style>
|