hx-invite.vue 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598
  1. <template>
  2. <view>
  3. <u-checkbox-group v-model="arralylist" placement="column" @change="checkboxChange">
  4. <view class="yong" style="margin-top: 20rpx;" v-for="(item,index) in list" :key="index">
  5. <view class="u-flex">
  6. <view class="" style="flex: 1;">
  7. <view class="u-flex u-row-between">
  8. <view class="order">
  9. 订单编号:{{item.order.order_no}}
  10. </view>
  11. <view class="deposit">
  12. 未提现
  13. </view>
  14. </view>
  15. <view class="u-flex u-row-between dan" style="margin-top: 18rpx;">
  16. <view class="u-flex">
  17. <u-checkbox :name="index"
  18. :disabled="['unapplied','failed'].includes(item.withdraw_status)&&item.is_confirm==0?true : false">
  19. </u-checkbox>
  20. <view class="lietou">{{item.type_name}}</view>
  21. </view>
  22. <view class="red">
  23. <text style="24rpx">¥</text>
  24. <text style="32rpx">{{item.amount}}</text>
  25. </view>
  26. </view>
  27. </view>
  28. </view>
  29. <view class="u-flex u-row-between" style="margin-top:26rpx;">
  30. <text class="date">邀请日期 2023.03.12 12:4</text>
  31. <text class="date1"
  32. v-if="item.is_confirm==1">回款时间:{{item.confirm_time.slice(0,-3).replaceAll("-",".")}}</text>
  33. <text class="date1" v-if="item.is_confirm==0">回款时间:未回款</text>
  34. </view>
  35. </view>
  36. </u-checkbox-group>
  37. <view class="" style="height: 186rpx;background: #F3F3F3;"></view>
  38. <!-- <view class="safe-area-inset-bottom"></view> -->
  39. <view class="bottom-end">
  40. <u-checkbox-group @change="arraly" v-model="checkboxValue1">
  41. <view class="u-flex u-row-between" style="width: 100%;">
  42. <view class="u-flex">
  43. <u-checkbox :name="-2">
  44. </u-checkbox>
  45. <view class="">全选</view>
  46. </view>
  47. <view class="u-flex">
  48. <view class="">
  49. <text class="jine">金额</text>
  50. <text class="red" style="font-size: 24rpx;margin-left: 12rpx;">¥</text>
  51. <text class="red" style="font-size: 36rpx;">{{alla}}</text>
  52. <text class="red" style="font-size: 24rpx;">.00</text>
  53. </view>
  54. <view class="btn" @click="totixian" style="margin-left: 20rpx;">
  55. 立即提现
  56. </view>
  57. </view>
  58. </view>
  59. <view class="safe-area-inset-bottom"></view>
  60. </u-checkbox-group>
  61. </view>
  62. </view>
  63. </template>
  64. <script>
  65. import {
  66. commission_list
  67. } from "@/units/inquire.js"
  68. export default {
  69. data() {
  70. return {
  71. arralylist: [],
  72. checkboxValue1: [],
  73. money: 200.00,
  74. show: false,
  75. showtime: false,
  76. current: 1,
  77. date: "",
  78. all: "",
  79. moneylist: [],
  80. list: [],
  81. allist: [],
  82. list2: [{
  83. label: '订单佣金',
  84. // 其他属性值
  85. source_type: "order"
  86. }, {
  87. label: '邀请佣金',
  88. source_type: "invite"
  89. }],
  90. alllll: 0,
  91. source_type: "order",
  92. label: "订单佣金",
  93. columns: [
  94. [{
  95. label: '订单佣金',
  96. // 其他属性值
  97. source_type: "order"
  98. // ...
  99. }, {
  100. label: '邀请佣金',
  101. source_type: "invite"
  102. }]
  103. ],
  104. list4: [{
  105. name: "佣金明细"
  106. },
  107. {
  108. name: "提现记录"
  109. }
  110. ],
  111. list5: [],
  112. list6: [],
  113. page: 1,
  114. total: 0,
  115. }
  116. },
  117. created() {
  118. this.commission_list()
  119. },
  120. onReachBottom() {
  121. if (this.total != this.list.length) {
  122. this.page++
  123. this.commission_list()
  124. }
  125. },
  126. computed: {
  127. alla() {
  128. var arr = 0
  129. if (this.arralylist.length == this.list5.length) {
  130. this.checkboxValue1 = [-2]
  131. } else {
  132. this.checkboxValue1 = []
  133. }
  134. this.arralylist.forEach(item => {
  135. arr += Number(this.list[item].amount)
  136. })
  137. return arr
  138. },
  139. bgImage() {
  140. return `url(${require('@/static/images/juxing.png')}) 100% 100%`
  141. }
  142. },
  143. methods: {
  144. totixian() {
  145. var id_list = []
  146. this.list.forEach((item, index) => {
  147. if (this.arralylist.indexOf(index) != -1) {
  148. id_list.push(item.id)
  149. }
  150. })
  151. var ids = id_list.join()
  152. if (this.alla > 0) {
  153. uni.navigateTo({
  154. url: "/pagesD/tixian?money=" + this.alla + "&current=" + this.current + "&ids=" + ids
  155. })
  156. } else {
  157. this.$u.toast("提现金额必须大于0")
  158. }
  159. },
  160. ally() {
  161. this.list.forEach((item, index) => {
  162. this.allist.push(index)
  163. })
  164. },
  165. arraly(n) {
  166. if (n.length > 0) {
  167. this.arralylist = []
  168. this.list.forEach((item, index) => {
  169. if (item.is_confirm == 1) {
  170. this.arralylist.push(index)
  171. }
  172. })
  173. // this.arralylist = this.checkboxValue1
  174. }
  175. if (n.length == 0) {
  176. this.arralylist = []
  177. }
  178. },
  179. checkboxChange(n) {
  180. this.arralylist = n
  181. // if (this.arralylist.length == this.list5.length) {
  182. // this.name1 = -2
  183. // }
  184. if (this.arralylist.length == this.list5.length) {
  185. this.checkboxValue1 = [-2]
  186. } else {
  187. this.checkboxValue1 = []
  188. }
  189. },
  190. return1() {
  191. uni.navigateBack()
  192. },
  193. enter(e) {
  194. this.label = e.value[0].label
  195. this.source_type = e.value[0].source_type
  196. this.show = false
  197. },
  198. async changetime(e) {
  199. const timeFormat = uni.$u.timeFormat;
  200. let timeValue = await timeFormat(e.value, 'yyyy-mm');
  201. this.date = timeValue;
  202. this.page = 1
  203. this.total = 0
  204. this.list = []
  205. this.commission_list()
  206. this.showtime = false
  207. },
  208. commission_list() {
  209. commission_list({
  210. page:1,
  211. source_type: "invite",
  212. job_name: "",
  213. is_confirm: "",
  214. begin_time: "",
  215. end_time: "",
  216. time_type: "",
  217. // status: "unapplied"
  218. }).then(res => {
  219. if (this.page == 1) {
  220. this.list = res.data.data
  221. } else {
  222. this.list = this.list.concat(res.data.data)
  223. console.log(this.list);
  224. }
  225. res.data.data.forEach(item => {
  226. if (item.is_confirm == 1) {
  227. this.list5.push(item)
  228. }
  229. })
  230. // this.ally()
  231. })
  232. }
  233. },
  234. }
  235. </script>
  236. <style lang="scss" scoped>
  237. .btn {
  238. width: 184rpx;
  239. height: 72rpx;
  240. background: #0C66C2;
  241. border-radius: 12rpx;
  242. font-size: 30rpx;
  243. font-family: PingFangSC, PingFang SC;
  244. font-weight: 400;
  245. color: #FFFFFF;
  246. line-height: 72rpx;
  247. text-align: center;
  248. }
  249. .jine {
  250. font-size: 24rpx;
  251. font-family: PingFangSC, PingFang SC;
  252. font-weight: 400;
  253. color: #444444;
  254. }
  255. .red {
  256. font-family: JDZhengHT, JDZhengHT;
  257. font-weight: 400;
  258. color: #F2413A;
  259. }
  260. .bottom-end {
  261. width: 750rpx;
  262. height: 166rpx;
  263. background: #FFFFFF;
  264. padding: 16rpx 32rpx 0;
  265. position: fixed;
  266. bottom: 0;
  267. left: 0;
  268. box-sizing: border-box;
  269. }
  270. .date {
  271. font-size: 24rpx;
  272. font-family: PingFangSC-Regular, PingFang SC;
  273. font-weight: 400;
  274. color: #888888;
  275. }
  276. .date1 {
  277. font-size: 24rpx;
  278. font-family: SFPro-Regular, SFPro;
  279. font-weight: 400;
  280. color: #222222;
  281. }
  282. .red {
  283. font-family: JDZhengHT-Regular, JDZhengHT;
  284. font-weight: 400;
  285. color: #F2413A;
  286. }
  287. .lietou {
  288. font-size: 32rpx;
  289. font-family: PingFangSC-Medium, PingFang SC;
  290. font-weight: 500;
  291. color: #222222;
  292. }
  293. .dan {
  294. margin-top: 20rpx;
  295. border-top: 2rpx solid #F6F6F6;
  296. padding-top: 18rpx;
  297. }
  298. .deposit {
  299. border-radius: 6rpx;
  300. background-color: rgba(12, 102, 194, 0.1);
  301. font-size: 24rpx;
  302. font-family: PingFangSC-Regular, PingFang SC;
  303. font-weight: 400;
  304. color: #0C66C2;
  305. padding: 4rpx;
  306. }
  307. .order {
  308. font-size: 24rpx;
  309. font-family: SFPro-Regular, SFPro;
  310. font-weight: 400;
  311. color: #666666;
  312. }
  313. .yong {
  314. background: #FFFFFF;
  315. border-radius: 16rpx;
  316. padding: 20rpx 20rpx 26rpx;
  317. box-sizing: border-box;
  318. .top {
  319. .left {
  320. font-size: 24rpx;
  321. font-family: PingFangSC-Regular, PingFang SC;
  322. font-weight: 400;
  323. color: #555555;
  324. }
  325. .right {
  326. font-family: SFPro-Regular, SFPro;
  327. font-weight: 400;
  328. color: #F2413A;
  329. }
  330. }
  331. .leftf {
  332. font-size: 26rpx;
  333. font-family: PingFangSC-Regular, PingFang SC;
  334. font-weight: 400;
  335. color: #555555;
  336. margin-top: 20rpx;
  337. }
  338. .leftff {
  339. font-size: 26rpx;
  340. font-family: PingFangSC-Regular, PingFang SC;
  341. font-weight: 400;
  342. color: #555555;
  343. }
  344. }
  345. .list1 {
  346. background: #FFFFFF;
  347. border-radius: 16rpx;
  348. .data {
  349. font-size: 24rpx;
  350. font-family: PingFangSC-Regular, PingFang SC;
  351. font-weight: 400;
  352. color: #888888;
  353. }
  354. .data1 {
  355. font-size: 24rpx;
  356. font-family: PingFangSC-Regular, PingFang SC;
  357. font-weight: 400;
  358. color: #222222;
  359. }
  360. .title {
  361. font-size: 32rpx;
  362. font-family: PingFangSC-Medium, PingFang SC;
  363. font-weight: 500;
  364. color: #222222;
  365. }
  366. .font {
  367. font-size: 24rpx;
  368. font-family: PingFangSC-Regular, PingFang SC;
  369. font-weight: 400;
  370. color: #fff;
  371. opacity: 1;
  372. }
  373. .back {
  374. background: #0C66C2;
  375. border-radius: 6rpx;
  376. padding: 4rpx 8rpx;
  377. opacity: 0.5;
  378. }
  379. .money {
  380. font-size: 24rpx;
  381. font-family: SFPro-Regular, SFPro;
  382. font-weight: 400;
  383. color: #F2413A;
  384. margin-left: 12rpx;
  385. }
  386. }
  387. .page {
  388. height: 100vh;
  389. .content {
  390. padding: 0 24rpx;
  391. background: #F3F3F3;
  392. min-height: 78vh;
  393. padding-top: 20rpx;
  394. min-height: 100vh;
  395. box-sizing: border-box;
  396. .list {
  397. background: #FFFFFF;
  398. border-radius: 16rpx;
  399. padding: 20rpx;
  400. box-sizing: border-box;
  401. }
  402. }
  403. }
  404. .bottom {
  405. border-top: 2rpx solid #F6F6F6;
  406. margin-top: 18rpx;
  407. padding-top: 18rpx;
  408. box-sizing: border-box;
  409. .left {
  410. font-size: 24rpx;
  411. font-family: PingFangSC-Regular, PingFang SC;
  412. font-weight: 400;
  413. color: #555555;
  414. }
  415. .right {
  416. font-size: 24rpx;
  417. font-family: PingFangSC-Regular, PingFang SC;
  418. font-weight: 400;
  419. color: #999999;
  420. }
  421. }
  422. .right {
  423. .concent {
  424. .left {
  425. font-size: 24rpx;
  426. font-family: PingFangSC-Regular, PingFang SC;
  427. font-weight: 400;
  428. color: #222222;
  429. }
  430. .money {
  431. font-size: 24rpx;
  432. font-family: SFPro-Regular, SFPro;
  433. font-weight: 400;
  434. color: #F2413A;
  435. margin-left: 12rpx;
  436. }
  437. .right {
  438. margin-left: 12rpx;
  439. font-size: 24rpx;
  440. font-family: PingFangSC-Regular, PingFang SC;
  441. font-weight: 400;
  442. color: #555555;
  443. }
  444. }
  445. .top {
  446. .left {
  447. font-size: 24rpx;
  448. font-family: PingFangSC-Regular, PingFang SC;
  449. font-weight: 400;
  450. color: #555555;
  451. }
  452. .right {
  453. font-size: 24rpx;
  454. font-family: PingFangSC-Regular, PingFang SC;
  455. font-weight: 400;
  456. color: #555555;
  457. display: inline-block;
  458. width: 170rpx;
  459. overflow: hidden;
  460. text-overflow: ellipsis;
  461. white-space: nowrap;
  462. }
  463. }
  464. }
  465. .left {
  466. // width: 300rpx;
  467. // overflow: hidden;
  468. // text-overflow: ellipsis;
  469. // white-space: nowrap;
  470. .concent {
  471. .left {
  472. font-size: 24rpx;
  473. font-family: PingFangSC-Regular, PingFang SC;
  474. font-weight: 400;
  475. color: #222222;
  476. }
  477. .money {
  478. font-size: 24rpx;
  479. font-family: SFPro-Regular, SFPro;
  480. font-weight: 400;
  481. color: #F2413A;
  482. margin-left: 12rpx;
  483. }
  484. .right {
  485. margin-left: 12rpx;
  486. font-size: 24rpx;
  487. font-family: PingFangSC-Regular, PingFang SC;
  488. font-weight: 400;
  489. color: #555555;
  490. }
  491. }
  492. .top {
  493. .left {
  494. height: 44rpx;
  495. font-size: 32rpx;
  496. font-family: PingFangSC-Medium, PingFang SC;
  497. font-weight: 500;
  498. color: #222222;
  499. }
  500. .right {
  501. margin-left: 12rpx;
  502. font-size: 24rpx;
  503. font-family: PingFangSC-Regular, PingFang SC;
  504. font-weight: 400;
  505. color: #141414;
  506. overflow: hidden;
  507. text-overflow: ellipsis;
  508. white-space: nowrap;
  509. width: 220rpx;
  510. display: inline-block;
  511. }
  512. }
  513. }
  514. .search {
  515. height: 68rpx;
  516. background: #F3F3F3;
  517. border-radius: 38rpx;
  518. padding: 14rpx 28rpx;
  519. box-sizing: border-box;
  520. }
  521. .index-header {
  522. padding: 0 32rpx;
  523. height: 50rpx;
  524. .index-search {
  525. width: 200rpx;
  526. height: 64rpx;
  527. background: #FFFFFF;
  528. border-radius: 20rpx;
  529. padding: 0 28rpx;
  530. .text1 {
  531. font-size: 24rpx;
  532. font-family: PingFangSC-Regular, PingFang SC;
  533. font-weight: 400;
  534. color: #999999;
  535. margin-left: 16rpx;
  536. }
  537. }
  538. }
  539. ::v-deep .u-navbar__content__left {
  540. padding: 0 !important;
  541. }
  542. // ::v-deep .u-subsection__item{
  543. // border-radius: 38rpx;
  544. // }
  545. // ::v-deep .u-subsection--subsection{
  546. // border-radius: 76rpx;
  547. // }
  548. </style>