index.vue 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990
  1. <template>
  2. <mobile-frame>
  3. <view class="main">
  4. <view class="one">
  5. <view class="one_1">
  6. <text>¥</text><text>{{money}}</text>
  7. </view>
  8. <view class="one_2">
  9. 当前可用
  10. </view>
  11. </view>
  12. <view class="two">
  13. <view class="two_1" v-if="list&&list.length>0">
  14. 数据列表
  15. </view>
  16. <view class="two_2" v-else>
  17. 已加载完全部
  18. </view>
  19. </view>
  20. </view>
  21. </mobile-frame>
  22. </template>
  23. <script>
  24. export default {
  25. data() {
  26. return {
  27. money: 0,
  28. list: []
  29. };
  30. },
  31. onLoad: function(e) {
  32. },
  33. methods: {
  34. },
  35. onPullDownRefresh: async function() {
  36. const that = this;
  37. that.$set(that, `list`, [])
  38. that.$set(that, `skip`, 0)
  39. that.$set(that, `limit`, 6)
  40. that.$set(that, `page`, 0)
  41. await that.search();
  42. uni.stopPullDownRefresh();
  43. }
  44. }
  45. </script>
  46. <style lang="scss">
  47. .main {
  48. display: flex;
  49. flex-direction: column;
  50. width: 100vw;
  51. height: 100vh;
  52. .one {
  53. background-color: var(--fFB1Color);
  54. text-align: center;
  55. padding: 5vw 0;
  56. .one_1 {
  57. font-size: 25px;
  58. font-weight: bold;
  59. color: #fff;
  60. margin: 0 0 2vw 0;
  61. text:nth-child(1) {
  62. font-size: 15px;
  63. padding: 0 1vw 0 0;
  64. }
  65. }
  66. .one_2 {
  67. font-size: 16px;
  68. color: #fff;
  69. }
  70. }
  71. .two {
  72. .two_2 {
  73. text-align: center;
  74. color: #858585;
  75. font-size: 14px;
  76. margin: 5vw 0;
  77. }
  78. }
  79. }
  80. </style>