猫妈狗爸伴宠师小程序前端代码
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.

163 lines
3.2 KiB

3 months ago
2 months ago
3 months ago
3 months ago
3 months ago
3 months ago
3 months ago
3 months ago
3 months ago
3 months ago
3 months ago
3 months ago
3 months ago
3 months ago
3 months ago
3 months ago
3 months ago
3 months ago
  1. <template>
  2. <!-- <div>提现</div> -->
  3. <view class="box">
  4. <view class="top" :style="{ borderRadius: '16rpx' }">
  5. <view >
  6. 提现金额
  7. </view>
  8. <view class="level">
  9. <view class="money level">
  10. <text>¥</text>
  11. <up-input class="amount" placeholderClass="placeInput" placeholder="请输入提现金额" clearable fontSize="34rpx"
  12. border="bottom" type="number" color="#FF2742" v-model="num"></up-input>
  13. </view>
  14. <!-- <DForm :list="state. " @submit="handleSubmit" /> -->
  15. </view>
  16. </view>
  17. </view>
  18. <view class="center">
  19. <view class="text">
  20. 提现说明
  21. </view>
  22. <view>
  23. <up-parse :content="configList.withdrawal_statement.paramValueArea" containerStyle="{
  24. color: '#707070',
  25. fontSize: '30rpx',
  26. lineHeight: '45rpx',
  27. }"></up-parse>
  28. </view>
  29. <up-button class="buttom" type="warning" text="提现" shape="circle" @click="cashClick"></up-button>
  30. </view>
  31. <uni-popup ref="inputDialogRef" type="dialog">
  32. <uni-popup-dialog ref="inputClose" mode="input" title="提现" v-model="fullName" placeholder="请输入姓名"
  33. @confirm="dialogInputConfirm" @close="close" :before-close="true"></uni-popup-dialog>
  34. </uni-popup>
  35. </template>
  36. <script setup>
  37. import {
  38. ref,
  39. computed,
  40. } from "vue"
  41. import { useStore } from 'vuex'
  42. const store = useStore()
  43. const configList = computed(() => {
  44. return store.getters.configList
  45. })
  46. const num = ref('');;
  47. const fullName = ref('')
  48. const inputDialogRef = ref(null)
  49. const inputClose = ref(null)
  50. const cashClick = () => {
  51. if (num.value) {
  52. fullName.value = ''
  53. inputDialogRef.value.open()
  54. } else {
  55. uni.showToast({
  56. icon: 'error',
  57. title: '金额不能为空',
  58. duration: 2000
  59. })
  60. }
  61. }
  62. const dialogInputConfirm = (val) => {
  63. if (val) {
  64. uni.showToast({
  65. icon: 'success',
  66. title: '提现成功',
  67. duration: 2000
  68. })
  69. fullName.value = val
  70. inputClose.value.close()
  71. fullName.value = ''
  72. } else {
  73. uni.showToast({
  74. icon: 'error',
  75. title: '请输入姓名',
  76. duration: 2000
  77. })
  78. }
  79. }
  80. const close = () => {
  81. inputDialogRef.value.close()
  82. fullName.value = ''
  83. }
  84. </script>
  85. <style scoped lang="scss">
  86. .box {
  87. width: 750rpx;
  88. height: 180rpx;
  89. background-image: linear-gradient(to bottom, #FFBF60, #FFFFFF);
  90. padding: 60rpx 24rpx 0 24rpx;
  91. box-sizing: border-box;
  92. }
  93. .top {
  94. width: 702rpx;
  95. height: 227rpx;
  96. background-color: #FFFFFF;
  97. padding: 24rpx 34rpx 0 34rpx;
  98. box-sizing: border-box;
  99. }
  100. .money {
  101. width: 550rpx;
  102. height: 71rpx;
  103. /* background-color: #FFBF60; */
  104. color: red !important;
  105. font-size: 54rpx !important;
  106. margin: 3% 0 0 5%;
  107. font-weight: 700;
  108. .amount {
  109. margin-left: 5%;
  110. height: 71rpx;
  111. }
  112. .placeInput {
  113. font-weight: 100;
  114. }
  115. }
  116. .center {
  117. width: 100%;
  118. height: 100vh;
  119. background-color: #FFFFFF;
  120. font-size: 30rpx;
  121. color: #707070;
  122. padding: 0 50rpx;
  123. ;
  124. box-sizing: border-box;
  125. margin-top: 80rpx;
  126. }
  127. .text {
  128. color: #000000;
  129. font-weight: 700;
  130. margin-bottom: 30rpx;
  131. }
  132. .buttom {
  133. width: 544rpx;
  134. height: 89rpx;
  135. background-color: #FFBF60;
  136. color: #FFFFFF;
  137. font-size: 28rpx;
  138. border-radius: 41rpx;
  139. margin-top: 300rpx;
  140. }
  141. .level {
  142. display: flex;
  143. }
  144. </style>