Commit 9f8a48d0 by 黄麒宇

大屏逻辑更改

parent acd18221
...@@ -17,12 +17,12 @@ ...@@ -17,12 +17,12 @@
</div> </div>
<div class="percent"> <div class="percent">
<div class="poItem"> <div class="poItem">
<span v-if="currentData && currentData.length > 0">{{currentData[1].name}}</span> <span v-if="currentData && currentData.length > 0">{{ currentData.length == 1 ? currentData[0].name : currentData[1].name}}</span>
</div> </div>
<div class="item"> <div class="item">
<span>当前温度</span> <span>当前温度</span>
<dv-decoration-9 style="width: 1.5rem;height: 1.5rem;margin-left: 35px;" :color="colors2"> <dv-decoration-9 style="width: 1.5rem;height: 1.5rem;margin-left: 35px;" :color="colors2">
<span style="font-size: 0.25rem;color: rgb(61,231,201);font-weight: bold;" v-if="currentData && currentData.length > 0">{{ currentData[1].temperature }}</span> <span style="font-size: 0.25rem;color: rgb(61,231,201);font-weight: bold;" v-if="currentData && currentData.length > 0">{{ currentData.length == 1 ? currentData[0].name : currentData[1].temperature }}</span>
</dv-decoration-9> </dv-decoration-9>
</div> </div>
<div class="item"> <div class="item">
...@@ -95,6 +95,9 @@ export default { ...@@ -95,6 +95,9 @@ export default {
waveHeight: 20, // 波浪高度 waveHeight: 20, // 波浪高度
colors: colors1 colors: colors1
} }
if(res.data.length == 1) {
this.water2 == this.water1
} else {
this.water2 = { this.water2 = {
data: [parseFloat(res.data[1].humidity).toFixed(2)], data: [parseFloat(res.data[1].humidity).toFixed(2)],
shape: "roundRect", shape: "roundRect",
...@@ -103,6 +106,7 @@ export default { ...@@ -103,6 +106,7 @@ export default {
waveHeight: 20, waveHeight: 20,
colors: colors2 colors: colors2
} }
}
}) })
}) })
} }
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
<div class="d-flex jc-center"> <div class="d-flex jc-center">
<dv-decoration-8 :color="['#568aea', '#131E88']" style="width:2.5rem;height:.425rem;" /> <dv-decoration-8 :color="['#568aea', '#131E88']" style="width:2.5rem;height:.425rem;" />
<div class="title"> <div class="title">
<span class="title-text">平面库监控平台</span> <span class="title-text">{{$route.query.storeCode}}号库房监控平台</span>
</div> </div>
<dv-decoration-8 <dv-decoration-8
:reverse="true" :reverse="true"
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论