帧视界壹通告,付费看视频的微信小程序
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.

172 lines
3.5 KiB

1 year ago
1 year ago
  1. <template>
  2. <view class="withdraw">
  3. <!--顶部导航栏-->
  4. <navbar leftClick @leftClick="$utils.navigateBack" title="提现"/>
  5. <!--内容区-->
  6. <view class="content">
  7. <!--上部分-->
  8. <view class="content-top">
  9. <view class="aaa">
  10. <view class="top">{{money.money}}</view>
  11. <view class="bottom">可提现金额</view>
  12. </view>
  13. </view>
  14. <!--下部分-->
  15. <view class="content-bottom">
  16. <view class="inputComponent">
  17. <view class="left">填写提现金额</view>
  18. <view class="centerAndRight">
  19. <view class="center">
  20. <uv-input placeholder="输入金额" v-model="withdrawMoney"
  21. border="none" @change="moneyChange"></uv-input>
  22. </view>
  23. <view class="right" @click="withdrawMoney = money.money">全部提现</view>
  24. </view>
  25. </view>
  26. </view>
  27. </view>
  28. <!--提现按钮-->
  29. <button @click="withdrawPage" class="bottomBtn">
  30. 提现
  31. </button>
  32. </view>
  33. </template>
  34. <script>
  35. import '../../common.css'; // 引入公共 CSS 文件
  36. export default {
  37. data() {
  38. return {
  39. withdrawMoney: "",
  40. money: null,
  41. };
  42. },
  43. onShow() {
  44. this.infoGetInfoMoney()
  45. },
  46. methods: {
  47. // 金额发生变化
  48. moneyChange(e) {
  49. console.log(e)
  50. this.withdrawMoney = e
  51. },
  52. infoGetInfoMoney(){
  53. this.$api('infoGetInfoMoney', res => {
  54. if(res.code == 200){
  55. this.money = res.result
  56. }
  57. })
  58. },
  59. // 提现
  60. withdrawPage() {
  61. this.$api('infoWithdraw', {
  62. withdrawMoney: this.withdrawMoney
  63. }, res => {
  64. if (res.code == 200) {
  65. uni.navigateTo({
  66. url: '/pages_mine/mine/withdrawalRecord'
  67. });
  68. // this.$utils.navigateTo('/pages_mine/mine/withdrawalRecord');
  69. }
  70. })
  71. }
  72. }
  73. }
  74. </script>
  75. <style lang="scss" scoped>
  76. .withdraw {
  77. .content {
  78. .content-top {
  79. display: flex;
  80. flex-direction: column;
  81. align-items: center;
  82. padding-top: 60rpx;
  83. background-color: #f8faff;
  84. height: 10vh;
  85. .aaa {
  86. color: #000000;
  87. .top {
  88. font-size: 50rpx;
  89. }
  90. .bottom {
  91. font-size: 14px;
  92. display: flex;
  93. justify-content: center;
  94. align-items: center;
  95. }
  96. }
  97. }
  98. .content-bottom {
  99. border-radius: 50rpx 50rpx 0 0;
  100. box-shadow: 0 -10rpx 10rpx rgba(0, 0, 0, 0.2); /* 仅上边的阴影效果 */
  101. background-color: #fff;
  102. height: calc(90vh - 240rpx);
  103. //width: 100vw;
  104. padding: 40rpx;
  105. .inputComponent {
  106. display: flex;
  107. //gap: 20rpx;
  108. //border: 1px solid red;
  109. .left {
  110. display: flex;
  111. justify-content: flex-start;
  112. align-items: center;
  113. font-size: 30rpx;
  114. width: 50%;
  115. margin-right: 20rpx;
  116. }
  117. .centerAndRight {
  118. display: flex;
  119. width: 50%;
  120. .center {
  121. width: 60%;
  122. }
  123. .right {
  124. display: flex;
  125. justify-content: flex-end;
  126. align-items: center;
  127. font-size: 32rpx;
  128. margin-left: 20rpx;
  129. width: 40%;
  130. background: $uni-linear-gradient-color;
  131. -webkit-background-clip: text; /*将设置的背景颜色限制在文字中*/
  132. -webkit-text-fill-color: transparent; /*给文字设置成透明*/
  133. }
  134. }
  135. }
  136. }
  137. }
  138. }
  139. </style>