123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115 |
- <template>
- <view class="content">
- <view class="contTop">
- <view class="brand">{{ urldata.brand }} {{ urldata.categoryName }} {{ urldata.name }}</view>
- <view class="partsCode">{{ urldata.partsCode }} | {{ urldata.specificationModel }}</view>
- </view>
- <view class="sycx">
- <img src="../../static/img/icon_car_def 2.png" alt="" class="sycxImg">
- <view class="sycxTxt">适用车型</view>
- </view>
- <view class="listBox">
- <view class="listLine" v-for="(item,index) in list">
- <view class="lineTop" @click="zhankai(item)">
- <view class="lineTopTxt">{{item.brand}}</view>
- <img src="../../static/img/icon_arrow_down.png" alt="" class="jiantou" v-if="!item.show">
- <img src="../../static/img/icon_arrow_up.png" alt="" class="jiantou" v-else>
- </view>
- <view class="lineCont" v-for="(v,i) in item.list" v-show="item.show">
- <view class="lie">{{v.title}}</view>
- </view>
- </view>
- </view>
- </view>
- </template>
- <script>
- export default {
-
- data() {
- return {
- id:'',
- list:'',
- urldata:''
- }
- },
- onLoad(opt) {
- this.urldata=opt;
- uni.showLoading({ title: '加载中'});
- this.$http('matchingByOpen/queryCarModelGroupByPartsID', {
- partsId:opt.id
-
- }, 'POST').then(res => {
- res.data.forEach(item=>{
- item.show=false;
- })
- this.list=res.data;
- uni.hideLoading();
- })
- },
- methods: {
- zhankai(item){
- item.show=!item.show;
- }
- }
- }
- </script>
- <style scoped>
- .content{
- min-height: 100vh;
- background: #F4F5F7;
- }
- .contTop{
- background: #ffffff;
- padding: 30rpx 24rpx;
- }
- .brand{
- color: #333333;
- line-height: 42rpx;
- font-size: 30rpx;
- font-family: PingFangSC-Medium, PingFang SC;
- font-weight: 500;
- }
- .partsCode{
- color: #999999;font-size: 24rpx;padding-top: 10rpx;
- line-height: 33rpx;
- }
- .sycx{
- display: flex;background: #ffffff;padding: 28rpx 24rpx;
- border-bottom: 1px solid #EEEEEE;
- margin-top: 20rpx;
- }
- .sycxImg{
- width: 42rpx;height: 42rpx;
- }
- .sycxTxt{
- color: #333333;font-size: 30rpx;
- line-height: 42rpx;padding-left: 16rpx;
- font-weight: 500;
- }
- .lineTop{
- background: #ffffff;display: flex;
- justify-content: space-between;
- padding: 30rpx 24rpx;
- }
- .jiantou{
- width: 24rpx;height: 24rpx;margin-top: 8rpx;
- }
- .lineTopTxt{
- font-size: 28rpx;
- font-family: PingFangSC-Medium, PingFang SC;
- font-weight: 500;
- color: #333333;
- }
- .lineCont{
- color: #666666;
- line-height: 40rpx;
- font-size: 28rpx;
- padding: 5rpx 24rpx;
- }
- .lie{
- padding: 15rpx 0;
- }
- </style>
|