logisticsProgress.vue 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202
  1. <template>
  2. <view class="page">
  3. <view class="top-detail">
  4. <view class="title">
  5. 发往仓库
  6. </view>
  7. <image class="arrow" src="../../static/mine/339.png" mode=""></image>
  8. <view class="title">
  9. 仓库打包
  10. </view>
  11. <image class="arrow" src="../../static/mine/340.png" mode=""></image>
  12. <view class="title">
  13. 洛杉矶
  14. </view>
  15. </view>
  16. <view class="logistics">
  17. <view class="warehouse-packaging" v-if="warehouse.length>0">
  18. <Progress :logisticsList="warehouse" />
  19. </view>
  20. <view class="_detail-1">
  21. <text>已于11月24日送至平台仓库</text>
  22. <u-icon @click="putItAway" name="arrow-up" color="#666666" size="18" v-if="isShow"></u-icon>
  23. <u-icon @click="putItAway" name="arrow-down" color="#666666" size="18" v-else></u-icon>
  24. </view>
  25. <view class="logistics-detail" v-if="isShow">
  26. <view class="">
  27. {{"顺丰快递"+"&nbsp;"+"|"+"&nbsp"+"订单号:"}}
  28. <text>JDV21093105892</text>
  29. </view>
  30. <view class="phone">
  31. <text @click="cope('JDV21093105892')">复制</text>
  32. {{"&nbsp;"+"|"+"&nbsp"}}
  33. <text @click="makeCall">打电话</text>
  34. </view>
  35. </view>
  36. <view class="logistics-information" v-if="isShow">
  37. <Progress :logisticsList="logisticsList" />
  38. </view>
  39. </view>
  40. </view>
  41. </template>
  42. <script>
  43. import Progress from './component/progress.vue'
  44. export default {
  45. components: {
  46. Progress
  47. },
  48. data() {
  49. return {
  50. logisticsList: [{
  51. title: "已签收",
  52. time: "10:11",
  53. status: false,
  54. does: "您的快件已暂存至浦口东方万汇城北区2号楼超市店菜鸟驿站,请凭取件码及时领取。"
  55. }, {
  56. title: "派送中",
  57. time: "10:11",
  58. status: false,
  59. does: "临沂市配送员【叶景瑞】 187626516732 正为您派送,感谢您的耐心等待"
  60. }, {
  61. title: "",
  62. time: "10:11",
  63. status: false,
  64. does: "临沂市配送员【叶景瑞】 187626516732 正为您派送,感谢您的耐心等待"
  65. },
  66. {
  67. title: "运输中",
  68. time: "10:11",
  69. status: false,
  70. does: "快递离开******"
  71. }
  72. ],
  73. warehouse: [{
  74. title: "打包称重",
  75. time: "10:11",
  76. status: true,
  77. imageUrl: true,
  78. does: "商品已打包称重,待用户付款"
  79. },
  80. {
  81. title: "商品入库",
  82. time: "10:11",
  83. status: false,
  84. imageUrl: false,
  85. does: "商品已进入转入仓库,正在排队等待打包"
  86. }
  87. ],
  88. isShow:true
  89. }
  90. },
  91. computed: {},
  92. methods: {
  93. cope(str) {
  94. uni.setClipboardData({
  95. data: str,
  96. success() {
  97. uni.showToast({
  98. title: "复制成功",
  99. icon: "none"
  100. })
  101. }
  102. })
  103. },
  104. makeCall() {
  105. uni.authorize({
  106. scope: 'scope.makePhoneCall',
  107. success: () => {
  108. uni.makePhoneCall({
  109. phoneNumber: '手机号码',
  110. success: () => {
  111. console.log('拨打电话成功!');
  112. },
  113. fail: () => {
  114. console.error('拨打电话失败!');
  115. }
  116. });
  117. },
  118. fail: () => {
  119. console.error('授权失败,请允许拨打电话权限!');
  120. }
  121. });
  122. },
  123. putItAway(){
  124. this.isShow = !this.isShow
  125. }
  126. },
  127. created() {
  128. uni.setNavigationBarTitle({
  129. title: "物流进度"
  130. })
  131. }
  132. }
  133. </script>
  134. <style scoped lang="scss">
  135. .page {
  136. padding: 20rpx 24rpx;
  137. .top-detail {
  138. display: flex;
  139. justify-content: space-around;
  140. align-items: center;
  141. height: 144rpx;
  142. background: linear-gradient(180deg, #F6E1DE 0%, #EFEFEF 100%);
  143. border-radius: 16rpx 16rpx 0 0;
  144. .title {
  145. color: rgba(34, 34, 34, .6);
  146. font-size: 32rpx;
  147. }
  148. .arrow {
  149. width: 98rpx;
  150. height: 8rpx;
  151. }
  152. }
  153. .logistics {
  154. background-color: #fff;
  155. border-radius: 16rpx;
  156. padding: 0 20rpx;
  157. position: relative;
  158. top: -20rpx;
  159. padding-bottom: 20rpx;
  160. ._detail-1 {
  161. display: flex;
  162. justify-content: space-between;
  163. font-size: 28rpx;
  164. color: #666;
  165. align-items: center;
  166. border-top: 2rpx solid rgba(151, 151, 151, .1);
  167. padding-top: 28rpx;
  168. }
  169. .logistics-detail {
  170. display: flex;
  171. justify-content: space-between;
  172. font-size: 26rpx;
  173. color: #333;
  174. height: 104rpx;
  175. align-items: center;
  176. border-bottom: 2rpx solid rgba(151, 151, 151, .1);
  177. }
  178. .logistics-information {
  179. padding: 20rpx 0;
  180. .information {
  181. position: relative;
  182. }
  183. }
  184. }
  185. }
  186. </style>