untransferredRecords.vue 7.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347
  1. <template>
  2. <view class="">
  3. <public-module></public-module>
  4. <u-sticky h5-nav-height="0">
  5. <view class="headers dis a-c j-start">
  6. <u-icon name="arrow-left" color="#333" size="38" @click="back"></u-icon>
  7. <text style="margin: auto;">未转入记录</text>
  8. </view>
  9. <view class="performance dis f-c ">
  10. <text>共有 {{total}}元未转入</text>
  11. <text>您的每一个等级收益需要手动转入钱包中,才可以将收益提现</text>
  12. </view>
  13. </u-sticky>
  14. <!-- 列表数据 -->
  15. <view class="content">
  16. <view class="item dis a-c j-s" v-for="(item,index) in transferRecords" :key="index" @click="Records(item)">
  17. <text>{{item.gradeName}}</text>
  18. <text class="font-weight">{{item.cashFee}}</text>
  19. <u-icon class="ml-1" name="arrow-right" color="#999" size="22"></u-icon>
  20. </view>
  21. </view>
  22. <u-loadmore v-if="userlist.length!=0" :status="status" />
  23. <!-- 钱包转入 -->
  24. <u-popup v-model="roleCommInShow" mode="center" border-radius="10">
  25. <view class=" roleCommInClass dis f-c a-c">
  26. <text class="title font-weight mt-3">佣金转入钱包</text>
  27. <view class="dis f-c p-3 content">
  28. <text>您的每一个等级收益需要手动转入钱包中,才可以将收益提现</text>
  29. <view class="mt-1 ">
  30. <text>{{Recordsitem.cashFee}}元</text>
  31. <text class="ml-2" style="color: #2D6DFF;" @click="transferAll">全部转入</text>
  32. </view>
  33. <u-input v-model="amount" class="mt-1" type="digit" :border="true" placeholder="输入转入金额" focus />
  34. </view>
  35. </view>
  36. <view class="roleCommInClass-footer dis a-c j-s ">
  37. <view class="dis a-c j-c" @click="roleCommInShow=false">取消</view>
  38. <view class="dis a-c j-c" @click="roleCommInconfirm">确认</view>
  39. </view>
  40. </u-popup>
  41. </view>
  42. </template>
  43. <script>
  44. import myDatePicker from '../components/todaydate-picker.vue';
  45. export default {
  46. components: {
  47. myDatePicker
  48. },
  49. data() {
  50. return {
  51. amount: null, //转入佣金
  52. roleCommInShow: false,
  53. tablist: [],
  54. total: "",
  55. referrerInfo: {}, //个人信息
  56. userlist: [],
  57. pageQuery: {
  58. endTime: "",
  59. startTime: "",
  60. grade: "",
  61. gradeName: "",
  62. appStatus: '',
  63. pageNum: 1,
  64. pageSize: 10,
  65. },
  66. status: 'loadmore',
  67. totalPages: 0,
  68. parentStatus: "",
  69. transferRecords: [],
  70. Recordsitem: {},
  71. statusFilterShow: false,
  72. quickOptions: [{
  73. label: "全部",
  74. value: null,
  75. },
  76. {
  77. label: "正常",
  78. value: "0",
  79. },
  80. {
  81. label: "已冻结",
  82. value: "1",
  83. },
  84. {
  85. label: "已失效",
  86. value: "2",
  87. }
  88. ],
  89. }
  90. },
  91. onReachBottom() {
  92. // if (this.pageQuery.pageNum >= this.totalPages) return;
  93. // this.status = 'loading';
  94. // this.pageQuery.pageNum = ++this.pageQuery.pageNum;
  95. // setTimeout(async () => {
  96. // let res = await this.$http.post('/newAppPartner/selectByIdList', this.pageQuery);
  97. // if (res.code == '200') {
  98. // this.userlist = [...this.userlist, ...res.data.list.records];
  99. // }
  100. // if (this.pageQuery.pageNum >= this.totalPages) this.status = 'nomore';
  101. // else this.status = 'loading';
  102. // }, 1000)
  103. },
  104. onLoad(options) {
  105. this.pageQuery.grade = options.grade;
  106. this.querydata();
  107. },
  108. computed: {
  109. },
  110. methods: {
  111. Records(item) {
  112. this.Recordsitem = item;
  113. this.roleCommInShow = true;
  114. },
  115. //全部转入
  116. transferAll() {
  117. this.amount = this.Recordsitem.cashFee;
  118. },
  119. //角色佣金转入
  120. async roleCommInconfirm() {
  121. if (Number(this.amount) > this.Recordsitem.cashFee) {
  122. return uni.showToast({
  123. title: '转入金额不能大于可转入金额',
  124. icon: 'none',
  125. });
  126. }
  127. if (Number(this.amount) <= 0) {
  128. return uni.showToast({
  129. title: '转入金额不能为0',
  130. icon: 'none',
  131. });
  132. }
  133. let res = await this.$http.post('/partnerExtractHistory/extractRecords', {
  134. grade: this.Recordsitem.grade,
  135. amount: this.amount,
  136. });
  137. if (res.code == 200) {
  138. this.roleCommInShow = false;
  139. this.querydata();
  140. } else {
  141. uni.showToast({
  142. title: res.msg,
  143. icon: 'none',
  144. });
  145. }
  146. },
  147. gradeText(grade) {
  148. const gradeMap = {
  149. 1: '创始人',
  150. 2: '管理人',
  151. 3: '合伙人',
  152. 4: '工作室'
  153. }
  154. return gradeMap[grade] || ''
  155. },
  156. back() {
  157. uni.navigateBack({
  158. delta: 1, // 返回的页面数,如果是1表示返回上一页
  159. success: function() {}
  160. });
  161. },
  162. async querydata() {
  163. let res = await this.$http.get('/partnerExtractHistory/queryExtractRecords')
  164. if (res.code == 200) {
  165. this.transferRecords = res.data.list;
  166. this.total = res.data.total;
  167. }
  168. },
  169. toReacors(id) {
  170. uni.navigateTo({
  171. url: "/pages/institutional/accountFreezeRecord?id=" + id + '&&grade=' + this.$route.query
  172. .grade + '&&type=2'
  173. })
  174. },
  175. //激活时间选择组件
  176. searchPopup() {
  177. this.$refs.datePicker.open()
  178. },
  179. //日期选择回调
  180. confirmPickDate(startdate, enddate) {
  181. this.pageQuery.startTime = startdate;
  182. this.pageQuery.endTime = enddate;
  183. },
  184. statusFilterConfirm(item) {
  185. console.log(item);
  186. this.pageQuery.grade = item.grade;
  187. this.pageQuery.gradeName = item.gradeName;
  188. this.querydata();
  189. this.statusFilterShow = false;
  190. },
  191. }
  192. }
  193. </script>
  194. <style lang="scss" scoped>
  195. .headers {
  196. width: 100%;
  197. z-index: 999999;
  198. padding: 30rpx;
  199. padding-top: 50px;
  200. background: linear-gradient(180deg, #D1EFFE 0%, #FFFFFF 100%);
  201. border-bottom: 1rpx solid #f2f2f2;
  202. text {
  203. font-size: 36rpx;
  204. font-weight: bold;
  205. color: #000;
  206. }
  207. .right {
  208. position: absolute;
  209. right: 30rpx;
  210. image {
  211. width: 28rpx;
  212. height: 28rpx;
  213. margin-right: 4rpx;
  214. }
  215. text {
  216. font-weight: 400;
  217. color: #000;
  218. font-size: 24rpx;
  219. }
  220. }
  221. }
  222. //业绩
  223. .performance {
  224. width: 100%;
  225. background: #EBF4FF;
  226. border-radius: 0rpx 0rpx 0rpx 0rpx;
  227. padding: 20rpx 30rpx;
  228. box-sizing: border-box;
  229. color: #2B67EF;
  230. text:first-child {
  231. font-size: 30rpx;
  232. font-weight: bold;
  233. line-height: 1.5;
  234. }
  235. text:last-child {
  236. font-size: 28rpx;
  237. font-weight: 400;
  238. line-height: 1.5;
  239. }
  240. }
  241. //时间筛选
  242. .filterTime {
  243. width: 100%;
  244. background: #fff;
  245. border-radius: 0rpx 0rpx 0rpx 0rpx;
  246. padding: 20rpx 30rpx;
  247. box-sizing: border-box;
  248. text:first-child {
  249. font-size: 26rpx;
  250. color: #333;
  251. }
  252. text:last-child {
  253. font-size: 19rpx;
  254. color: #666;
  255. margin-left: 4rpx;
  256. }
  257. }
  258. .content {
  259. margin: 20rpx 30rpx;
  260. box-sizing: border-box;
  261. background-color: #FFFFFF;
  262. border-radius: 10rpx 10rpx 10rpx 10rpx;
  263. padding: 0 30rpx;
  264. box-sizing: border-box;
  265. .item {
  266. font-size: 30rpx;
  267. color: #333;
  268. padding: 24rpx 0 30rpx;
  269. border-bottom: 1rpx solid #eee;
  270. text:first-child {
  271. margin-right: auto;
  272. }
  273. }
  274. .item:last-child {
  275. border: none;
  276. }
  277. }
  278. .roleCommInClass {
  279. width: 600rpx;
  280. border-radius: 10rpx;
  281. box-sizing: border-box;
  282. font-size: 26rpx;
  283. .title {
  284. font-size: 32rpx;
  285. color: #333;
  286. }
  287. .content {
  288. text:nth-child(1) {
  289. font-size: 28rpx;
  290. color: #333;
  291. }
  292. text:nth-child(2) {
  293. font-size: 26rpx;
  294. color: #666;
  295. }
  296. }
  297. }
  298. .roleCommInClass-footer {
  299. width: 100%;
  300. border-top: 1rpx solid #eee;
  301. view {
  302. width: 49%;
  303. padding: 24rpx;
  304. box-sizing: border-box;
  305. }
  306. view:first-child {
  307. border-right: 1rpx solid #eee;
  308. }
  309. view:last-child {
  310. color: #2D6DFF;
  311. }
  312. }
  313. </style>