history.vue 2.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107
  1. <template>
  2. <view class="content">
  3. <homenav :iStatusBarHeight="iStatusBarHeight" :title="'历史查询'"></homenav>
  4. <view class="box">
  5. <view class="historyLine" v-for="(item,index) in historyList" @click="goDetail(item)">
  6. <view class="historyLineCar">
  7. <view class="historyLogoBox">
  8. <image :src="item.logo" mode="" class="historylinecarImg"></image>
  9. </view>
  10. <view>
  11. <view class="historylinecar">{{item.title}}</view>
  12. <view class="historyLineVin" v-if="item.ifVin">
  13. <view class="vinms">VIN</view>
  14. <view class="vinNum">{{item.vin}}</view>
  15. </view>
  16. </view>
  17. </view>
  18. </view>
  19. <nodata v-if="historyList.length==0&&loading"></nodata>
  20. </view>
  21. </view>
  22. </template>
  23. <script>
  24. import homenav from "../../components/homenav/nav.vue"
  25. import nodata from '../../components/nodata/nodata.vue'
  26. export default {
  27. components: {
  28. homenav,nodata
  29. },
  30. data() {
  31. return {
  32. historyList:[],
  33. iStatusBarHeight:'',
  34. loading:false,
  35. }
  36. },
  37. onLoad(opt) {
  38. this.iStatusBarHeight = uni.getSystemInfoSync().statusBarHeight;
  39. this.queryHistory()
  40. },
  41. methods: {
  42. goDetail(e){
  43. uni.navigateTo({
  44. url:'/pages/index/byItem?nLevelID='+e.nLevelID+'&logo='+e.logo+'&value='+e.title+'&id='+e.groupID+'&isVin='+e.ifVin+'&vin='+e.vin
  45. })
  46. },
  47. queryHistory(){
  48. this.loading=false;
  49. this.$http2('queryHistory', {
  50. },'POST').then(res => {
  51. this.loading=true;
  52. this.historyList=res.data
  53. })
  54. },
  55. }
  56. }
  57. </script>
  58. <style scoped>
  59. .box{
  60. padding: 0 24rpx;
  61. }
  62. .historylinecarImg{
  63. width: 54rpx;
  64. height: 54rpx;
  65. }
  66. .historylinecar{
  67. font-weight: 400;font-size: 26rpx;
  68. color: #1A1A1A;
  69. line-height: 46rpx;width: 636rpx;
  70. }
  71. .historyLine{
  72. padding: 30rpx 0;border-top: 1rpx solid #EEEEEE;
  73. }
  74. .historyLineCar{
  75. display: flex;justify-content: space-between;
  76. }
  77. .vinms{
  78. width: 38rpx;
  79. height: 26rpx;
  80. background: linear-gradient(224deg, #FFDA28 0%, #FFBF35 100%);
  81. border-radius: 4rpx;
  82. text-align: center;
  83. line-height: 26rpx;
  84. font-weight: 600;
  85. color: #FFFFFF;
  86. font-size: 18rpx;
  87. margin-top: 2rpx;
  88. }
  89. .historyLineVin{
  90. display: flex;
  91. }
  92. .vinNum{
  93. font-weight: 400;font-size: 22rpx;padding-left: 10rpx;
  94. color: #999999;line-height: 30rpx;
  95. }
  96. .historyLogoBox{
  97. display: flex;align-items: center;
  98. }
  99. </style>