修改看板

boardTest
夜笙歌 3 weeks ago
parent 6e3e0a4d14
commit c1d79c601f

@ -63,6 +63,7 @@
"vue-cropper": "0.5.5", "vue-cropper": "0.5.5",
"vue-meta": "2.4.0", "vue-meta": "2.4.0",
"vue-router": "3.4.9", "vue-router": "3.4.9",
"vue-seamless-scroll": "^1.1.23",
"vuedraggable": "2.24.3", "vuedraggable": "2.24.3",
"vuex": "3.6.0", "vuex": "3.6.0",
"xlsx": "^0.17.0" "xlsx": "^0.17.0"

@ -2,7 +2,6 @@
<div style="height: 100vh;width: 100vw;overflow: hidden;position: relative;"> <div style="height: 100vh;width: 100vw;overflow: hidden;position: relative;">
<div <div
:style="`width:100%;height:100%;background-image:url(${bg});background-repeat: no-repeat;background-size: 100% 100%;`"> :style="`width:100%;height:100%;background-image:url(${bg});background-repeat: no-repeat;background-size: 100% 100%;`">
<!-- <img :src="model" alt="">-->
</div> </div>
<div class="title">青岛胶东机场行李输送线</div> <div class="title">青岛胶东机场行李输送线</div>
<div class="item1"> <div class="item1">
@ -233,13 +232,40 @@
</div> </div>
</div> </div>
</div> </div>
<div class="scTable1">
<div style="background-color: #094170">
<div class="scrollTable" style="font-weight: bold;">
报警信息
</div>
</div>
<vue-seamless-scroll
:class-option="chart1TableOption"
:data="almTableData"
style="height: calc(100% - 33px);overflow:hidden; "
>
<div
v-for="(item, index) in almTableData"
:key="index"
>
<div :style='"background-color:" + ((index % 2 === 0)? "#053460":"#032d57") '>
<div
class="scrollTable">
{{ item.ruleName }}
</div>
</div>
</div>
</vue-seamless-scroll>
</div>
</div> </div>
</template> </template>
<script> <script>
import bg from '@/assets/images/bg.jpg' import bg from '@/assets/images/bg.jpg'
import vueSeamlessScroll from 'vue-seamless-scroll'
export default { export default {
components: {vueSeamlessScroll},
data() { data() {
return { return {
bg, bg,
@ -263,6 +289,18 @@ export default {
'E0013': {}, 'E0013': {},
'E0014': {}, 'E0014': {},
}, },
almTableData: [],
chart1TableOption: {
step: 0.5, //
limitMoveNum: 12, // this.dataList.length
hoverStop: true, // stop
direction: 1, // 0 1 2 3
openWatch: true, // dom
singleHeight: 0, // (0) direction => 0/1
singleWidth: 0, // (0) direction => 2/3
waitTime: 0,
autoPlay: true,
},
deviceMap: { deviceMap: {
temperature: '温度', temperature: '温度',
humidity: '湿度', humidity: '湿度',
@ -291,12 +329,42 @@ export default {
vibrationAcceleration: e.deviceParam.vibrationAcceleration || 0, vibrationAcceleration: e.deviceParam.vibrationAcceleration || 0,
vibrationTemp: e.deviceParam.vibrationTemp || 0, vibrationTemp: e.deviceParam.vibrationTemp || 0,
}) })
// this.$set(this.almData[deviceID], e.deviceParam.monitorId, e.alarmRules.map(v => { this.$set(this.almData[deviceID], e.deviceParam.monitorId, e.alarmRules)
// return v.ruleName // this.$set(this.almData[deviceID], e.deviceParam.monitorId, [
// })) // {
this.$set(this.almData[deviceID], e.deviceParam.monitorId, ['报警信息']) // "objid": 30020,
// "monitorId": "T0002_0101 ",
// "ruleId": null,
// "ruleName": "T0002_0101 20",
// "triggerRule": 0,
// "monitorField": 0,
// "triggerValue": 20,
// "cause": "-"
// },
// {
// "objid": 30021,
// "monitorId": "T0002_0101 ",
// "ruleId": null,
// "ruleName": "T0002_0101 30",
// "triggerRule": 1,
// "monitorField": 0,
// "triggerValue": 30,
// "cause": "-"
// }
// ])
let list = []
Object.values(this.almData).forEach((item) => {
Object.values(item).forEach((item1) => {
item1.forEach((item2) => {
list.push(item2)
})
})
})
this.almTableData = list
// this.$set(this.almData[deviceID], e.deviceParam.monitorId, [''])
} }
console.log(this.deviceData.E0014)
} }
) )
}, },
@ -305,6 +373,18 @@ export default {
} }
</script> </script>
<style lang="less" scoped> <style lang="less" scoped>
.scrollTable {
color: rgb(185, 186, 192);
margin: auto 0px;
padding: 4px 0;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
text-align: center;
display: inline-block;
width: 100%;
}
.title { .title {
position: absolute; position: absolute;
top: 2%; top: 2%;
@ -316,6 +396,29 @@ export default {
color: white; color: white;
} }
.scTable1 {
position: absolute;
top: 48%;
left: 2.5%;
width: 20%;
height: 45%;
overflow: hidden;
}
.line:before {
content: "";
position: absolute;
top: 100%;
left: 50%;
transform: translate(-50%, -50%);
width: 6px;
height: 6px;
border-radius: 50%;
background-color: #B8DFFA;
border: 2px solid #3E649F;
}
.item1 { .item1 {
right: 0%; right: 0%;
bottom: 27%; bottom: 27%;
@ -328,13 +431,13 @@ export default {
.line { .line {
position: absolute; position: absolute;
top: 100%; top: calc(100% - 8px);
left: 100%; left: calc(100% - 8px);
transform-origin: left top; transform-origin: center top;
transform: translateX(-50%) rotate(-45deg); transform: translateX(-50%) rotate(-45deg);
width: 1px; width: 1px;
height: 3vh; height: 3vh;
background-color: #fff; background-color: #3E649F;
} }
} }
@ -350,13 +453,13 @@ export default {
.line { .line {
position: absolute; position: absolute;
top: 100%; top: calc(100% - 8px);
left: 100%; left: calc(100% - 8px);
transform-origin: left top; transform-origin: center top;
transform: translateX(-50%) rotate(-45deg); transform: translateX(-50%) rotate(-45deg);
width: 1px; width: 1px;
height: 3vh; height: 3vh;
background-color: #fff; background-color: #3E649F;
} }
} }
@ -372,13 +475,13 @@ export default {
.line { .line {
position: absolute; position: absolute;
top: 100%; top: calc(100% - 8px);
left: 0%; left: 8px;
transform-origin: right top; transform-origin: center top;
transform: translateX(-50%) rotate(45deg); transform: translateX(-50%) rotate(45deg);
width: 1px; width: 1px;
height: 3vh; height: 3vh;
background-color: #fff; background-color: #3E649F;
} }
} }
@ -396,13 +499,13 @@ export default {
.line { .line {
position: absolute; position: absolute;
top: 100%; top: calc(100% - 8px);
left: 60%; left: calc(60% - 8px);
transform-origin: left top; transform-origin: center top;
transform: translateX(-50%) rotate(-45deg); transform: translateX(-50%) rotate(-45deg);
width: 1px; width: 1px;
height: 3vh; height: 3vh;
background-color: #fff; background-color: #3E649F;
} }
} }
@ -495,6 +598,7 @@ export default {
} }
.alm { .alm {
display: none;
animation: colourSwitching 0.5s infinite; animation: colourSwitching 0.5s infinite;
} }

Loading…
Cancel
Save