index.wxml
3.58 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
<wxs module="jstools" src="includes.wxs"></wxs>
<view class="map-box">
<map id="myMap" latitude="{{latitude}}" longitude="{{longitude}}" bindmarkertap="markertap" bindcallouttap="callouttap" bindlabeltap="labeltap" markers="{{markers}}" scale="{{scale}}">
<cover-view style="bottom:{{drawerHeight == 456?20:400}}rpx" class="cover-view" bindtap="controltap">
<cover-image class="station" src="https://img01.glsx.com.cn/weapp/resource/miniprogram/wuye/home/parking/position.png"></cover-image>
</cover-view>
</map>
<view class="draw-box" style="height: {{drawerHeight}}rpx;">
<block wx:if="{{isEmpty}}">
<view class="draw-header" catch:touchstart="touchStart" catch:touchmove="touchMove" catch:touchend="touchEnd">
<view class="parking-arrow-icon" catch:tap="pullH">
</view>
<view class="parking-logo">
<glsx-image webp src="home/parking/stop.png" class="parking-logo"></glsx-image>
</view>
<view class="parking-desc">当前剩余空闲车位: <text>{{parking.idleStatusCount}}</text></view>
</view>
<view class="draw-tab">
<view class="tab-item {{tabIndex === item.value?'checked':''}}" data-index="{{item.value}}" catch:tap="selectTab" wx:for="{{STATUS}}">{{item.label}}({{parking[item.name]}})</view>
<view class="tab-btn" bindtap="handleRefresh">刷新<view class="parking-refresh {{isRotate?'rotate':''}}">
<glsx-image webp src="home/parking/refresh.png"></glsx-image>
</view>
</view>
</view>
<view class="draw-body">
<block wx:if="{{carList.length}}">
<view class="car-item" wx:for="{{carList}}" wx:key="index">
<view class="parking-logo">
<glsx-image webp src="home/parking/{{item.parkingStatus == 1?'idle':item.parkingStatus == 2?'occupy':'unknown'}}_icon.png" class="parking-logo"></glsx-image>
</view>
<view class="parking-desc">
<view class="parking-num {{item.parkingStatus == 0?'disabeld':''}}">
{{item.parkingArea}}-{{item.parkingBuilding}}-{{item.parkingFloor}}
</view>
<view class="parking-status {{item.parkingStatus == 1?'idle':item.parkingStatus == 2?'occupy':'unknown'}}">
{{item.parkingStatusStr}}
</view>
</view>
<view class="parking-btn" bind:tap="jump" data-id="{{item.id}}">详情</view>
</view>
</block>
<block wx:else>
<view class="empty-box" style="height: 100%;">
<view class="empty-body" style="width: 220rpx;height: 220rpx;">
<glsx-image webp src="home/parking/empty.png"></glsx-image>
</view>
<view class="empty-text">暂无车位</view>
</view>
</block>
</view>
</block>
<block wx:else>
<view class="empty-box">
<view class="empty-header"></view>
<view class="empty-body">
<glsx-image webp src="home/parking/empty.png"></glsx-image>
</view>
<view class="empty-text">暂无车位</view>
</view>
</block>
</view>
</view>