awards.vue 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107
  1. <template>
  2. <view>
  3. <view class="bg-img" style="background-image: url('https://upload-file-data.obs.cn-south-1.myhuaweicloud.com/5f263a5a6e7c4f2493e0325f28ab659a-bgimg.png');height: 310upx;"></view>
  4. <view class="container" style="margin: -80upx 30upx 30upx 30upx;">
  5. <view class="padding">
  6. <text class="text-bold text-black padding-right-sm">账户热力值</text>
  7. <text class="text-bold" style="color: #f87a3a;">可兑换到账{{data.totalWithDraw}}元</text>
  8. </view>
  9. <view class="padding-lr flex justify-between align-center">
  10. <view>
  11. <text
  12. style="font-size: 60upx;font-family: PingFang SC;font-weight: 800;color: #F3484E;">{{data.usableHotValue}}</text>
  13. <text class="padding-left-xs"
  14. style="font-size: 24upx;font-family: PingFang SC;font-weight: 800;color: #878787;">热力值</text>
  15. </view>
  16. <button class="cu-btn round text-white" style="background-color: #f75757;width: 140upx;">提现</button>
  17. </view>
  18. <view style="margin: 10upx 20upx;">
  19. <u-line color="#e0e0e0"></u-line>
  20. </view>
  21. <view style="padding: 20upx 0upx 0upx 30upx;">
  22. <text class="title">已提现:</text>
  23. <text class="number">{{data.withdrawed}}</text>
  24. <text class="title padding-left-xs">元</text>
  25. </view>
  26. <view style="padding: 10upx 0upx 20upx 30upx;">
  27. <text class="title">可提现:</text>
  28. <text class="number">{{data.usableWithdraw}}</text>
  29. <text class="title padding-left-xs">元</text>
  30. </view>
  31. </view>
  32. <view class="container margin-lr">
  33. <view class="padding flex align-center">
  34. <view class="cuIcon-text text-bold padding-right-xs" style="font-size: 38upx;"></view>
  35. <view class="title">提现明细</view>
  36. </view>
  37. <view v-for="(item, index) in list" :key="index" class="flex align-center justify-between">
  38. <view class="padding-lr">
  39. <view class="title">{{item.note}}</view>
  40. <view style="font-size: 24upx;font-family: PingFang SC;font-weight: bold;color: #686868;">
  41. {{item.createTime}}</view>
  42. </view>
  43. <view class="padding-right">
  44. <text style="font-size: 36upx;font-family: PingFang SC;font-weight: bold;color: #F3484E;">+{{ +item.hotValue}}</text>
  45. <text class="text-bold padding-left-xs">元</text>
  46. </view>
  47. </view>
  48. <view style="padding: 20upx;">
  49. <u-line color="#e0e0e0"></u-line>
  50. </view>
  51. </view>
  52. <view style="height: 30upx;"></view>
  53. </view>
  54. </template>
  55. <script>
  56. export default {
  57. data() {
  58. return {
  59. userId: '',
  60. data: {},
  61. list:[]
  62. }
  63. },
  64. onLoad() {
  65. this.userId = uni.getStorageSync("userId") || -1;
  66. this.getBonus()
  67. this.getList()
  68. },
  69. methods: {
  70. getBonus() {
  71. this.$u.api.user.getBonus({
  72. userId: this.userId
  73. }).then(res => {
  74. this.data = res
  75. })
  76. },
  77. getList() {
  78. this.$u.api.user.withdrawrecords({userId: this.userId}).then(res => {
  79. this.list = res.records
  80. })
  81. }
  82. }
  83. }
  84. </script>
  85. <style>
  86. .container {
  87. background-color: #FFFFFF;
  88. border-radius: 16upx;
  89. box-shadow: 0px 3px 79px 0px rgba(132, 132, 132, 0.22);
  90. }
  91. .title {
  92. font-size: 28upx;
  93. font-family: PingFang SC;
  94. font-weight: 800;
  95. color: #000000;
  96. }
  97. .number {
  98. font-size: 30upx;
  99. font-family: PingFang SC;
  100. font-weight: 800;
  101. color: #F3484E;
  102. }
  103. </style>