小程序端工程代码
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.

106 lines
3.0 KiB

  1. <template>
  2. <view class="my-promotion">
  3. <view class="header">
  4. <view class="name acea-row row-center-wrapper">
  5. <view>当前佣金</view>
  6. <view class="record" @click="goCashRecord()">
  7. 提现记录
  8. <text class="iconfont icon-xiangyou"></text>
  9. </view>
  10. </view>
  11. <view class="num">{{ Info.commissionCount }}</view>
  12. <view class="profit acea-row row-between-wrapper">
  13. <view class="item">
  14. <view>昨日收益</view>
  15. <view class="money">{{ Info.lastDayCount }}</view>
  16. </view>
  17. <view class="item">
  18. <view>累积已提</view>
  19. <view class="money">{{ Info.extractCount }}</view>
  20. </view>
  21. </view>
  22. </view>
  23. <view class="list acea-row row-between-wrapper">
  24. <view class="item acea-row row-center-wrapper row-column" @click="goPoster()">
  25. <text class="iconfont icon-erweima"></text>
  26. <view>推广名片</view>
  27. </view>
  28. <view class="item acea-row row-center-wrapper row-column" @click="goPromoterList()">
  29. <text class="iconfont icon-tongji"></text>
  30. <view>推广人统计</view>
  31. </view>
  32. <view class="item acea-row row-center-wrapper row-column" @click="goCommissionDetails()">
  33. <text class="iconfont icon-qiandai"></text>
  34. <view>佣金明细</view>
  35. </view>
  36. <view class="item acea-row row-center-wrapper row-column" @click="goPromoterOrder()">
  37. <text class="iconfont icon-dingdan"></text>
  38. <view>推广人订单</view>
  39. </view>
  40. <view class="item acea-row row-center-wrapper row-column" @click="toCash()">
  41. <text class="iconfont icon-chongzhi"></text>
  42. <view>立即提现</view>
  43. </view>
  44. </view>
  45. </view>
  46. </template>
  47. <script>
  48. import { getSpreadInfo } from "@/api/user";
  49. export default {
  50. name: "UserPromotion",
  51. components: {},
  52. props: {},
  53. data: function() {
  54. return {
  55. Info: {
  56. lastDayCount: 0,
  57. extractCount: 0,
  58. commissionCount: 0
  59. }
  60. };
  61. },
  62. mounted: function() {
  63. this.getInfo();
  64. },
  65. methods: {
  66. goPoster() {
  67. this.$yrouter.push("/pages/user/promotion/Poster/index");
  68. },
  69. goCashRecord() {
  70. this.$yrouter.push("/pages/user/promotion/CashRecord/index");
  71. },
  72. goPromoterList() {
  73. this.$yrouter.push("/pages/user/promotion/PromoterList/index");
  74. },
  75. goCommissionDetails() {
  76. this.$yrouter.push("/pages/user/promotion/CommissionDetails/index");
  77. },
  78. goPromoterOrder() {
  79. this.$yrouter.push("/pages/user/promotion/PromoterOrder/index");
  80. },
  81. getInfo: function() {
  82. let that = this;
  83. getSpreadInfo().then(
  84. res => {
  85. that.Info = res.data;
  86. },
  87. function(err) {
  88. uni.showToast({
  89. title: err.msg || err.response.data.msg|| err.response.data.message,
  90. icon: 'none',
  91. duration: 2000
  92. });
  93. }
  94. );
  95. },
  96. toCash: function() {
  97. this.$yrouter.push({ path: "/pages/user/promotion/UserCash/index" });
  98. }
  99. }
  100. };
  101. </script>
  102. <style lang="less">
  103. </style>