3
0

recharge.vue 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181
  1. <template>
  2. <view class="content">
  3. <custom-layout ref="layout" :showBottom="true" title="充值" v-model="dataList"
  4. @layoutquery="onQueryList">
  5. <template #content>
  6. <view class=" card_record">
  7. <view class="card_record_name">余额</view>
  8. <view class="card_record_num">
  9. <uni-icons custom-prefix="iconfont" type="icon-jifen" size="20"></uni-icons>
  10. <text>9</text>
  11. </view>
  12. <view class="card_record_bottom flx-justify-between">
  13. <view class="flx-center">
  14. <view class="">充值记录</view>
  15. <view class="ml10 mr10">|</view>
  16. <view class="">消费明细</view>
  17. </view>
  18. <view class="">
  19. 白赚积分
  20. </view>
  21. </view>
  22. </view>
  23. <view class="record_list">
  24. <view class="record_list_title">充值</view>
  25. <view class="demo-uni-row">
  26. <view class="demo-uni-col" v-for="(item,index) in 10" :key="index">
  27. <view class="record_item_num">99</view>
  28. <view class="record_item_pay">¥29元</view>
  29. </view>
  30. </view>
  31. </view>
  32. <view class="checkbox_box mt20 pl20 pr20">
  33. <checkbox-group>
  34. <label>
  35. <checkbox value="agreement" checked="true" />
  36. <text class="checkbox_box_text">已阅读并同意</text>
  37. </label>
  38. </checkbox-group>
  39. <text class="checkbox_box_supplementary">《充值协议》</text>和<text
  40. class="checkbox_box_supplementary">《充值安全提示》</text>
  41. </view>
  42. <view class="pl20 pr20 mt20">
  43. <button class="but_bottom" type="primary">立即充值</button>
  44. </view>
  45. </template>
  46. </custom-layout>
  47. </view>
  48. </template>
  49. <script setup>
  50. import {
  51. ref,
  52. onMounted
  53. } from 'vue';
  54. import {
  55. onShow
  56. } from "@dcloudio/uni-app";
  57. // 引入组件
  58. // 定义查询字典
  59. // 定义变量内容
  60. const agreement = ref(false)
  61. const checkboxList = ref([{
  62. text: '已阅读并同意',
  63. value: 0
  64. }])
  65. // 生命中期
  66. onMounted(() => {
  67. console.log('onMounted生命周期')
  68. })
  69. </script>
  70. <style lang="scss" scoped>
  71. @import '@/static/css/common.scss';
  72. .card_record {
  73. margin: 30rpx;
  74. padding: 30rpx;
  75. border-radius: 20rpx;
  76. background: linear-gradient(118.57deg, rgba(176, 242, 255, 1) 0%, rgba(144, 252, 205, 1) 100%);
  77. box-shadow: 0rpx 8rpx 12rpx rgba(24, 105, 255, 0.3);
  78. .card_record_name {
  79. font-size: 30rpx;
  80. font-weight: 600;
  81. letter-spacing: 0rpx;
  82. color: rgba(56, 56, 56, 1);
  83. }
  84. .card_record_num {
  85. display: flex;
  86. align-items: flex-end;
  87. .uni-icons {
  88. margin-bottom: 10rpx;
  89. position: relative;
  90. left: -10rpx;
  91. }
  92. text {
  93. font-size: 70rpx;
  94. font-weight: 700;
  95. letter-spacing: 0rpx;
  96. color: rgba(56, 56, 56, 1);
  97. margin-left: 10rpx;
  98. }
  99. }
  100. .card_record_bottom {
  101. margin-top: 60rpx;
  102. font-size: 28rpx;
  103. font-weight: 600;
  104. letter-spacing: 0rpx;
  105. line-height: 32.82rpx;
  106. color: rgba(56, 56, 56, 1);
  107. }
  108. }
  109. // ======liet样式=======
  110. .record_list {
  111. padding: 0 30rpx;
  112. box-sizing: border-box;
  113. .record_list_title {
  114. font-size: 32rpx;
  115. font-weight: 700;
  116. letter-spacing: 0rpx;
  117. line-height: 37.5rpx;
  118. color: rgba(0, 0, 0, 1);
  119. }
  120. .demo-uni-row {
  121. width: 100%;
  122. margin-top: 20rpx;
  123. box-sizing: border-box;
  124. display: flex;
  125. flex-wrap: wrap;
  126. .demo-uni-col {
  127. width: calc((100% - 40rpx) / 3);
  128. height: 120rpx;
  129. background-color: #fff;
  130. border-radius: 13px;
  131. margin-bottom: 20rpx;
  132. display: flex;
  133. flex-direction: column;
  134. justify-content: center;
  135. align-items: center;
  136. &:nth-child(3n - 1) {
  137. margin-right: 20rpx;
  138. margin-left: 20rpx;
  139. }
  140. .record_item_num {
  141. font-size: 36rpx;
  142. font-weight: 500;
  143. letter-spacing: 0rpx;
  144. line-height: 42.2rpx;
  145. color: $primary-color;
  146. }
  147. .record_item_pay {
  148. font-size: 20rpx;
  149. font-weight: 500;
  150. letter-spacing: 0rpx;
  151. line-height: 23.44rpx;
  152. color: $text-color-sub;
  153. margin-top: 10rpx;
  154. }
  155. }
  156. }
  157. }
  158. .but_bottom {
  159. border-radius: 50rpx;
  160. background-color: $primary-color;
  161. color: $text-one;
  162. }
  163. </style>