Browse Source

h5添加在线状态

master
suyanyan 1 month ago
parent
commit
a17f5c281a
1 changed files with 19 additions and 8 deletions
  1. +19
    -8
      monitorMobile/pages/monitor/index.vue

+ 19
- 8
monitorMobile/pages/monitor/index.vue View File

@@ -16,7 +16,7 @@
<view class="botbox"> <view class="botbox">
<view id="url-player-test"></view> <view id="url-player-test"></view>
</view> </view>
</view> </view>
<view class="bottom-content"> <view class="bottom-content">


@@ -78,7 +78,8 @@
</view> </view>
</view> </view>
<view class="tableBox"> <view class="tableBox">
<u-empty marginTop="100rpx" :show="monitorList.length == 0&&status == 'nomore'" mode="list" text="暂无数据"></u-empty>
<u-empty marginTop="100rpx" :show="monitorList.length == 0&&status == 'nomore'" mode="list"
text="暂无数据"></u-empty>
<u-list @scrolltolower="scrolltolower" style="height: calc(100% - 0rpx);"> <u-list @scrolltolower="scrolltolower" style="height: calc(100% - 0rpx);">
<u-list-item v-for="(item, index) in monitorList" :key="index"> <u-list-item v-for="(item, index) in monitorList" :key="index">
<view class="liBox"> <view class="liBox">
@@ -107,6 +108,13 @@
设备IP:{{item.directUrlIp}} 设备IP:{{item.directUrlIp}}
</view> </view>
</view> </view>
<view class="thirdCard">
<view class="txt">
状态:
<text v-if="item.deviceStatus" style="color: #67c23a;">在线</text>
<text v-else style="color: #db2777;">离线</text>
</view>
</view>
</view> </view>
</view> </view>


@@ -201,10 +209,10 @@
this.loadmore() this.loadmore()
}, },
onUnload() { onUnload() {
if(this.showVideo) {
if (this.showVideo) {
this.closeDialog() this.closeDialog()
} }
}, },
onPullDownRefresh() { onPullDownRefresh() {
uni.stopPullDownRefresh() uni.stopPullDownRefresh()
@@ -336,7 +344,7 @@
}); });
}, },
// 获取视频地址 // 获取视频地址
startClick(id,name) {
startClick(id, name) {
this.sensorId = id; this.sensorId = id;
this.sensorName = name; this.sensorName = name;
this.showVideo = true; this.showVideo = true;
@@ -443,17 +451,20 @@
align-items: center; align-items: center;
padding: 0 25rpx; padding: 0 25rpx;
background: #fff; background: #fff;

.title { .title {
font-weight: 700; font-weight: 700;
font-size: 28rpx; font-size: 28rpx;
} }

.closes { .closes {
// background: #ccc; // background: #ccc;
} }
} }

.botbox { .botbox {
height:calc(100% - 80rpx);
height: calc(100% - 80rpx);
} }
} }


@@ -674,7 +685,7 @@
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
align-items: center; align-items: center;
margin-bottom: 60rpx;
// margin-bottom: 60rpx;


.schoolName { .schoolName {
font-size: 32rpx; font-size: 32rpx;


Loading…
Cancel
Save