实时数据一二次值单位
This commit is contained in:
@@ -5,7 +5,7 @@
|
||||
<div class="view_top">
|
||||
<!-- 左侧仪表盘 -->
|
||||
<div class="view_top_left">
|
||||
<div class="left_charts_title">电压有效值(kV)</div>
|
||||
<div class="left_charts_title">电压有效值({{ voltageUnit }})</div>
|
||||
<div class="left_charts">
|
||||
<MyEchart :pieInterVal="true" ref="pieChart1" :options="echartsDataV1"></MyEchart>
|
||||
</div>
|
||||
@@ -45,7 +45,7 @@
|
||||
<div class="view_bot">
|
||||
<vxe-table border height="" :data="realList" :column-config="{ resizable: true, tooltip: true }"
|
||||
:tooltip-config="{ enterable: true }">
|
||||
<vxe-colgroup align="center" title="电压有效值(kV)">
|
||||
<vxe-colgroup align="center" :title="`电压有效值(${voltageUnit})`">
|
||||
<vxe-column align="center" field="vRmsA" title="A相"></vxe-column>
|
||||
<vxe-column align="center" field="vRmsB" title="B相"></vxe-column>
|
||||
<vxe-column align="center" field="vRmsC" title="C相"></vxe-column>
|
||||
@@ -69,11 +69,11 @@
|
||||
<br />
|
||||
<vxe-table border height="" :data="realList" :column-config="{ resizable: true, tooltip: true }"
|
||||
:tooltip-config="{ enterable: true }">
|
||||
<vxe-column align="center" field="freq" width="140" title="频率(Hz)"></vxe-column>
|
||||
<vxe-column align="center" field="freqDev" width="120" title="频率偏差(Hz)"></vxe-column>
|
||||
<vxe-column align="center" field="freqDev" width="140" title="频率(Hz)"></vxe-column>
|
||||
<vxe-column align="center" field="freq" width="120" title="频率偏差(Hz)"></vxe-column>
|
||||
<vxe-column align="center" width="180" field="vUnbalance" title="电压不平衡度(%)"></vxe-column>
|
||||
<vxe-column align="center" width="180" field="iUnbalance" title="电流不平衡度(%)"></vxe-column>
|
||||
<vxe-colgroup align="center" title="基波电压幅值(kV)">
|
||||
<vxe-colgroup align="center" :title="`基波电压幅值(${voltageUnit})`">
|
||||
<vxe-column align="center" field="v1A" title="A相"></vxe-column>
|
||||
<vxe-column align="center" field="v1B" title="B相"></vxe-column>
|
||||
<vxe-column align="center" field="v1C" title="C相"></vxe-column>
|
||||
@@ -102,7 +102,7 @@
|
||||
<vxe-column align="center" field="iThdB" title="B相"></vxe-column>
|
||||
<vxe-column align="center" field="iThdC" title="C相"></vxe-column>
|
||||
</vxe-colgroup>
|
||||
<vxe-colgroup align="center" title="有功功率(kW)">
|
||||
<vxe-colgroup align="center" :title="`有功功率(${powerUnit})`">
|
||||
<vxe-column align="center" field="pA" title="A相"></vxe-column>
|
||||
<vxe-column align="center" field="pB" title="B相"></vxe-column>
|
||||
<vxe-column align="center" field="pC" title="C相"></vxe-column>
|
||||
@@ -112,7 +112,7 @@
|
||||
<br />
|
||||
<vxe-table border height="" :data="realList" :column-config="{ resizable: true, tooltip: true }"
|
||||
:tooltip-config="{ enterable: true }">
|
||||
<vxe-colgroup align="center" title="无功功率(kVar)">
|
||||
<vxe-colgroup align="center" :title="`无功功率(${reactivePowerUnit})`">
|
||||
<vxe-column align="center" field="qA" title="A相"></vxe-column>
|
||||
<vxe-column align="center" field="qB" title="B相"></vxe-column>
|
||||
<vxe-column align="center" field="qC" title="C相">
|
||||
@@ -122,7 +122,7 @@
|
||||
</vxe-column>
|
||||
<vxe-column align="center" field="qTot" title="总"></vxe-column>
|
||||
</vxe-colgroup>
|
||||
<vxe-colgroup align="center" title="视在功率(kVA)">
|
||||
<vxe-colgroup align="center" :title="`视在功率(${apparentPowerUnit})`">
|
||||
<vxe-column align="center" field="sA" title="A相"></vxe-column>
|
||||
<vxe-column align="center" field="sB" title="B相"></vxe-column>
|
||||
<vxe-column align="center" field="sC" title="C相"></vxe-column>
|
||||
@@ -170,6 +170,10 @@ const echartsDataV3: any = ref({})
|
||||
const echartsDataA1: any = ref({})
|
||||
const echartsDataA2: any = ref({})
|
||||
const echartsDataA3: any = ref({})
|
||||
|
||||
const currentDataLevel = ref('Primary')
|
||||
const previousDataLevel = ref('')
|
||||
|
||||
//渲染中间相角图
|
||||
const initRadioCharts = () => {
|
||||
echartsData1.value = {
|
||||
@@ -542,7 +546,33 @@ const vRadioList: any = ref([])
|
||||
|
||||
const realData = ref<any>({})
|
||||
const realList = ref<any>([])
|
||||
const setRealData = (val: any) => {
|
||||
|
||||
// 计算电压单位
|
||||
const voltageUnit = computed(() => {
|
||||
return currentDataLevel.value === 'Primary' ? 'kV' : 'V'
|
||||
})
|
||||
|
||||
// 计算功率单位
|
||||
const powerUnit = computed(() => {
|
||||
return currentDataLevel.value === 'Primary' ? 'kW' : 'W'
|
||||
})
|
||||
|
||||
// 计算无功功率单位
|
||||
const reactivePowerUnit = computed(() => {
|
||||
return currentDataLevel.value === 'Primary' ? 'kVar' : 'Var'
|
||||
})
|
||||
|
||||
// 计算视在功率单位
|
||||
const apparentPowerUnit = computed(() => {
|
||||
return currentDataLevel.value === 'Primary' ? 'kVA' : 'VA'
|
||||
})
|
||||
|
||||
const setRealData = (val: any,dataLevel:string) => {
|
||||
// 只有当 dataLevel 真正改变时才更新
|
||||
if (dataLevel !== previousDataLevel.value) {
|
||||
currentDataLevel.value = dataLevel
|
||||
previousDataLevel.value = dataLevel
|
||||
}
|
||||
realData.value = val
|
||||
realList.value = [val]
|
||||
initRadioCharts()
|
||||
|
||||
Reference in New Issue
Block a user