orderShop.vue 3.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185
  1. <template>
  2. <view class="box">
  3. <view class="topTIs">门店确认收货后,才可选择预约时间</view>
  4. <view class="shopbox">
  5. <view class="shopline" v-for="(item,index) in queryShopList">
  6. <view class="shoplineLeft">
  7. <image :src="item.photoPath" mode="" class="shopImg" v-if="item.photoPath"></image>
  8. <image src="../../static/img/noimg.png" mode="" class="shopImg" v-else></image>
  9. </view>
  10. <view class="shopright">
  11. <view class="shopTop">
  12. <view class="shopName">{{item.shopName}}</view>
  13. <image src="../../static/img/shopcall.png" mode="" class="shopCallImg"></image>
  14. </view>
  15. <view class="shopScore">
  16. <span class="shopScore1" v-if="item.shopScore">{{item.shopScore}}</span>
  17. <span class="shopScore2" v-if="item.shopScore">分</span>
  18. <span class="shopScore2" v-if="!item.shopScore">暂无评分</span>
  19. <span class="shopScore3">服务次数 {{item.sheetSum}}</span>
  20. </view>
  21. <view class="shopTime"><span v-if="item.startTime">{{item.startTime}}</span> - <span v-if="item.endTime">{{item.endTime}}</span> </view>
  22. <view class="shopBottom">
  23. <view class="shopBottomLeft">
  24. <span v-if="item.distance&&item.distance!= '0.00'">{{item.distance}}km</span>
  25. <span class="shopaddress">{{item.address}}</span>
  26. </view>
  27. <view class="Btn" @click="ckshop(item)">确定</view>
  28. </view>
  29. </view>
  30. </view>
  31. </view>
  32. </view>
  33. </template>
  34. <script>
  35. export default {
  36. components: {
  37. },
  38. data() {
  39. return {
  40. orderData:'',
  41. currentMileage:'',
  42. location:'',
  43. queryShopList:[],
  44. }
  45. },
  46. onShow() {
  47. },
  48. onLoad(opt) {
  49. this.orderData=opt.orderData;
  50. this.currentMileage=opt.currentMileage;
  51. this.location=uni.getStorageSync("location");
  52. this.getqueryShopList()
  53. },
  54. methods: {
  55. ckshop(item){
  56. console.log(item)
  57. var that=this;
  58. uni.setStorage({
  59. key: 'orderShop',
  60. data: item,
  61. success: function() {
  62. uni.navigateTo({
  63. url:'confirmOrder?orderData='+that.orderData+'&currentMileage='+that.currentMileage
  64. })
  65. }
  66. });
  67. },
  68. getqueryShopList(){
  69. uni.showLoading({ });
  70. this.$http('worldKeepCar/worldHome/getWorldShopInfoList', {
  71. lat:this.location.lat,
  72. lng:this.location.lng,
  73. cityCode:this.location.cityCode,
  74. },'GET').then(res => {
  75. uni.hideLoading();
  76. this.queryShopList=res.data
  77. })
  78. },
  79. }
  80. }
  81. </script>
  82. <style scoped>
  83. .box{
  84. min-height: 100vh;
  85. background:#F4F5F7 ;
  86. }
  87. .topTIs{
  88. font-size: 26rpx;
  89. text-align: center;
  90. color: #C8841C;
  91. height: 72rpx;
  92. background: #FFF7EB;
  93. line-height: 72rpx;
  94. margin-bottom: 20rpx;
  95. }
  96. .shopbox{
  97. padding:0 16rpx;
  98. }
  99. .shopline{
  100. padding: 20rpx;
  101. background: #FFFFFF;
  102. border-radius: 10rpx;
  103. margin-top: 20rpx;
  104. display: flex;
  105. }
  106. .shopImg{
  107. width: 146rpx;
  108. height: 146rpx;
  109. border-radius: 10rpx;
  110. }
  111. .shopCallImg{
  112. width: 38rpx;
  113. height: 46rpx;
  114. }
  115. .shopTop{
  116. display: flex;
  117. justify-content: space-between;
  118. width: 510rpx;
  119. }
  120. .shopright{
  121. padding-left: 20rpx;
  122. }
  123. .shopName{
  124. font-size: 26rpx;
  125. color: #333333;
  126. line-height: 37rpx;
  127. width:450rpx;
  128. white-space: nowrap;
  129. overflow: hidden;
  130. text-overflow: ellipsis;
  131. }
  132. .shopScore1{
  133. font-size: 36rpx;
  134. color: #FF4F00;
  135. }
  136. .shopScore2{
  137. font-size: 22rpx;
  138. color: #FF4F00;
  139. }
  140. .shopScore3{
  141. font-size: 22rpx;
  142. color: #333333;
  143. padding-left: 20rpx;
  144. }
  145. .shopTime{
  146. font-size: 22rpx;
  147. color: #666666;
  148. line-height: 30rpx;
  149. padding-top: 10rpx;
  150. }
  151. .Btn{
  152. width: 104rpx;
  153. height: 56rpx;
  154. background: #FF2400 linear-gradient(135deg, #FD5300 0%, #FF270A 100%);
  155. border-radius: 6rpx;
  156. font-size: 26rpx;
  157. text-align: center;
  158. color: #FFFFFF;
  159. line-height: 56rpx;
  160. }
  161. .shopBottom{
  162. display: flex;
  163. }
  164. .shopBottomLeft{
  165. width: 400rpx;
  166. font-size: 22rpx;
  167. color: #666666;
  168. line-height: 30rpx;
  169. padding-top: 10rpx;
  170. }
  171. .shopaddress{
  172. padding-left: 10rpx;
  173. }
  174. </style>