三项不平衡补充序分量

This commit is contained in:
caozehui
2026-07-02 15:00:19 +08:00
parent 3135f76a2f
commit 131adc81a7
7 changed files with 72 additions and 29 deletions

View File

@@ -20,7 +20,7 @@ VITE_COMPANY_WEBSITE=http://www.shining-electric.com/
# 开发环境跨域代理,支持配置多个
VITE_PROXY=[["/api","http://127.0.0.1:18093/"]]
VITE_PROXY=[["/api","http://127.0.0.1:18092/"]]
#VITE_PROXY=[["/api","http://192.168.1.124:18092/"]]
#VITE_PROXY=[["/api","http://192.168.2.125:18092/"]]
VITE_IS_SHOW_RAW_DATA=true

View File

@@ -23,7 +23,7 @@ VITE_PWA=true
# 线上环境接口地址
#VITE_API_URL="/api" # 打包时用
VITE_API_URL="http://127.0.0.1:18093/"
VITE_API_URL="http://127.0.0.1:18092/"
VITE_COMPANY_WEBSITE=http://www.shining-electric.com/
VITE_IS_SHOW_RAW_DATA=true
# 开启激活验证

View File

@@ -6,9 +6,9 @@
style="width: 100%;">
<el-table-column type="index" label="序号" width="70" fixed="left"/>
<el-table-column prop="time" label="数据时间"/>
<el-table-column v-if="!isThreePhase && phaseA==1" prop="dataA" :label="'A相'+(unit==''?'':''+unit+'')"/>
<el-table-column v-if="!isThreePhase && phaseB==1" prop="dataB" :label="'B相'+(unit==''?'':''+unit+'')"/>
<el-table-column v-if="!isThreePhase && phaseC==1" prop="dataC" :label="'C相'+(unit==''?'':''+unit+'')"/>
<el-table-column v-if="!isThreePhase && phaseA==1" prop="dataA" :label="labelA+(unit==''?'':''+unit+'')"/>
<el-table-column v-if="!isThreePhase && phaseB==1" prop="dataB" :label="labelB+(unit==''?'':''+unit+'')"/>
<el-table-column v-if="!isThreePhase && phaseC==1" prop="dataC" :label="labelC+(unit==''?'':''+unit+'')"/>
<el-table-column v-if="!isThreePhase && phaseT === 1" prop="dataT" :label="tableHeader+(unit==''?'':''+unit+'')"/>
<el-table-column v-if="isThreePhase" prop="dataB" :label="'负序不平衡度'+(unit==''?'':''+unit+'')"/>
</el-table>
@@ -20,13 +20,30 @@
import {CheckData} from "@/api/check/interface";
import {computed} from "vue";
const {tableData, currentScriptTypeName} = defineProps<{
const {tableData, currentCheckItem} = defineProps<{
tableData: CheckData.RawDataItem[]
currentScriptTypeName: string
currentCheckItem: string
}>()
const emit = defineEmits(['exportRawDataHandler'])
const labelA = computed(() => {
if(currentCheckItem.includes('电压序分量')){
return '正序分量'
}
return 'A相'
})
const labelB = computed(() => {
if(currentCheckItem.includes('电压序分量')){
return '负序分量'
}
return 'B相'
})
const labelC = computed(() => {
if(currentCheckItem.includes('电压序分量')){
return '零序分量'
}
return 'C相'
})
const unit = computed(() => {
return tableData.length > 0 ? tableData[0].unit : '';
})
@@ -46,15 +63,16 @@ const phaseT = computed(() => {
})
const tableHeader = computed(() => {
if (phaseT.value === 1) {
let index = currentScriptTypeName.indexOf('=');
return currentScriptTypeName.substring(0, index);
if(currentCheckItem.includes('三相电压负序不平衡度')){
return '三相电压不平衡度'
}
return currentScriptTypeName
if(currentCheckItem.includes('三相电流负序不平衡度')){
return '三相电流不平衡度'
}
return currentCheckItem
})
const isThreePhase = computed(() => {
return currentScriptTypeName.includes('三相电压不平衡度') || currentScriptTypeName.includes('三相电流不平衡度')
return currentCheckItem.includes('三相电压负序不平衡度') || currentCheckItem.includes('三相电流负序不平衡度')
})
const exportData = () => {

View File

@@ -12,7 +12,7 @@
<!-- {{ '通道' + row.chnNum }}-->
<!-- </template>-->
<!-- </el-table-column>-->
<el-table-column label="A" v-if="phaseA === 1">
<el-table-column :label="labelA" v-if="phaseA === 1">
<el-table-column prop="stdA" :label="'标准值' + (outerUnit == '' ? '' : '' + outerUnit + '')" />
<el-table-column prop="dataA" :label="'被检值' + (outerUnit == '' ? '' : '' + outerUnit + '')" />
<el-table-column prop="isDataA" label="检测结果">
@@ -33,7 +33,7 @@
</template>
</el-table-column>
</el-table-column>
<el-table-column label="B" v-if="phaseB === 1">
<el-table-column :label="labelB" v-if="phaseB === 1">
<el-table-column prop="stdB" :label="'标准值' + (outerUnit == '' ? '' : '' + outerUnit + '')" />
<el-table-column prop="dataB" :label="'被检值' + (outerUnit == '' ? '' : '' + outerUnit + '')" />
<el-table-column prop="isDataB" label="检测结果">
@@ -55,7 +55,7 @@
</template>
</el-table-column>
</el-table-column>
<el-table-column label="C" v-if="phaseC === 1">
<el-table-column :label="labelC" v-if="phaseC === 1">
<el-table-column prop="stdC" :label="'标准值' + (outerUnit == '' ? '' : '' + outerUnit + '')" />
<el-table-column prop="dataC" :label="'被检值' + (outerUnit == '' ? '' : '' + outerUnit + '')" />
<el-table-column prop="isDataC" label="检测结果">
@@ -107,9 +107,9 @@
import { computed } from 'vue'
import { CheckData } from '@/api/check/interface'
const { tableData, currentScriptTypeName } = defineProps<{
const { tableData, currentCheckItem } = defineProps<{
tableData: CheckData.CheckResult[]
currentScriptTypeName: string
currentCheckItem: string
}>()
const outerUnit = computed(() => {
@@ -129,6 +129,25 @@ const innerUnitT = computed(() => {
return tableData.length > 0 ? tableData[0].unitT : ''
})
const labelA = computed(() => {
if(currentCheckItem.includes('电压序分量')){
return '正序分量'
}
return 'A相'
})
const labelB = computed(() => {
if(currentCheckItem.includes('电压序分量')){
return '负序分量'
}
return 'B相'
})
const labelC = computed(() => {
if(currentCheckItem.includes('电压序分量')){
return '零序分量'
}
return 'C相'
})
const phaseA = computed(() => {
return tableData.length <= 0 || tableData[0].dataA == null || tableData[0].dataA == '/' ? 0 : 1
})
@@ -144,11 +163,13 @@ const phaseT = computed(() => {
})
const tableHeader = computed(() => {
if (phaseT.value === 1) {
let index = currentScriptTypeName.indexOf('=')
return currentScriptTypeName.substring(0, index)
}
return currentScriptTypeName
if(currentCheckItem.includes('三相电压负序不平衡度')){
return '三相电压不平衡度'
}
if(currentCheckItem.includes('三相电流负序不平衡度')){
return '三相电流不平衡度'
}
return currentCheckItem
})
// const maxErrorStr = computed((data) => {

View File

@@ -136,13 +136,13 @@
<el-tab-pane label="检测结果" name="resultTab">
<DataCheckResultTable
:tableData="checkResultData"
:currentScriptTypeName="currentScriptTypeName"
:currentCheckItem="currentCheckItem"
/>
</el-tab-pane>
<el-tab-pane label="原始数据" name="rawDataTab">
<DataCheckRawDataTable
:tableData="rawTableData"
:currentScriptTypeName="currentScriptTypeName"
:currentCheckItem="currentCheckItem"
@exportRawDataHandler="exportRawDataHandler"
/>
</el-tab-pane>

View File

@@ -47,7 +47,7 @@
:row.devices[index1].chnResult[index2].icon==='CircleCheckFilled'?'符合'
:row.devices[index1].chnResult[index2].icon==='Close'?'不符合'
:row.devices[index1].chnResult[index2].icon==='WarnTriangleFilled'?'数据异常'
:row.devices[index1].chnResult[index2].icon==='Loading'?'检测中':'连接中断'"
:row.devices[index1].chnResult[index2].icon==='Loading'?'检测中':'不参与误差比较'"
placement='right'>
<!-- 通道状态按钮 -->
<el-button

View File

@@ -302,7 +302,7 @@ const unit = [
{
label: '电流',
unit: props.valueCode == 'Absolute' ? 'A' : '%'
},
}
]
// 参考设定值添加单位
@@ -320,8 +320,12 @@ const setUnit = (row: any) => {
let o = props.valueCode == 'Absolute' ? 'A' : '%'
row.name == '电流有效值' ? (text = o) : ''
row.name == '电流相角' ? (text = '°') : ''
} else if (row.name == '电压序分量') {
text = '%Un V'
} else if (row.name == '电流序分量') {
text = '%In A'
} else {
text = unit.filter(item => item.label == row.pname)[0]?.unit
text = unit.filter(item => item.label == row.pname)[0]?.unit
}
return text || ''