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.

136 lines
2.6 KiB

6 months ago
  1. <template>
  2. <view>
  3. <view class="top">
  4. <view class="topleft">当前积分:<text class='dqnum'>{{nowjf}}</text></view>
  5. <view class="topright">已消费:<text class='xfnum'>{{xfnow}}</text></view>
  6. <view class="rule" @click="showgz">规则</view>
  7. </view>
  8. <view class="bottom">
  9. <view class="listtitle">
  10. <span>类型</span>
  11. <span>数量</span>
  12. <span>余量</span>
  13. <span>时间</span>
  14. </view>
  15. <view class="list" v-for="(row,index) in list" :key="index" >
  16. <span>{{row.lxtext}}</span>
  17. <span :class="[row.lx>0?'isxiaof':'isshour']">{{row.nums}}</span>
  18. <span>{{row.yunums}}</span>
  19. <span>{{row.rq}}</span>
  20. </view>
  21. </view>
  22. </view>
  23. </template>
  24. <script>
  25. export default {
  26. data() {
  27. return {
  28. nowjf:0,
  29. xfnow:0,
  30. list:[],
  31. shuomtext:''
  32. }
  33. },
  34. onShow(){
  35. let getuserinfo=uni.getStorageSync('userinfo');
  36. this.jifenlist(getuserinfo.uid,getuserinfo.aid);
  37. this.baseinfo('jftip');
  38. },
  39. methods: {
  40. //提现列表
  41. async jifenlist(uid,aid){
  42. let info= await this.$api.jifenlist({action:'jifenlist',uid:uid,aid:aid});
  43. this.list=info.data.list;
  44. this.nowjf=info.data.nowcount;
  45. this.xfnow=info.data.xfcount;
  46. },
  47. async baseinfo(key) {
  48. let reinfo=await this.$api.baseinfo({action:'baseinfo',key:key});
  49. this.shuomtext=reinfo.data.info
  50. },
  51. showgz(){
  52. let t=this;
  53. uni.showModal({
  54. title: '积分规则',
  55. showCancel:false,
  56. confirmText:'已知晓',
  57. content: this.shuomtext,
  58. success: function (res) {}
  59. });
  60. }
  61. }
  62. }
  63. </script>
  64. <style lang='scss'>
  65. .top{
  66. display: flex;
  67. width: 100%;
  68. background-color: #488ED8;
  69. justify-content: space-between;
  70. padding: 20upx;
  71. color: #ffffff;
  72. }
  73. .topleft{
  74. width: 40%;
  75. display: flex;
  76. justify-content: space-around;
  77. text{
  78. font-size: 40upx;
  79. font-weight: bold;
  80. }
  81. border-right: 1upx solid #ffffff;
  82. }
  83. .topright{
  84. width: 40%;
  85. display: flex;
  86. justify-content: space-around;
  87. text{
  88. font-size: 40upx;
  89. font-weight: bold;
  90. }
  91. }
  92. .rule{
  93. width: 15%;
  94. font-size: 30upx;
  95. border: 1upx #fff solid;
  96. padding: 2upx;
  97. border-radius: 25upx;
  98. text-align: center;
  99. display: flex;
  100. align-items: center;
  101. justify-content: center;
  102. }
  103. .listtitle{
  104. display: flex;
  105. justify-content: space-between;
  106. border-bottom: 1upx #F6F6F6 solid;
  107. color: #666666;
  108. padding:10upx 2upx;
  109. span{
  110. width: 25%;
  111. border-right: 1upx #F6F6F6 solid;
  112. text-align: center;
  113. }
  114. }
  115. .list{
  116. display: flex;
  117. justify-content: space-between;
  118. text-align: center;
  119. padding:15upx 2upx;
  120. font-size: 30upx;
  121. span{
  122. width: 25%;
  123. text-align: center;
  124. }
  125. border-bottom: 1upx #F6F6F6 solid;
  126. }
  127. .isshour{
  128. color: #F90101;
  129. }
  130. .isxiaof{
  131. color: #008000;
  132. }
  133. </style>