adaptationsMore.vue 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110
  1. <template>
  2. <view class="content">
  3. <homenav :iStatusBarHeight="iStatusBarHeight" :title="'适配车型'"></homenav>
  4. <view class="box">
  5. <!-- <view class="detail-container">
  6. <view class="title1">{{optdata.title}}</view>
  7. <view class="title2">{{optdata.title2}}</view>
  8. </view> -->
  9. <view class="lineBox" v-for="(item,index) in list" @click="Ick(item)">
  10. <view class="line" >
  11. <view class="lineTitle">
  12. <span>{{item.brand}}</span>
  13. </view>
  14. <image class="jtImg" v-if="item.ck" src="/static/img/icon_arrow_up.png" mode=""></image>
  15. <image class="jtImg" v-if="!item.ck" src="/static/img/icon_arrow_down.png" mode=""></image>
  16. </view>
  17. <view v-if="item.ck">
  18. <view class="spcarline" v-for="(v,i) in item.list">{{v.title}}</view>
  19. </view>
  20. </view>
  21. </view>
  22. </view>
  23. </template>
  24. <script>
  25. import nodata from '../../components/nodata/nodata.vue'
  26. import homenav from "../../components/homenav/nav.vue"
  27. export default {
  28. components: {
  29. nodata,homenav
  30. },
  31. data() {
  32. return {
  33. iStatusBarHeight:'',
  34. optdata:'',
  35. list:'',
  36. }
  37. },
  38. onLoad(opt) {
  39. console.log(opt)
  40. this.iStatusBarHeight = uni.getSystemInfoSync().statusBarHeight;
  41. this.optdata=opt;
  42. uni.showLoading({ title: '加载中'});
  43. this.$http('partsByOpen/queryCarModelGroupByPartsID', {
  44. partsId:opt.partsId
  45. },'POST').then(res => {
  46. uni.hideLoading();
  47. res.data.forEach(item=>{
  48. item.ck=false
  49. })
  50. this.list = res.data
  51. })
  52. },
  53. methods: {
  54. Ick(item){
  55. item.ck=!item.ck
  56. },
  57. }
  58. }
  59. </script>
  60. <style scoped>
  61. .content{
  62. min-height: 100vh;
  63. background:#f4f5f7 ;
  64. }
  65. .jtImg{
  66. width: 26rpx;height: 26rpx;
  67. }
  68. .line{
  69. font-size: 30rpx;
  70. display: flex;
  71. justify-content: space-between;
  72. color: #22222;
  73. }
  74. .lineBox{
  75. /* padding: 24rpx; */
  76. border-bottom: 1px solid #eaeaea;
  77. }
  78. .line2{
  79. padding: 10rpx;color: #999;
  80. }
  81. .spcarline{
  82. font-weight: 400;
  83. color: #666;
  84. font-size: 24rpx;
  85. padding: 24rpx;
  86. }
  87. .line{
  88. padding: 24rpx;
  89. background: #fff;
  90. }
  91. .detail-container{
  92. background: #ffffff;
  93. margin-bottom: 20rpx;
  94. padding: 24rpx;
  95. }
  96. .title1{
  97. font-weight: 600; color: #333;font-size: 30rpx;
  98. }
  99. .title2{
  100. color: #999;font-size: 26rpx;
  101. padding-top: 10rpx;
  102. }
  103. </style>