index.vue 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143
  1. <template>
  2. <view class="container">
  3. <view class="item-me-bg"></view>
  4. <view class="item-me">
  5. <view class="item-row">
  6. <view>
  7. <view class="row-je">2031.7</view>
  8. <view class="row-jf">累计小费</view>
  9. </view>
  10. <view style="width: 2rpx;height: 96rpx;border: 2rpx solid #D6D7DC;margin: 0 80rpx"></view>
  11. <view>
  12. <view class="row-je">68</view>
  13. <view class="row-jf">跑腿订单</view>
  14. </view>
  15. </view>
  16. <view class="item-column">
  17. <view v-for="(item, index) in riderInfo" :key="index" class="column-box" :style="{paddingTop: index !== 0 ? '27rpx' : ''}"
  18. @tap="onRiderClick(item.id)">
  19. <view class="column-name">
  20. <image :src="item.img"></image>{{item.name}}
  21. </view>
  22. <view class='iconfont icon-jiantou ' style="font-size: 30rpx;"></view>
  23. </view>
  24. </view>
  25. </view>
  26. </view>
  27. </template>
  28. <script>
  29. export default {
  30. data() {
  31. return {
  32. riderInfo: [{
  33. id: 1,
  34. name: '跑腿记录',
  35. img: '/static/img/run-errands.png',
  36. pagePath: ''
  37. }, {
  38. id: 2,
  39. name: '提现',
  40. img: '/static/img/withdrawal.png',
  41. pagePath: ''
  42. }, {
  43. id: 3,
  44. name: '返回用户端',
  45. img: '/static/img/run-errands.png',
  46. pagePath: ''
  47. }],
  48. }
  49. },
  50. methods: {
  51. onRiderClick(id) {
  52. if (id === 3) {
  53. uni.switchTab({
  54. url: '/pages/user/index'
  55. })
  56. }
  57. }
  58. },
  59. onLoad(options) {},
  60. }
  61. </script>
  62. <style scoped lang="scss">
  63. .container {
  64. position: relative;
  65. flex: 1;
  66. width: 100%;
  67. }
  68. .item-me-bg {
  69. position: absolute;
  70. top: 0;
  71. width: 100%;
  72. height: 80rpx;
  73. background-color: $bg-color-primary;
  74. z-index: 1;
  75. }
  76. .item-me {
  77. position: relative;
  78. top: 0;
  79. z-index: 9999;
  80. padding: 0 19rpx;
  81. .item-row {
  82. width: 100%;
  83. height: 304rpx;
  84. text-align: center;
  85. background-color: #fff;
  86. border-radius: 23rpx;
  87. display: flex;
  88. align-items: center;
  89. justify-content: center;
  90. margin-bottom: 20rpx;
  91. .row-je {
  92. font-weight: 500;
  93. font-size: 46rpx;
  94. color: #141414;
  95. }
  96. .row-jf {
  97. font-weight: 400;
  98. font-size: 27rpx;
  99. color: #999999;
  100. }
  101. }
  102. .item-column {
  103. width: 100%;
  104. background-color: #fff;
  105. border-radius: 23rpx;
  106. padding: 20rpx 0 96rpx 39rpx;
  107. display: flex;
  108. flex-direction: column;
  109. align-items: center;
  110. .column-box {
  111. width: 100%;
  112. padding: 0 39rpx 27rpx 0;
  113. border-bottom: 2rpx solid #D6D7DC;
  114. display: flex;
  115. align-items: center;
  116. justify-content: space-between;
  117. }
  118. .column-name {
  119. display: flex;
  120. align-items: center;
  121. font-weight: 500;
  122. font-size: 27rpx;
  123. color: #141414;
  124. image {
  125. width: 38.5rpx;
  126. height: 38.5rpx;
  127. margin-right: 20rpx;
  128. }
  129. }
  130. }
  131. }
  132. </style>