|
|
|
@ -1,5 +1,5 @@
|
|
|
|
|
<template>
|
|
|
|
|
<div :class="className" :style="{height:height,width:width}" />
|
|
|
|
|
<div :class="className" :style="{height:height,width:width}"/>
|
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
<script>
|
|
|
|
@ -30,9 +30,9 @@ export default {
|
|
|
|
|
data() {
|
|
|
|
|
return {
|
|
|
|
|
chart: null,
|
|
|
|
|
XData:['高温报警', '低压报警', '电池电量报警', '位置报警'],
|
|
|
|
|
dataOne:[1,2,3],
|
|
|
|
|
dataTwo:[3,4,5]
|
|
|
|
|
XData: ['高温报警', '低压报警', '电池电量报警', '位置报警'],
|
|
|
|
|
dataOne: [1, 2, 3],
|
|
|
|
|
dataTwo: [3, 4, 5]
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
mounted() {
|
|
|
|
@ -50,7 +50,7 @@ export default {
|
|
|
|
|
methods: {
|
|
|
|
|
setData(e) {
|
|
|
|
|
console.log(e)
|
|
|
|
|
let item = e.filter(val => !!val )
|
|
|
|
|
let item = e.filter(val => !!val)
|
|
|
|
|
this.XData = item.map(val => val.time || '')
|
|
|
|
|
this.dataOne = item.map(val => val.course)
|
|
|
|
|
this.dataTwo = item.map(val => val.textureDepth)
|
|
|
|
@ -78,10 +78,10 @@ export default {
|
|
|
|
|
},
|
|
|
|
|
toolbox: {
|
|
|
|
|
feature: {
|
|
|
|
|
dataView: { show: true, readOnly: false },
|
|
|
|
|
magicType: { show: true, type: ['line', 'bar'] },
|
|
|
|
|
restore: { show: true },
|
|
|
|
|
saveAsImage: { show: true }
|
|
|
|
|
dataView: {show: true, readOnly: false},
|
|
|
|
|
magicType: {show: true, type: ['line', 'bar']},
|
|
|
|
|
restore: {show: true},
|
|
|
|
|
saveAsImage: {show: true}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
legend: {
|
|
|
|
|