userManagement.vue 2.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128
  1. <template>
  2. <view class="user-card">
  3. <navBar :name="'最近骑行'" />
  4. <view class="flex-row align-center user-card-heard">
  5. <img style="width: 48rpx;height: 48rpx;" src="https://qiniu.bms16.com/FieeNq75ybyjIzQO6fmNcdTlRsp5" alt="">
  6. <text style="margin-left: 16rpx;">共享用户</text>
  7. </view>
  8. <view class="user-card-text">家人、朋友长期共用车辆,授权账户可以使用感应解锁,寻车定位,查看设置等功能;</view>
  9. <!-- <view v-for="(item,index) in userList" :key="index"> -->
  10. <view @click="srcFn(`/pages/powerSetting/powerSetting?id=${item.target_user_id}`)" v-for="(item,index) of list" :key="index" class="user-list flex-row align-center">
  11. <image class="user-heard-img" :src="item.headimg" mode="aspectFill"></image>
  12. <view class="user-name-view">
  13. <view class="user-name">{{item.nickname}}</view>
  14. <view class="user-email">{{item.email}}</view>
  15. </view>
  16. <img class="user-nav-img" src="https://qiniu.bms16.com/FqnbZ2iKHmzCGJA8XD30sf5g_CAm" alt="">
  17. </view>
  18. <view @click="addUser" class="flex-row user-card-btn align-center">
  19. <img style="width: 20rpx;height: 20rpx;" src="https://qiniu.bms16.com/FvP_5VTgawzExIHW3kJahXAvE04z" alt="">
  20. <text style="margin-left: 6rpx;">添加成员</text>
  21. </view>
  22. </view>
  23. </template>
  24. <script>
  25. var config = require('../../common/config_gyq.js');
  26. var http = require('../../common/request.js');
  27. export default {
  28. data() {
  29. return {
  30. list:[],
  31. car_info:{}
  32. };
  33. }
  34. /**
  35. * 生命周期函数--监听页面加载
  36. */
  37. ,
  38. onLoad: function(options) {
  39. // this.listFn()
  40. },
  41. onShow() {
  42. this.listFn()
  43. },
  44. methods: {
  45. srcFn(url){
  46. uni.navigateTo({
  47. url
  48. })
  49. },
  50. addUser(){
  51. uni.navigateTo({
  52. url:`/pages/addUser/addUser`
  53. })
  54. },
  55. async listFn(){
  56. this.car_info = uni.getStorageSync('car_info') || {};
  57. let {data} = await http.postApi(config.API_FLK_CAR_SHARE_LIST,{
  58. car_sn:this.car_info.car_sn
  59. })
  60. if(data.code == 200){
  61. this.list = data.data.list
  62. }
  63. console.log(data)
  64. }
  65. }
  66. };
  67. </script>
  68. <style>
  69. .user-card{
  70. background: #FFFFFF;
  71. border-radius: 40rpx;
  72. border: 4rpx solid #FFFFFF;
  73. margin: 24rpx;
  74. padding: 32rpx 32rpx 48rpx ;
  75. }
  76. .align-center{
  77. align-items: center;
  78. }
  79. .user-card-heard{
  80. font-weight: 600;
  81. font-size: 40rpx;
  82. color: #060809;
  83. margin-bottom: 16rpx;
  84. }
  85. .user-card-text{
  86. font-weight: 400;
  87. font-size: 28rpx;
  88. color: #060809;
  89. margin-bottom: 40rpx;
  90. opacity: 0.4;
  91. }
  92. .user-card-btn{
  93. justify-content: center;
  94. font-weight: 600;
  95. font-size: 32rpx;
  96. color: #060809;
  97. }
  98. .user-heard-img{
  99. width: 112rpx;
  100. height: 112rpx;
  101. border-radius: 50%;
  102. }
  103. .user-name-view{
  104. margin-bottom: 48rpx;
  105. display: flex;
  106. flex-direction: column;
  107. flex-grow: 1;
  108. margin-left: 24rpx;
  109. padding: 0 18rpx;
  110. }
  111. .user-name{
  112. font-weight: 600;
  113. font-size: 32rpx;
  114. color: #060809;
  115. padding-bottom:20rpx ;
  116. }
  117. .user-email{
  118. font-weight: 500;
  119. font-size: 24rpx;
  120. color: #060809;
  121. opacity: 0.6;
  122. }
  123. .user-nav-img{
  124. width: 28rpx;
  125. height: 28rpx;
  126. }
  127. </style>