recharge.vue 4.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180
  1. <template>
  2. <view>
  3. <view class="index">
  4. <image class="index-bg" src="@/static/img/wallet/bg.png" mode="scaleToFill"></image>
  5. <view class="head-money">
  6. <view class="sys-color-794B06 sys-size-28">我的JM币</view>
  7. <view class="head-mongy-1">
  8. <image src="@/static/img/wallet/j.png" mode=""></image>
  9. <view class="sys-size-52 sys-color-362100 sys-weight-600">138</view>
  10. </view>
  11. </view>
  12. </view>
  13. <view class="t-box sys-background-FFDFC3">
  14. <view class="sys-background-gray-f"></view>
  15. </view>
  16. <view class="box-sizing-border box-card">
  17. <view class="card-list">
  18. <view class="card-list-nav box-sizing-border"
  19. :class="fromData.moneyId===item.id?'s-view':'n-view'"
  20. @click="selectFun(1,item)"
  21. v-for="(item,i) in list" :key="i">
  22. <view class="list-top">
  23. <image src="@/static/img/wallet/b.png" mode=""></image>
  24. <view class="sys-size-40 sys-color-gray-3 sys-weight-600">{{item.b}}</view>
  25. </view>
  26. <view class="sys-size-24 sys-color-gray-6">¥{{item.money}}</view>
  27. </view>
  28. <view class="card-list-nav" v-if="list.length>3&&list.length%3!=0"></view>
  29. </view>
  30. <view class="m-26 sys-size-24 sys-color-gray-9" @click="selectFun(2)">充值即代表同意《积且充值协议》</view>
  31. <view class="card-button sys-background-41AAEE sys-size-32 sys-color-white" @click="selectFun(3)">
  32. <image src="@/static/img/wallet/zfb-logo.png" mode="scaleToFill"></image>支付宝支付
  33. </view>
  34. <view class="card-button sys-background-6DCF06 sys-size-32 sys-color-white" @click="selectFun(4)">
  35. <image src="@/static/img/wallet/wx-logo.png" mode="scaleToFill"></image>微信支付
  36. </view>
  37. <view class="sys-size-32 sys-color-gray-3 sys-weight-600">我的道具</view>
  38. <image class="crad-f" src="@/static/img/wallet/ad-2.png" mode="scaleToFill" @click="selectFun(5)"></image>
  39. </view>
  40. <SmallPaper v-if="isOpen" @close='close'></SmallPaper>
  41. </view>
  42. </template>
  43. <script>
  44. import SmallPaper from './small-paper.vue';
  45. export default {
  46. components:{SmallPaper},
  47. data(){
  48. return{
  49. isOpen:false,
  50. fromData:{
  51. moneyId:1,
  52. },
  53. list:[
  54. {money:6,b:60,id:1,},
  55. {money:16,b:160,id:2,},
  56. {money:26,b:260,id:3,},
  57. {money:36,b:360,id:4,},
  58. {money:46,b:460,id:5,},
  59. ],
  60. }
  61. },
  62. methods:{
  63. selectFun(type,item){
  64. if(type === 1){
  65. this.fromData.moneyId = item.id;
  66. }else if(type === 2){
  67. // 积且充值协议跳转
  68. }else if(type === 3){
  69. // 支付宝支付
  70. }else if(type === 4){
  71. // 微信支付
  72. }else if(type === 5){
  73. // 购买小纸条
  74. this.isOpen = true;
  75. }
  76. },
  77. close(e){
  78. this.isOpen = false;
  79. },
  80. },
  81. }
  82. </script>
  83. <style scoped lang="scss">
  84. .m-26{
  85. margin: 26rpx 0;
  86. }
  87. .index{
  88. width: 100%;
  89. height: 436rpx;
  90. position: relative;
  91. .index-bg{
  92. width: 100%;
  93. height: 436rpx;
  94. }
  95. .head-money{
  96. position: absolute;
  97. left: 54rpx;
  98. bottom: 76rpx;
  99. .head-mongy-1{
  100. display: flex;
  101. align-items: center;
  102. margin-top: 26rpx;
  103. image{
  104. width: 40rpx;
  105. height: 40rpx;
  106. border-radius: 50%;
  107. margin-right: 12rpx;
  108. }
  109. }
  110. }
  111. }
  112. .t-box{
  113. height: 30rpx;
  114. view{
  115. height: 30rpx;
  116. border-radius: 30rpx 30rpx 0rpx 0rpx;
  117. }
  118. }
  119. .box-card{
  120. min-height: 100rpx;
  121. padding: 70rpx 32rpx 10rpx 32rpx;
  122. .card-list{
  123. display: flex;
  124. flex-flow: row wrap;
  125. justify-content: space-between;
  126. .card-list-nav{
  127. width: 220rpx;
  128. height: 132rpx;
  129. border-radius: 12rpx;
  130. margin-bottom: 14rpx;
  131. text-align: center;
  132. .list-top{
  133. display: flex;
  134. align-items: center;
  135. justify-content: center;
  136. margin: 20rpx 0 4rpx 0;
  137. image{
  138. width: 24rpx;
  139. height: 24rpx;
  140. margin-right: 4rpx;
  141. }
  142. }
  143. }
  144. .s-view{
  145. border: 2rpx solid #FE6915;
  146. }
  147. .n-view{
  148. border: 2rpx solid #F2F2F2;
  149. }
  150. }
  151. .card-button{
  152. width: 686rpx;
  153. height: 88rpx;
  154. border-radius: 16rpx;
  155. line-height: 88rpx;
  156. display: flex;
  157. align-items: center;
  158. justify-content: center;
  159. margin-bottom: 24rpx;
  160. image{
  161. width: 32rpx;
  162. height: 32rpx;
  163. margin-right: 8rpx;
  164. }
  165. }
  166. .crad-f{
  167. width: 100%;
  168. height: 160rpx;
  169. border-radius: 20rpx;
  170. margin-top: 34rpx;
  171. box-shadow: 0rpx 0rpx 8rpx 0rpx rgba(0,0,0,0.1);
  172. }
  173. }
  174. </style>