index.vue 5.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151
  1. <template>
  2. <view class="container-view">
  3. <view class="flex-row flex-between align-center padding_about_40">
  4. <view class="car-name-view">
  5. <text style="margin-right: 10rpx;">小米</text>
  6. <img src="https://qiniu.bms16.com/FoSXDpVGvbdmwbX3CMUBvR7X4IzI" style="width: 14rpx;height: 14rpx;" alt="">
  7. </view>
  8. <img src="https://qiniu.bms16.com/FtlfBtBE5-TeTI5EdrciX_u8u_Sx" style="width: 48rpx;height: 48rpx;" alt="">
  9. </view>
  10. <view class="car-img-view">
  11. <view class="quantity-view flex-row">
  12. <text class="quantity flex-row">88 <text style="font-size: 28rpx;font-weight: 500;">%</text></text>
  13. <u-line-progress style="width: 100rpx;" active-color="#2ADA62" height="10" :show-percent="false" :percent="70"></u-line-progress>
  14. <text class="quantity-text flex-row">
  15. <text style="font-weight:400;font-size: 22rpx;">{{$t("续航")}}</text>
  16. <text style="font-size: 36rpx;">54</text><text style="font-size: 30rpx;">km</text>
  17. </text>
  18. </view>
  19. <img src="https://qiniu.bms16.com/Fg8_p7083jpsy8BXG4bR6yMs7jQX" style="width: 100%;height: 526rpx;" alt="">
  20. <view class="flex-row align-center update-time-view" >
  21. <text style="margin-right: 10rpx;">{{$t("车辆已关机")}} </text>
  22. <text style="margin-right: 10rpx;">{{$t("更新于")}} 11-25 23:05 </text>
  23. <img src="https://qiniu.bms16.com/FsL6XWGoIhfsVB7jRg6EGFVsuaTZ" style="width: 24rpx;height: 32rpx;" alt="">
  24. </view>
  25. </view>
  26. <Control/>
  27. <view class="flex-row flex-between map-card-view" >
  28. <MapCard latitude="23.099994" longitude="113.324004" :carAddress="carAddress" :carLocation="carLocation"/>
  29. <view class="card-right">
  30. <view class="card-bg" @tap="navTravelingTrack">
  31. <view class="flex-row flex-between card-top-title">
  32. <view class="flex-row align-center">
  33. <img style="width: 36rpx;height: 36rpx;" src="https://qiniu.bms16.com/FkrcMCV__HraZ0W0NBNdEZPIlwss" alt="">
  34. <text class="margin_l_8">{{isTrackOrAll?'最近骑行':'总里程'}}</text>
  35. </view>
  36. <view @tap.stop="isTrackOrAll=!isTrackOrAll"><img style="width: 24rpx;height: 20rpx;" src="https://qiniu.bms16.com/FltPK-o7KGS3dQ2pfQHXGSxOdzaN" alt=""></view>
  37. </view>
  38. <view class="card-top-text">27.4<text class="font_24">km</text></view>
  39. </view>
  40. <view class="card-bg">
  41. <view class="flex-row card-top-title">
  42. <img style="width: 36rpx;height: 36rpx;" src="https://qiniu.bms16.com/FtalApKa3STyruaBxxRB4O9hHXyE" alt="">
  43. <text class="margin_l_8">{{$t("换电套餐")}}</text>
  44. </view>
  45. <view class=" card-top-text">30 <text class="font_24">{{$t("天")}}</text></view>
  46. </view>
  47. </view>
  48. </view>
  49. <view class="config-view">
  50. <view class="flex-row config-car-view">
  51. <view class="margin_r_20"><img class="icon_style_64" src="https://qiniu.bms16.com/Ftzyvs5whxDdMFksYChHaWKVb0Uk" alt=""></view>
  52. <view class="flex-row config-text-view">
  53. <view class="flex-row font_w_600">{{$t("感应解锁")}}</view>
  54. <view class="flex-row tip-text-config">{{$t("请先链接蓝牙")}}</view>
  55. </view>
  56. <img class="icon_style_28" src="https://qiniu.bms16.com/FqnbZ2iKHmzCGJA8XD30sf5g_CAm" alt="">
  57. </view>
  58. <view class="flex-row config-car-view">
  59. <view class="margin_r_20"><img class="icon_style_64" src="https://qiniu.bms16.com/FhKkijkN__9UzhYNgamBFSggIlYo" alt=""></view>
  60. <view class="flex-row config-text-view">
  61. <view class="flex-row font_w_600">{{$t("用车人管理")}}</view>
  62. <view class="flex-row tip-text-config">{{$t("个家庭账号")}}</view>
  63. </view>
  64. <img class="icon_style_28" src="https://qiniu.bms16.com/FqnbZ2iKHmzCGJA8XD30sf5g_CAm" alt="">
  65. </view>
  66. <view class="flex-row config-car-view">
  67. <view class="margin_r_20"><img class="icon_style_64" src="https://qiniu.bms16.com/FsAg6mHEBJfbtpgIHBrDdNiPo1iH" alt=""></view>
  68. <view class="flex-row config-text-view">
  69. <view class="flex-row font_w_600">{{$t("设备信息")}}</view>
  70. <view class="flex-row tip-text-config">{{$t("软件版本")}}</view>
  71. </view>
  72. <img class="icon_style_28" src="https://qiniu.bms16.com/FqnbZ2iKHmzCGJA8XD30sf5g_CAm" alt="">
  73. </view>
  74. </view>
  75. <view style="height: 264rpx;"></view>
  76. <CustomTabbar />
  77. </view>
  78. </template>
  79. <script>
  80. var app = getApp();
  81. var config = require('../../common/config.js');
  82. var common = require('../../common/common.js');
  83. var http = require('../../common/http.js');
  84. var storage = require('../../common/storage.js');
  85. import Control from './components/control/control'
  86. import MapCard from './components/mapCard/mapCard'
  87. import CustomTabbar from '@/component/customTabbar/index';
  88. export default {
  89. data() {
  90. return {
  91. carLocation: [{
  92. id: 1345,
  93. latitude: 23.099994,
  94. longitude: 113.324004,
  95. iconPath: 'https://qiniu.bms16.com/FjzP68_NSPJbde_JraN5dJRnyqqJ',
  96. width: 60,
  97. height: 60,
  98. customCallout: {
  99. display: 'ALWAYS', // 'BYCLICK':点击显示; 'ALWAYS':常显
  100. },
  101. }], // 标记点
  102. carAddress:'普宁升记炒饭肠粉百...',
  103. isTrackOrAll:true
  104. };
  105. },
  106. computed: {},
  107. components: {
  108. Control,
  109. MapCard,
  110. CustomTabbar
  111. },
  112. /**
  113. * 生命周期函数--监听页面加载
  114. */
  115. onLoad: function(options) {
  116. },
  117. /**
  118. * 生命周期函数--监听页面显示
  119. */
  120. onShow: function() {
  121. },
  122. // 分享给好友
  123. onShareAppMessage: function(res) { //发送给朋友
  124. return {
  125. title: this.appConfig.app_name,
  126. path: 'pages/index/index',
  127. }
  128. },
  129. methods: {
  130. navTravelingTrack(){
  131. uni.navigateTo({
  132. url: '/pages/travelingTrack/travelingTrack?longitude=' + this.longitude +'&latitude=' + this.latitude,
  133. success: function(res) {},
  134. fail: function(res) {},
  135. complete: function(res) {}
  136. });
  137. }
  138. }
  139. };
  140. </script>
  141. <style>
  142. @import './index.css';
  143. </style>