湖里大屏(数字工地):人脸闸机数据渲染

This commit is contained in:
骆乐 2022-08-11 13:36:33 +08:00
parent 632655024c
commit 37a5d8f6b8
4 changed files with 52 additions and 17 deletions

View File

@ -24,7 +24,7 @@
<rightCenter title="环境监测"></rightCenter>
</div>
<div class="rightBottom">
<rightBottom title="人脸闸机"></rightBottom>
<rightBottom title="人脸闸机" :ufaceList="ufaceList"></rightBottom>
</div>
</div>
</div>
@ -64,7 +64,8 @@ export default {
towerList: [], //
lifterList: [], //
videoCountList: {}, //
ufaceList: [], //
ufaceList: {}, //
uface:[],
ufaceInCount: 0, //
environmentDevList: [], //
dangerAlarmTypeList: [], //
@ -90,7 +91,7 @@ export default {
//
getAllTowerDangerInfo(data).then(res => {
if (res.code === 200) {
console.log('获取塔吊数量',res)
// console.log('',res)
let { result } = res
this.totalTowerDev = result.devCount.devNum
this.totalDangerTowerDev = result.towerAlarmCount
@ -154,7 +155,7 @@ export default {
selectTowerDevAlarmCountList(data).then(res => {
if (res.code === 200) {
this.towerList = res.result.devList
console.log('获取塔吊设备信息',this.towerList)
// console.log('',this.towerList)
}
})
//
@ -173,8 +174,10 @@ export default {
//
selectUfaceDevStatisticsList(data).then(res => {
if (res.code === 200) {
this.ufaceList = res.result.devList
this.ufaceList.forEach(item => {
console.log('获取人脸闸机设备信息',res)
this.ufaceList = res.result
this.uface = res.result.devList
this.uface.forEach(item => {
this.ufaceInCount += item.inTotalNum
})
}

View File

@ -6,11 +6,13 @@
>
<div class="list">
<div class="list-head">设备名称</div>
<div class="listBox">
<div class="list-item" :class="item.deviceState ==1 ? 'offline' : 'online'" v-for="(item,index) in videoCountList.videoList" :key="index">
<div class="label">{{item.videoName}}</div>
<div class="status">{{item.deviceState ==1 ? '在线' :'离线'}}</div>
</div>
</div>
</div>
</DeviceCard>
</Card>
</template>
@ -34,12 +36,17 @@ export default {
return {}
},
mounted(){
console.log('--------------',this.videoCountList)
// console.log('--------------',this.videoCountList)
}
}
</script>
<style lang="less" scoped>
::-webkit-scrollbar {
width: 3px;
color: #636364;
}
.list {
padding: 0 10px;
color: #fff;
@ -48,6 +55,9 @@ export default {
padding-left: 16px;
font-size: 12px;
}
.listBox{
height:120px;
overflow: auto;
.list-item {
margin-bottom: 6px;
padding: 0 16px;
@ -81,4 +91,8 @@ export default {
}
}
}
}
</style>

View File

@ -59,7 +59,7 @@ export default {
};
},
mounted() {
console.log("传过来了吗", this.towerList, this.totalTowerDev);
// console.log("------", this.towerList, this.totalTowerDev);
// xy 0
//var datax = [],datay =[]
//this.towerList.forEach((item)=>{

View File

@ -10,11 +10,13 @@
<div class="enter">进场人数</div>
<div class="outer">出场人数</div>
</div>
<div class="list-item" :class="i === 2 ? 'offline' : 'online'" v-for="i in 3" :key="i">
<div class="status">在线</div>
<div class="label">1号塔吊</div>
<div class="enter">66</div>
<div class="outer">99</div>
<div class="listBox">
<div class="list-item" :class="item.deviceState ==1 ? 'offline' : 'online'" v-for="(item,index) in ufaceList.devList" :key="index">
<div class="status">{{item.deviceState ==1 ? '在线' :'离线'}}</div>
<div class="label">{{item.devName}}</div>
<div class="enter">{{item.isEnter}}</div>
<div class="outer">{{item.outTotalNum}}</div>
</div>
</div>
</div>
</DeviceCard>
@ -30,15 +32,26 @@ export default {
title: {
type: String,
default: ''
},
ufaceList:{
type: Object,
default: []
}
},
data() {
return {}
},
mounted(){
// console.log('--------------', this.ufaceList)
}
}
</script>
<style lang="less" scoped>
::-webkit-scrollbar {
width: 3px;
color: #636364;
}
.list {
padding: 0 10px;
color: #fff;
@ -59,6 +72,9 @@ export default {
text-align: right;
}
}
.listBox{
height:100px;
overflow:auto;
.list-item {
margin-bottom: 6px;
padding: 0 16px;
@ -99,4 +115,6 @@ export default {
}
}
}
}
</style>