Distribution.vue 7.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262
  1. <template>
  2. <view class="Distribution">
  3. <view class="top-view">
  4. <view class="lever-view clearfix">
  5. <view class="lever-view-left float_left">
  6. <image class="user-avator" :src="avator" mode="aspectFill"></image>
  7. <text>{{ businessman_detail.gradeName }}</text>
  8. </view>
  9. <view class="float_right ew-code" @click="goPage('/pagesT/Distribution/Poster')"><text class="ibonfont ibonerweima-copy"></text></view>
  10. </view>
  11. <view class="cash-out clearfix">
  12. <view class="float_left">
  13. <view class="cash-tit">{{ text_set.commission_w || '可提现佣金' }}(元)</view>
  14. <view class="cash-num">{{ businessman_detail.balance || 0 }}</view>
  15. </view>
  16. <view class="float_right" @click="goPage('/pagesT/Distribution/Withdrawal?balance=' + (businessman_detail.balance || 0) + '&id=' + businessman_detail.id)">
  17. <view class="cash-btn">{{ text_set.withdrawal || '提现' }}</view>
  18. </view>
  19. </view>
  20. <view class="money-num">
  21. <view class="money-num-li" @click="goAddUpMoney">
  22. <text>{{ text_set.commission_c || '累计佣金' }}</text>
  23. <view class="money-num-text">
  24. <text class="rmb-icon">¥</text>
  25. {{ businessman_detail.totalMoney || 0 }}
  26. </view>
  27. </view>
  28. <view class="money-num-li" @click="goPage('/pagesT/Distribution/NotRecorded?waitMoney=' + businessman_detail.waitMoney || 0)">
  29. <text>{{ text_set.commission_r || '待入账佣金' }}</text>
  30. <view class="money-num-text">
  31. <text class="rmb-icon">¥</text>
  32. {{ businessman_detail.waitMoney || 0 }}
  33. </view>
  34. </view>
  35. </view>
  36. </view>
  37. <view class="handel-ul">
  38. <view class="handel-li clearfix" @click="goPage('/pagesT/Distribution/DOrder?id=' + businessman_detail.id)">
  39. <view class="float_left icon-left-view"><text class="ibonfont ibondingdan icon-left" style="color:#f46248"></text></view>
  40. <view class="float_left clearfix handel-right">
  41. <text class="float_left">{{ text_set.distribution_order || '分销订单' }}</text>
  42. <view class="float_right handel-right-r">
  43. <text>{{ businessman_detail.statistics.orderNum || 0 }}笔</text>
  44. <text class="ibonfont ibonjinru"></text>
  45. </view>
  46. </view>
  47. </view>
  48. <view class="handel-li clearfix" @click="goPage('/pagesT/Distribution/MyGroup?id=' + businessman_detail.id)">
  49. <view class="float_left icon-left-view"><text class="ibonfont ibonicon-test icon-left" style="color:#f46248"></text></view>
  50. <view class="float_left clearfix handel-right">
  51. <text class="float_left">{{ text_set.self || '我的团队' }}</text>
  52. <view class="float_right handel-right-r">
  53. <text>{{ businessman_detail.statistics.sub || 0 }}人</text>
  54. <text class="ibonfont ibonjinru"></text>
  55. </view>
  56. </view>
  57. </view>
  58. <view class="handel-li clearfix" @click="goPage('/pagesT/Distribution/IncomeDetails?id=' + businessman_detail.id)">
  59. <view class="float_left icon-left-view"><text class="ibonfont ibontixian icon-left" style="color:#46c09b"></text></view>
  60. <view class="float_left clearfix handel-right">
  61. <text class="float_left">{{ text_set.withdrawal_m || '提现明细' }}</text>
  62. <view class="float_right handel-right-r"><text class="ibonfont ibonjinru"></text></view>
  63. </view>
  64. </view>
  65. <view class="handel-li clearfix" @click="goPage('/pagesT/Distribution/GradeDescription?gradeName=' + businessman_detail.gradeName)">
  66. <view class="float_left icon-left-view"><text class="ibonfont ibonhuiyuan icon-left" style="color:#2d5dc9"></text></view>
  67. <view class="float_left clearfix handel-right">
  68. <text class="float_left">等级说明</text>
  69. <view class="float_right handel-right-r"><text class="ibonfont ibonjinru"></text></view>
  70. </view>
  71. </view>
  72. <view class="handel-li clearfix" @click="goPage('/pagesT/Distribution/Ranking?id=' + businessman_detail.id)">
  73. <view class="float_left icon-left-view"><text class="ibonfont ibondianshang icon-left" style="color:#fed261"></text></view>
  74. <view class="float_left clearfix handel-right">
  75. <text class="float_left">排行榜</text>
  76. <view class="float_right handel-right-r"><text class="ibonfont ibonjinru"></text></view>
  77. </view>
  78. </view>
  79. </view>
  80. </view>
  81. </template>
  82. <script>
  83. import { getAvator } from '@/access/common.js';
  84. export default {
  85. data() {
  86. return {
  87. isLoding: false,
  88. text_set: {},
  89. avator: '',
  90. businessman_detail: {
  91. statistics: {}
  92. }
  93. };
  94. },
  95. onShareAppMessage() {
  96. return {
  97. title: this.$store.state.baseSet.shop,
  98. path: '/pages/index/index?businessmanId=' + this.$store.state.userStatus.id,
  99. imageUrl: this.$store.state.baseSet.images,
  100. success: res => {
  101. console.log(res);
  102. }
  103. };
  104. },
  105. // 下拉刷新
  106. onPullDownRefresh() {
  107. this.getInfoBusinessman();
  108. },
  109. onLoad() {
  110. uni.setNavigationBarColor({
  111. frontColor: '#ffffff',
  112. backgroundColor: '#fe582e'
  113. });
  114. this.text_set = this.$store.state.distributionTextSet;
  115. this.avator = getAvator();
  116. },
  117. onShow() {
  118. this.getInfoBusinessman();
  119. },
  120. methods: {
  121. goAddUpMoney() {
  122. this.goPage(
  123. `/pagesT/Distribution/AddUpMoney?id=${this.businessman_detail.id}&totalMoney=${this.businessman_detail.totalMoney || 0}&waitMoney=${this.businessman_detail
  124. .waitMoney || 0}&balance=${this.businessman_detail.balance || 0}&auditWithdraw=${this.businessman_detail.auditWithdraw || 0}&waitAuditWithdraw=${this
  125. .businessman_detail.waitAuditWithdraw || 0}`
  126. );
  127. },
  128. // 分销商详情
  129. getInfoBusinessman() {
  130. this.$u.api.getInfoBusinessman().then(res=>{
  131. uni.stopPullDownRefresh();
  132. this.businessman_detail = res.data;
  133. });
  134. }
  135. }
  136. };
  137. </script>
  138. <style lang="scss">
  139. body {
  140. background: $page-color-base;
  141. }
  142. .top-view {
  143. color: #ffffff;
  144. background-color: #fe582e;
  145. .lever-view {
  146. padding: 30upx 24upx;
  147. .lever-view-left {
  148. font-size: 22upx;
  149. font-weight: bold;
  150. line-height: 38upx;
  151. height: 42upx;
  152. padding-right: 16upx;
  153. border-radius: 22upx;
  154. background-color: rgba($color: #ffffff, $alpha: 0.3);
  155. text {
  156. transform: translateY(4upx);
  157. display: inline-block;
  158. }
  159. .user-avator {
  160. margin-right: 8upx;
  161. width: 42upx;
  162. height: 42upx;
  163. border-radius: 100%;
  164. vertical-align: middle;
  165. transform: translateY(-2upx);
  166. }
  167. }
  168. .ew-code {
  169. line-height: 36upx;
  170. height: 36upx;
  171. opacity: 0.5;
  172. .ibonerweima-copy {
  173. font-size: 48upx;
  174. }
  175. }
  176. }
  177. .cash-out {
  178. padding: 0 24upx 30upx;
  179. .cash-tit {
  180. font-size: 24upx;
  181. }
  182. .cash-num {
  183. font-size: 60upx;
  184. font-weight: bold;
  185. padding-top: 20upx;
  186. }
  187. .cash-btn {
  188. margin-top: 76upx;
  189. font-size: 24upx;
  190. width: 146upx;
  191. height: 46upx;
  192. line-height: 46upx;
  193. text-align: center;
  194. background-color: #ffffff;
  195. border-radius: 40upx;
  196. color: #fe582e;
  197. }
  198. }
  199. .money-num {
  200. background-color: #f03b28;
  201. display: flex;
  202. padding: 34upx 0;
  203. .money-num-li {
  204. flex: 2;
  205. font-size: 24upx;
  206. padding-left: 24upx;
  207. &:first-child {
  208. border-right: 1px solid rgba($color: #ffffff, $alpha: 0.3);
  209. }
  210. .money-num-text {
  211. font-size: 32upx;
  212. margin-left: 16upx;
  213. display: inline-block;
  214. transform: translateY(4upx);
  215. .rmb-icon {
  216. font-size: 24upx;
  217. margin-right: 6upx;
  218. }
  219. }
  220. }
  221. }
  222. }
  223. .handel-ul {
  224. .handel-li {
  225. background-color: #ffffff;
  226. padding-left: 20upx;
  227. line-height: 100upx;
  228. font-size: 28upx;
  229. .icon-left-view {
  230. line-height: 100upx;
  231. height: 100upx;
  232. .icon-left {
  233. font-size: 36upx;
  234. margin-right: 30upx;
  235. }
  236. }
  237. .handel-right {
  238. width: 660upx;
  239. border-bottom: 1px solid #f5f5f5;
  240. .handel-right-r {
  241. color: #999999;
  242. padding-right: 20upx;
  243. .ibonjinru {
  244. font-size: 28upx;
  245. margin-left: 20upx;
  246. }
  247. }
  248. }
  249. &:last-child {
  250. .handel-right {
  251. border-bottom: 0 none;
  252. }
  253. }
  254. }
  255. }
  256. </style>