useradmin.vue 2.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128
  1. <template>
  2. <view class="content">
  3. <scroll-view scroll-y="true" class="list-wrap" :style="{'height': maxheight}">
  4. <view class="user-item ">
  5. <view class="user-info">
  6. <image src="" mode=""></image>
  7. <view class="">
  8. 往事随风往事随风
  9. </view>
  10. </view>
  11. <view class="user-base">
  12. <view class="">
  13. 电话:13756234569
  14. </view>
  15. <view class="">
  16. 地址:椒江区东海大道400号
  17. </view>
  18. <view class="">
  19. 进店时间:2023-12-20 14:20:12
  20. </view>
  21. </view>
  22. <view class="jg"></view>
  23. <view class="btn-list flex">
  24. <view class="btn">
  25. 水票:<text>30</text>
  26. </view>
  27. <view class="btn">
  28. 押桶:<text>5</text>
  29. </view>
  30. </view>
  31. </view>
  32. </scroll-view>
  33. </view>
  34. </template>
  35. <script>
  36. import {
  37. getUserList
  38. } from "@/api/user.js"
  39. export default {
  40. data() {
  41. return {
  42. maxheight: '',
  43. };
  44. },
  45. onLoad(opt) {
  46. this.getUserList()
  47. },
  48. onShow() {
  49. },
  50. onReady(res) {
  51. var that = this;
  52. uni.getSystemInfo({
  53. success: resu => {
  54. const query = uni.createSelectorQuery();
  55. query.select('.list-wrap').boundingClientRect();
  56. query.exec(function(res) {
  57. that.maxheight = resu.windowHeight - res[0].top + 'px';
  58. });
  59. },
  60. fail: res => {}
  61. });
  62. },
  63. onReachBottom() {
  64. },
  65. methods: {
  66. getUserList() {
  67. getUserList().then(res => {
  68. console.log(res);
  69. })
  70. }
  71. }
  72. };
  73. </script>
  74. <style lang="scss" scoped>
  75. .user-item {
  76. width: 750rpx;
  77. align-items: flex-start;
  78. padding: 25rpx 45rpx;
  79. background-color: #fff;
  80. margin-bottom: 15rpx;
  81. .user-info {
  82. height: 72rpx;
  83. font-size: 36rpx;
  84. font-weight: bold;
  85. color: #333333;
  86. display: flex;
  87. justify-content: flex-start;
  88. align-items: center;
  89. image {
  90. height: 72rpx;
  91. width: 72rpx;
  92. margin-right: 20rpx;
  93. background-color: #eee;
  94. border-radius: 50%;
  95. }
  96. }
  97. .jg {
  98. width: 681rpx;
  99. height: 2rpx;
  100. background: #E6E6E6;
  101. margin: 25rpx auto;
  102. }
  103. .user-base {
  104. view {
  105. margin: 15rpx 0;
  106. }
  107. }
  108. .btn-list {
  109. justify-content: flex-start;
  110. .btn {
  111. padding: 15rpx 30rpx;
  112. margin-right: 32rpx;
  113. border: 2px solid #333333;
  114. border-radius: 10rpx;
  115. font-size: 31rpx;
  116. font-weight: 500;
  117. color: #333333;
  118. text {
  119. color: #FF4C4C;
  120. }
  121. }
  122. }
  123. }
  124. </style>