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

258 lines
4.6 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
  1. <template>
  2. <!-- <div>保证金退还</div> -->
  3. <view class="container">
  4. <view class="top" :style="{ borderRadius: '8rpx' }">
  5. <view class="level account">
  6. <view >
  7. 账户总览
  8. </view>
  9. </view>
  10. <view class="level Recharge">
  11. <view class="money level">
  12. <text>¥</text>
  13. <input v-model="money" type="text" />
  14. </view>
  15. </view>
  16. </view>
  17. <view class="center">
  18. <up-parse class="size-28" :content="configList.pet_mmoney_text.paramValueArea"></up-parse>
  19. </view>
  20. <view class="level text1">
  21. 有关履约保证金的其他规则详见
  22. <view class="text4" @click="openPopup('pet_lv_yue')">
  23. 履约保证金&认证费协议
  24. </view>
  25. </view>
  26. <view class="buttom level" :style="{ borderRadius: '41rpx' }" @click="onRefund">
  27. <text>退还并注销伴宠师</text>
  28. </view>
  29. <up-popup :show="popupData.show" @close="closePopup" :round="10">
  30. <view style="max-height: 80vh; overflow-y: auto; padding: 20rpx;">
  31. <up-parse class="size-28" :content="popupData.content"></up-parse>
  32. </view>
  33. </up-popup>
  34. <up-popup
  35. :show="codePopupVisible"
  36. mode="center"
  37. bgColor="transparent"
  38. @close="onCodePopupClose"
  39. >
  40. <view class="popup">
  41. <image class="popup-bg" :src="configList.pet_mmoney_back.paramValueImage"></image>
  42. <view class="flex-colc popup-content">
  43. <text>您已申请退还请联系服务顾问</text>
  44. <image class="qr" :src="configList.pet_code.paramValueImage" mode="widthFix"></image>
  45. </view>
  46. <view class="btn-close" @click="codePopupVisible = false">
  47. <up-icon name="close-circle-fill" color="#ffffff" size="60rpx"></up-icon>
  48. </view>
  49. </view>
  50. </up-popup>
  51. </view>
  52. </template>
  53. <script setup>
  54. import { ref, reactive, computed } from 'vue'
  55. import { useStore } from 'vuex'
  56. const store = useStore()
  57. const configList = computed(() => {
  58. return store.getters.configList
  59. })
  60. const money = ref()
  61. const codePopupVisible = ref(false)
  62. const onCodePopupClose = () => {
  63. uni.reLaunch({
  64. url: '/pages/workbenchManage/index'
  65. })
  66. }
  67. const onRefund = () => {
  68. // todo: subimt refund and fetch qrcode and open popup
  69. codePopupVisible.value = true
  70. }
  71. const popupData = reactive({
  72. show: false,
  73. content: null,
  74. })
  75. const openPopup = (key) => {
  76. popupData.content = configList.value[key]?.paramValueArea || "";
  77. popupData.show = true;
  78. }
  79. const closePopup = () => {
  80. popupData.show = false
  81. }
  82. </script>
  83. <style scoped lang="scss">
  84. .container {
  85. width: 100%;
  86. height: 150rpx;
  87. padding: 7% 3% 0 4%;
  88. box-sizing: border-box;
  89. background-image: linear-gradient(to bottom, #FFBF60, #F2F2F2);
  90. }
  91. .top {
  92. width: 702rpx;
  93. height: 227rpx;
  94. background-color: #FFFFFF;
  95. padding: 3% 6% 0 6%;
  96. box-sizing: border-box;
  97. font-size: 30rpx;
  98. }
  99. .level {
  100. display: flex;
  101. }
  102. .account {
  103. justify-content: space-between;
  104. color: #000000;
  105. font-size: 30rpx;
  106. }
  107. .Recharge {
  108. width: auto;
  109. height: 71rpx;
  110. justify-content: space-between;
  111. margin: 30rpx 0 0 30rpx;
  112. color: #FFFFFF;
  113. font-size: 22rpx;
  114. align-items: center;
  115. }
  116. .text2 {
  117. color: #BDBDBD;
  118. font-size: 22rpx;
  119. }
  120. .line {
  121. position: relative;
  122. padding: 0 0 0 20rpx;
  123. &::before {
  124. position: absolute;
  125. top: 7rpx;
  126. left: 10rpx;
  127. content: "";
  128. width: 3rpx;
  129. height: 26rpx;
  130. border-radius: 9rpx;
  131. background-color: #BDBDBD;
  132. }
  133. }
  134. .money {
  135. width: 450rpx;
  136. height: 71rpx;
  137. /* background-color: #FFBF60; */
  138. color: #FFBF60 !important;
  139. font-size: 54rpx !important;
  140. }
  141. .money input {
  142. margin-left: 5%;
  143. font-size: 61rpx;
  144. height: 71rpx;
  145. }
  146. .text3 {
  147. width: 131rpx;
  148. height: 47rpx;
  149. background-color: #FFBF60;
  150. line-height: 47rpx;
  151. display: flex;
  152. justify-content: center;
  153. }
  154. .center {
  155. width: 100%;
  156. height: 800rpx;
  157. padding: 3% 4%;
  158. box-sizing: border-box;
  159. color: #707070;
  160. font-size: 28rpx;
  161. line-height: 45rpx;
  162. }
  163. .text {
  164. color: black;
  165. font-size: 30rpx;
  166. font-weight: 700;
  167. margin: 3% 0;
  168. }
  169. .text1 {
  170. color: #BDBDBD;
  171. font-size: 22rpx;
  172. padding: 0 4%;
  173. box-sizing: border-box;
  174. }
  175. .text4 {
  176. color: #FFBF60;
  177. }
  178. .buttom {
  179. width: 594rpx;
  180. height: 94rpx;
  181. background-color: #FFBF60;
  182. margin: 25% 3% 0 7%;
  183. justify-content: center;
  184. align-items: center;
  185. color: #FFFFFF;
  186. font-size: 30rpx;
  187. }
  188. .popup {
  189. width: 632rpx;
  190. height: 835rpx;
  191. position: relative;
  192. &-bg,
  193. &-content {
  194. width: 100%;
  195. height: 100%;
  196. }
  197. &-content {
  198. position: absolute;
  199. top: 0;
  200. left: 0;
  201. padding-top: 276rpx;
  202. box-sizing: border-box;
  203. color: #707070;
  204. font-size: 28rpx;
  205. line-height: 37rpx;
  206. .qr {
  207. margin-top: 89rpx;
  208. width: 307rpx;
  209. height: auto;
  210. }
  211. }
  212. .btn-close {
  213. position: absolute;
  214. top: -27rpx;
  215. right: -13rpx;
  216. }
  217. }
  218. </style>