confirm.vue 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158
  1. <template>
  2. <view>
  3. <car-common ref="common"></car-common>
  4. <u-navbar title="确认身份" :is-back="noback">
  5. <view class="slot-wrap"></view>
  6. <view class="navbar-right" @click="gotoHome" v-if="!noback" >
  7. <u-icon name="home-fill" color="#999" size="28"></u-icon>
  8. <span >前往首页</span>
  9. </view>
  10. </u-navbar>
  11. <view class="confirm">
  12. <h3 v-if="list.length">请选择购票人的照片?</h3>
  13. <p v-show="!num">一位乘客仅需选择一张照片</p>
  14. <p v-show="num">如需为您的同伴购票请同时选中Ta的照片</p>
  15. <view class="confirm-pic" v-if="list.length">
  16. <template v-for="item in list">
  17. <view class="confirm-pic-item " :class="item.ck?'active':''" @click="ckBtn(item)" >
  18. <img :src="item.imageUrl+'?x-oss-process=image/resize,h_800,m_lfit/auto-orient,1'" alt="">
  19. </view>
  20. </template>
  21. </view>
  22. </view>
  23. <view class="upload-button" >
  24. <view class="reset-btn" @click="upBusNoTicketList">
  25. <u-icon name="shuaxin" custom-prefix="custom-icon" color="#2979ff" size="36"></u-icon>
  26. </view>
  27. <view class="submit-btn" v-show="num">
  28. <u-button type="primary" shape="circle" @click="submit">确定</u-button>
  29. </view>
  30. <view class="submit-btn" v-show="!num">
  31. <u-button class="gray-btn" type="default" shape="circle" >请选择</u-button>
  32. </view>
  33. </view>
  34. </view>
  35. </template>
  36. <script>
  37. import api from './confirm.js'
  38. export default api;
  39. </script>
  40. <style scoped lang="scss">
  41. .confirm{
  42. margin-top: 20px;
  43. .confirm-img{
  44. height: 240px;
  45. width: 240px;
  46. border-radius: 50%;
  47. overflow: hidden;
  48. border:4px solid #1677ff;
  49. img{
  50. height: 100%;
  51. width: 100%;
  52. }
  53. }
  54. .confirm-img-border{
  55. border: 2px solid #fff;
  56. height: 244px;
  57. width: 244px;
  58. border-radius: 50%;
  59. }
  60. .confirm-img-border2{
  61. border: 2px solid #7fb4ff;
  62. height: 248px;
  63. width: 248px;
  64. border-radius: 50%;
  65. margin: 50px auto 20px;
  66. }
  67. .confirm-img-border3{
  68. border: 2px solid #ffb8b8;
  69. height: 248px;
  70. width: 248px;
  71. border-radius: 50%;
  72. margin: 50px auto 20px;
  73. .confirm-img{
  74. border-color:#ff6666;
  75. }
  76. }
  77. h3{
  78. text-align: center;
  79. font-size: 18px;
  80. }
  81. p{
  82. color:#999;text-align: center;
  83. margin-top: 10rpx;
  84. }
  85. }
  86. .navbar-right {
  87. display: flex;
  88. margin-right: 20rpx;
  89. span{
  90. color:rgb(96, 98, 102);
  91. margin-left: 3px;
  92. }
  93. }
  94. .slot-wrap {
  95. display: flex;
  96. align-items: center;
  97. flex: 1;
  98. }
  99. .confirm-pic{
  100. display: flex;
  101. flex-direction: row;
  102. flex-wrap: wrap;
  103. padding: 20px;
  104. margin-bottom: 30px;
  105. .confirm-pic-item{
  106. height:100px;
  107. width: 100px;
  108. border-radius: 50%;
  109. overflow: hidden;
  110. border: 3px solid #fff;
  111. margin-bottom: 10px;
  112. margin-right: 17px;
  113. &:nth-child(3n+0){
  114. margin-right: 0;
  115. }
  116. &.active{
  117. border: 3px solid #1677ff;
  118. }
  119. img{
  120. height: 100%;
  121. width: 100%;
  122. }
  123. }
  124. }
  125. .upload-button{
  126. position: fixed;
  127. left: 30rpx;
  128. bottom:30rpx;
  129. right: 30rpx;
  130. display: flex;
  131. .reset-btn{
  132. height: 40px;
  133. width: 40px;
  134. border-radius: 50%;
  135. text-align: center;
  136. line-height: 40px;
  137. border: 1px solid #eee;
  138. margin-right: 10px;
  139. }
  140. .submit-btn{
  141. flex: 1;
  142. .gray-btn{
  143. background-color: #bfbfbf;
  144. color:#fff;
  145. border-color: #bfbfbf;
  146. }
  147. }
  148. }
  149. </style>