user_spread_money.vue 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165
  1. <template>
  2. <view>
  3. <view class='commission-details'>
  4. <view class='promoterHeader bg-color'>
  5. <view class='headerCon acea-row row-between-wrapper'>
  6. <view>
  7. <view class='name'>{{name}}</view>
  8. <view class='money'>¥<text class='num'>{{recordCount}}</text></view>
  9. </view>
  10. <view class='iconfont icon-jinbi1'><image src='https://hy.liuniu946.com/app/img/yj.png' mode=""></image> </view>
  11. </view>
  12. </view>
  13. <view class='sign-record'>
  14. <block v-for="(item,index) in recordList" :key="index" v-if="recordList.length>0">
  15. <view class="time">{{item.time}}</view>
  16. <block >
  17. <view class='list' v-for="(t,i) in item.list">
  18. <view class='item'>
  19. <view class='listn'>
  20. <view class='itemn acea-row row-between-wrapper'>
  21. <view>
  22. <view class='name line1'>{{t.title}}</view>
  23. <view class="time">{{t.add_time}}</view>
  24. </view>
  25. <view class='num' v-if="t.pm==0">-{{t.number}}</view>
  26. <view class='num font-color' v-else>+{{t.number}}</view>
  27. </view>
  28. </view>
  29. </view>
  30. </view>
  31. </block>
  32. </block>
  33. <view v-if="recordList.length == 0">
  34. <emptyPage title='暂无记录~'></emptyPage>
  35. </view>
  36. </view>
  37. </view>
  38. </view>
  39. </template>
  40. <script>
  41. import {
  42. getCommissionInfo,
  43. spreadCount,
  44. getSpreadInfo,
  45. extractLst,
  46. spreadInfo
  47. } from '@/api/user.js';
  48. import { cashList, userBalance,spreadCommission} from '@/api/wallet.js';
  49. import {
  50. toLogin
  51. } from '@/libs/login.js';
  52. import emptyPage from '@/components/emptyPage.vue'
  53. export default {
  54. components: {
  55. emptyPage
  56. },
  57. data() {
  58. return {
  59. name: '佣金列表',
  60. type: 0,
  61. page: 1,
  62. limit: 12,
  63. recordList: [],
  64. recordType: 0,
  65. recordCount: 0,
  66. status: false,
  67. extractCount: 0,
  68. };
  69. },
  70. onLoad(options) {
  71. },
  72. onShow: function() {
  73. let type = this.type;
  74. uni.setNavigationBarTitle({
  75. title: "佣金列表"
  76. });
  77. this.recordType = 2;
  78. this.spreadInfo();
  79. this.getRecordList();
  80. },
  81. methods: {
  82. spreadInfo(){
  83. let that=this;
  84. spreadInfo().then(res => {
  85. that.recordCount = res.data.commissionCount;
  86. that.extractCount = res.data.extractCount;
  87. });
  88. },
  89. getRecordList: function() {
  90. console.log("0000")
  91. let that = this;
  92. let page = that.page;
  93. let limit = that.limit;
  94. let status = that.status;
  95. let recordType = that.recordType;
  96. let recordList = that.recordList;
  97. let recordListNew = [];
  98. spreadCommission({
  99. page: page,
  100. limit: limit
  101. },3)
  102. .then(res => {
  103. let ln=res.data.length;
  104. console.log(ln)
  105. let recordListData =res.data;
  106. recordListNew = recordList.concat(recordListData);
  107. that.page+=1;
  108. that.$set(that, 'recordList', recordListNew);
  109. });
  110. console.log(recordList.length)
  111. },
  112. },
  113. }
  114. </script>
  115. <style scoped lang="scss">
  116. .sign-record .num{
  117. color: red;
  118. }
  119. .time{
  120. margin: 10rpx;
  121. font-size: 24rpx;
  122. color: #606266;
  123. }
  124. .list{
  125. border-radius: 10rpx;
  126. background-color: #fff;
  127. padding: 10rpx;
  128. width: 98%;
  129. margin: 1%;
  130. }
  131. .icon-jinbi1 image{
  132. opacity: 0.6;
  133. margin: 40rpx;
  134. width: 120rpx;
  135. height: 120rpx;
  136. }
  137. .bg-color{
  138. color: #fff;
  139. border-bottom-left-radius: 20rpx;
  140. border-bottom-right-radius: 20rpx;
  141. height: 220rpx;
  142. background-color: #f75022 !important;
  143. }
  144. .commission-details .promoterHeader .headerCon .money {
  145. margin: 10rpx;
  146. font-size: 36rpx;
  147. }
  148. .commission-details .promoterHeader .headerCon .money .num {
  149. font-family: 'Guildford Pro';
  150. }
  151. .message{
  152. font-size: 18rpx;
  153. color: #fc4141;
  154. }
  155. .name {
  156. margin:20rpx;
  157. }
  158. </style>