index.vue 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134
  1. <template>
  2. <view class="content">
  3. <view class="top">
  4. <view class="inputBox">
  5. <img src="../../static/img/icon_search.png" alt="" class="searchImg">
  6. <input v-model="vin" type="text" placeholder="请输入17位车架号查询" class="topInput" @confirm="inputconfirm">
  7. <image src="../../static/img/icon_close.png" class="searchClose" v-if="vin!=''"
  8. @click="clear"></image>
  9. <!-- <image src="../../static/img/icon_camera.png" mode="" class="cameraImg"></image> -->
  10. </view>
  11. </view>
  12. <view class="history">
  13. <view class="historyTop">
  14. <view class="historyTopTxt">历史搜索</view>
  15. <!-- <image src="../../static/img/icon_delete.png" mode="" class="historyDelImg"></image> -->
  16. </view>
  17. <view v-for="(item,index) in 1" class="historyLIneBox">
  18. <view class="historyLIne" @click="gogroup2('LVHRE4877A5013603')">LVHRE4877A5013603</view>
  19. </view>
  20. </view>
  21. </view>
  22. </template>
  23. <script>
  24. export default {
  25. data() {
  26. return {
  27. vin: ''
  28. }
  29. },
  30. onLoad() {
  31. },
  32. methods: {
  33. clear(){
  34. this.vin = ''
  35. this.$emit('search','');
  36. },
  37. inputconfirm(){
  38. console.log(this.vin)
  39. this.gogroup()
  40. },
  41. gogroup(){
  42. uni.navigateTo({
  43. url:'group?vin='+this.vin
  44. })
  45. },
  46. gogroup2(vin){
  47. uni.navigateTo({
  48. url:'group?vin='+vin
  49. })
  50. }
  51. }
  52. }
  53. </script>
  54. <style scoped>
  55. .comment{
  56. padding-bottom: constant(safe-area-inset-bottom);
  57. padding-bottom: env(safe-area-inset-bottom);
  58. }
  59. .top{
  60. height: 96rpx;
  61. border-bottom: 1px solid #EEEEEE;
  62. padding-top: 24rpx;
  63. }
  64. .searchImg{
  65. width: 40rpx;
  66. height: 40rpx;
  67. margin-top: 16rpx;
  68. margin-left: 20rpx;
  69. }
  70. .inputBox{
  71. width: 702rpx;
  72. height: 72rpx;
  73. background: #F4F5F7;
  74. border-radius: 36rpx;
  75. margin-left: 24rpx;
  76. display:flex;
  77. position: relative;
  78. }
  79. .topInput{
  80. font-size: 28rpx;
  81. height: 72rpx;
  82. line-height: 72rpx;
  83. padding-left: 16rpx;
  84. width: 500rpx;
  85. }
  86. .searchClose {
  87. position: absolute;
  88. width: 36rpx;
  89. height: 36rpx;
  90. right: 36rpx;
  91. top: 20rpx;
  92. }
  93. .cameraImg{
  94. position: absolute;
  95. width: 40rpx;
  96. height: 40rpx;
  97. top: 16rpx;
  98. right: 20rpx;
  99. }
  100. .history{
  101. padding: 24rpx;
  102. }
  103. .historyTop{
  104. display: flex;
  105. justify-content: space-between;
  106. }
  107. .historyDelImg{
  108. width: 34rpx;height: 34rpx;
  109. }
  110. .historyTopTxt{
  111. font-size: 28rpx;
  112. font-weight: 400;
  113. color: #666666;
  114. line-height: 34rpx;
  115. }
  116. .historyLIne{
  117. color: #333333;font-size: 24rpx;
  118. height: 64rpx;
  119. background: #F4F5F7;
  120. border-radius: 32rpx;
  121. line-height: 64rpx;
  122. padding: 0 24rpx;
  123. margin-top: 20rpx;
  124. }
  125. .historyLIneBox{
  126. display: flex;
  127. }
  128. </style>