修改实时数据
This commit is contained in:
@@ -4,33 +4,18 @@
|
||||
<div class="harmonic_select">
|
||||
<el-form :model="searchForm" id="history_select">
|
||||
<el-form-item label="稳态指标">
|
||||
<el-select
|
||||
multiple
|
||||
collapse-tags
|
||||
collapse-tags-tooltip
|
||||
v-model="searchForm.index"
|
||||
placeholder="请选择统计指标"
|
||||
:multiple-limit="3"
|
||||
value-key="id"
|
||||
>
|
||||
<el-option
|
||||
v-for="(item, index) in indexOptions"
|
||||
:label="item.name"
|
||||
:key="index"
|
||||
:value="item"
|
||||
></el-option>
|
||||
<el-select multiple collapse-tags collapse-tags-tooltip v-model="searchForm.index"
|
||||
placeholder="请选择统计指标" :multiple-limit="3" value-key="id">
|
||||
<el-option v-for="(item, index) in indexOptions" :label="item.name" :key="index"
|
||||
:value="item"></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<!-- <el-button type="primary" :loading="loading" @click="init">查询</el-button> -->
|
||||
</el-form>
|
||||
</div>
|
||||
<div class="harmonic_body">
|
||||
<div
|
||||
class="harmonic_body_charts"
|
||||
:style="{ height: height }"
|
||||
v-for="(item, index) in searchForm.index"
|
||||
:key="index"
|
||||
>
|
||||
<div class="harmonic_body_charts" :style="{ height: height }" v-for="(item, index) in searchForm.index"
|
||||
:key="index">
|
||||
<MyEchart :ref="setChildRef(index)" :options="item.echartsData" :isInterVal="true"></MyEchart>
|
||||
</div>
|
||||
</div>
|
||||
@@ -363,8 +348,8 @@ const init = () => {
|
||||
? (height = mainHeight(275, 3).height)
|
||||
: (height = mainHeight(275, searchForm.value.index.length).height)
|
||||
item.children.map((zz: any, zzIndex: any) => {
|
||||
let [min, max] = yMethod(allDataList.value)
|
||||
console.log(max, min)
|
||||
|
||||
|
||||
item.echartsData.series.push({
|
||||
name: zz.phase,
|
||||
type: 'line',
|
||||
@@ -377,15 +362,19 @@ const init = () => {
|
||||
smooth: true, // 这里设置平滑曲线
|
||||
symbol: 'none' // 设置为 'none' 去掉折点小圆
|
||||
})
|
||||
item.echartsData.yAxis.max = max
|
||||
item.echartsData.yAxis.min = min
|
||||
|
||||
})
|
||||
let arrList=item.children?.map(item => item.yMethodList.map(val => val[1])).flat()
|
||||
let [min, max] = yMethod(arrList.length==0?[0]:arrList)
|
||||
console.log("🚀 ~ item.children.map ~ zz.yMethodList:",min, max )
|
||||
item.echartsData.yAxis.max = max
|
||||
item.echartsData.yAxis.min = min
|
||||
})
|
||||
|
||||
loading.value = false
|
||||
}
|
||||
|
||||
onMounted(() => {})
|
||||
onMounted(() => { })
|
||||
defineExpose({ resetData, setHarmonicSpectrumData })
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
|
||||
Reference in New Issue
Block a user