猫妈狗爸伴宠师小程序前端代码
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

146 lines
2.3 KiB

3 months ago
3 months ago
3 months ago
3 months ago
3 months ago
3 months ago
3 months ago
3 months ago
3 months ago
3 months ago
  1. <template>
  2. <!-- <div>保证金明细</div> -->
  3. <view class="box">
  4. <view class="top flex" :style="{ borderRadius: '31.5rpx' }">
  5. <view
  6. class="income flex element"
  7. v-for="(tab, tIdx) in tabs"
  8. :key="`tab-${tIdx}`"
  9. :class="[queryParams.status === tab.value ? 'is-active' : '']"
  10. >
  11. {{ tab.title }}
  12. </view>
  13. </view>
  14. <view>
  15. <view class="Recharge flex"
  16. v-for="(item, index) in list"
  17. :key="`record-${index}`"
  18. >
  19. <view class="flex">
  20. <image src="https://img1.baidu.com/it/u=3034232350,1041791648&fm=253&fmt=auto&app=138&f=PNG?w=500&h=500"
  21. mode=""></image>
  22. <view class="text1">
  23. <view class="text2">
  24. {{ item.title }}
  25. </view>
  26. <view>
  27. {{ item.createTime }}
  28. </view>
  29. </view>
  30. </view>
  31. <view class="text3">
  32. {{ `¥${item.price}` }}
  33. </view>
  34. </view>
  35. </view>
  36. </view>
  37. </template>
  38. <script setup>
  39. import { reactive } from 'vue'
  40. import { onShow } from '@dcloudio/uni-app'
  41. import { usePageList } from "@/utils/pageList";
  42. const tabs = reactive([
  43. {
  44. title: '收入明细',
  45. value: '0',
  46. },
  47. {
  48. title: '支出明细',
  49. value: '1',
  50. },
  51. ])
  52. // todo
  53. const { queryParams, list, total, getData } = usePageList()
  54. onShow(() => {
  55. list.value = [
  56. {
  57. title: '提现',
  58. price: 168,
  59. status: '1',
  60. createTime: '2020-12-29 12:54:54'
  61. },
  62. {
  63. title: '提现',
  64. price: 168,
  65. status: '1',
  66. createTime: '2020-12-29 12:54:54'
  67. },
  68. {
  69. title: '提现',
  70. price: 168,
  71. status: '1',
  72. createTime: '2020-12-29 12:54:54'
  73. },
  74. ]
  75. })
  76. </script>
  77. <style lang="scss" scoped>
  78. .box {
  79. width: 750rpx;
  80. height: 1452rpx;
  81. background-color: #FFFFFF;
  82. padding: 2% 2% 0 2%;
  83. box-sizing: border-box;
  84. }
  85. .top {
  86. width: 722rpx;
  87. height: 63rpx;
  88. background-color: #F3F3F3;
  89. }
  90. .element {
  91. border-radius: 32rpx;
  92. &.is-active {
  93. background-color: #FFBF60;
  94. color: white;
  95. }
  96. }
  97. .income {
  98. width: 361rpx;
  99. height: 63rpx;
  100. line-height: 63rpx;
  101. font-size: 30rpx;
  102. justify-content: center;
  103. }
  104. .Recharge {
  105. padding: 20rpx 0;
  106. box-sizing: border-box;
  107. justify-content: space-between;
  108. border-bottom: 1rpx solid #E0E0E0;
  109. }
  110. .flex {
  111. display: flex;
  112. }
  113. .text1 {
  114. font-size: 30rpx;
  115. color: #949494;
  116. }
  117. .Recharge image {
  118. width: 56rpx;
  119. height: 56rpx;
  120. margin-top: 0.5%;
  121. }
  122. .text2 {
  123. font-weight: 700;
  124. color: #333333;
  125. }
  126. .text3 {
  127. color: #FF2A2A;
  128. }
  129. </style>