fast(我的项目):我的项目设备管理添加空间标签

This commit is contained in:
fhysy 2024-10-31 17:26:56 +08:00
parent bb8e04d1bc
commit 1b4bfe6082
1 changed files with 12 additions and 2 deletions

View File

@ -128,6 +128,9 @@
</div> </div>
</template> </template>
<template slot="cardBody"> <template slot="cardBody">
<div style="margin-bottom: 10px">
<el-tag v-for="(val,i) in devItem.deviceLabel" :key="i" size="mini" style="margin-right: 5px;margin-bottom: 5px">{{ val }}</el-tag>
</div>
<div class="object-device-body"> <div class="object-device-body">
<div class="card-body-info"> <div class="card-body-info">
<div class="card-body-left"> <div class="card-body-left">
@ -376,7 +379,14 @@ export default {
this.queryParams this.queryParams
) )
).then((res) => { ).then((res) => {
this.list = res.rows; let list = res.rows.map(item=>{
if(item.deviceLabel && item.deviceLabel[0] == '空间'){
item.deviceLabel.shift();
return item;
}
return item;
})
this.list = list || [];
if (this.stompClient) { if (this.stompClient) {
this.closeSocket(); this.closeSocket();
} }
@ -477,7 +487,7 @@ export default {
justify-content: flex-start; justify-content: flex-start;
.object-device-card { .object-device-card {
width: 285px; width: 285px;
height: 164px; //height: 164px;
background: #ffffff; background: #ffffff;
border: 1px solid #e4ebf4; border: 1px solid #e4ebf4;
box-shadow: 0px 0px 8px 0px rgba(17, 76, 157, 0.26); box-shadow: 0px 0px 8px 0px rgba(17, 76, 157, 0.26);