sitePage.vue 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109
  1. <template>
  2. <view>
  3. <car-common ref="common"></car-common>
  4. <u-navbar title="站点主页" >
  5. <view class="slot-wrap"></view>
  6. <view class="navbar-right" @click="mapopenBtn" >
  7. <u-icon name="plus-circle" v-if="!mapopen" color="#999" size="28"></u-icon>
  8. <span v-if="!mapopen">放大地图</span>
  9. <u-icon name="minus-circle" v-if="mapopen" color="#999" size="28"></u-icon>
  10. <span v-if="mapopen">缩小地图</span>
  11. </view>
  12. </u-navbar>
  13. <carmap ref="amap" @onload="mapdown"></carmap>
  14. <view class="sitePage-currentSite">
  15. <u-icon name="zhanpai" custom-prefix="custom-icon" size="40" color="#1677ff"></u-icon>
  16. <span>{{nearbyStationInfo.stationName}}</span>
  17. <p>距离{{nearbyStationInfo.distance}}米</p>
  18. </view>
  19. <view class="sitePage-route">
  20. <view class="route-item" v-for="li,i in nearbyStationInfo.nearbyShiftDTOList " :key="i" @click="gotoLine(li,nearbyStationInfo.stationId)">
  21. <view class="route-text">
  22. <h4>{{li.routeName}}</h4>
  23. <p>开往:{{li.endStationName}} {{li.currentStationName&&li.des!='等待发车'?'当前:'+li.currentStationName:''}}</p>
  24. </view>
  25. <view class="route-gap" >
  26. <view class="route-gap stop">
  27. <span>{{li.des?li.des:"等待发车"}}</span>
  28. <u-icon name="arrow-right" color="#999" size="28"></u-icon>
  29. </view>
  30. </view>
  31. </view>
  32. </view>
  33. </view>
  34. </template>
  35. <script>
  36. import api from './sitePage.js'
  37. export default api
  38. </script>
  39. <style>
  40. page{
  41. background-color: #f7f7f7;
  42. }
  43. </style>
  44. <style scoped lang="scss">
  45. .sitePage-currentSite{
  46. background-color: #fff;
  47. height: 50px;
  48. display: flex;
  49. padding: 0 15px;
  50. align-items: center;
  51. span{
  52. font-size: 18px;
  53. margin-left: 10px;
  54. font-weight: bold;
  55. }
  56. p{
  57. color:#999;
  58. margin-left: 10px;
  59. }
  60. }
  61. .sitePage-route{
  62. margin: 10px;
  63. .route-item{
  64. padding: 20rpx;
  65. background-color: #fff;
  66. border-bottom: 1px solid #f7f7f7;
  67. display: flex;
  68. justify-content: space-between;
  69. align-items: center;
  70. &:last-child{
  71. border: none;
  72. }
  73. h4{
  74. font-size: 32rpx;
  75. }
  76. p{
  77. margin-top: 6rpx;
  78. color:#999;
  79. }
  80. }
  81. .route-gap{
  82. span{
  83. font-size: 32rpx;
  84. font-weight: bold;
  85. margin-right: 10rpx;
  86. color:#1677ff;
  87. }
  88. &.stop{
  89. span{color:#ff731d}
  90. }
  91. }
  92. }
  93. .navbar-right {
  94. display: flex;
  95. margin-right: 20rpx;
  96. span{
  97. color:rgb(96, 98, 102);
  98. margin-left: 3px;
  99. }
  100. }
  101. .slot-wrap {
  102. display: flex;
  103. align-items: center;
  104. flex: 1;
  105. }
  106. </style>