比对模式根据配置文件动态展示原始数据、历史趋势图

This commit is contained in:
caozehui
2026-02-02 10:14:41 +08:00
parent e4de4fe43c
commit ad02fac4ff

View File

@@ -165,7 +165,7 @@
:currentScriptTypeName="currentScriptTypeName" :currentScriptTypeName="currentScriptTypeName"
/> />
</el-tab-pane> </el-tab-pane>
<el-tab-pane label="原始数据" name="rawDataTab"> <el-tab-pane label="原始数据" name="rawDataTab" v-if="!isBusiness">
<CompareDataCheckRawDataTable <CompareDataCheckRawDataTable
v-if="activeTab === 'rawDataTab'" v-if="activeTab === 'rawDataTab'"
:tableData="rawTableData.length == 0 ? [] : currentRawTableData" :tableData="rawTableData.length == 0 ? [] : currentRawTableData"
@@ -173,7 +173,7 @@
:currentScriptTypeName="currentScriptTypeName" :currentScriptTypeName="currentScriptTypeName"
/> />
</el-tab-pane> </el-tab-pane>
<el-tab-pane label="历史趋势" name="chartTab" v-if="!isWaveData"> <el-tab-pane label="历史趋势" name="chartTab" v-if="!isWaveData&&!isBusiness">
<CompareDataCheckChart <CompareDataCheckChart
v-if="activeTab === 'chartTab'" v-if="activeTab === 'chartTab'"
:tableData="rawTableData.length == 0 ? [] : currentRawTableData" :tableData="rawTableData.length == 0 ? [] : currentRawTableData"
@@ -198,17 +198,12 @@ import { Histogram, Postcard } from '@element-plus/icons-vue'
import {generateDevReport, getPqErrSysList} from '@/api/plan/plan' import {generateDevReport, getPqErrSysList} from '@/api/plan/plan'
import {useModeStore} from '@/stores/modules/mode' // 引入模式 store import {useModeStore} from '@/stores/modules/mode' // 引入模式 store
import {useDictStore} from '@/stores/modules/dict' import {useDictStore} from '@/stores/modules/dict'
import { import {changeErrorSystem, deleteTempTable, getContrastFormContent, getContrastResult, getScriptList, reCalculate} from '@/api/check/test'
changeErrorSystem,
deleteTempTable,
getContrastFormContent,
getContrastResult,
getScriptList,
reCalculate
} from '@/api/check/test'
import {ElMessage} from 'element-plus' import {ElMessage} from 'element-plus'
import {ResultEnum} from '@/enums/httpEnum' import {ResultEnum} from '@/enums/httpEnum'
const isShowRawData = import.meta.env.VITE_IS_SHOW_RAW_DATA
const {appendToBody = true} = defineProps<{ const {appendToBody = true} = defineProps<{
appendToBody: boolean appendToBody: boolean
}>() }>()
@@ -275,6 +270,11 @@ const currentRawTableData = computed(() => {
return Array.isArray(data) ? data : [] return Array.isArray(data) ? data : []
}) })
const isBusiness = computed(() => {
console.log(isShowRawData)
return modeStore.currentMode === '比对式' && isShowRawData
})
const open = async (row: any, chnNum: string, deviceId: string | null, source: number) => { const open = async (row: any, chnNum: string, deviceId: string | null, source: number) => {
activeTab.value = 'resultTab' activeTab.value = 'resultTab'
isWaveData.value = false isWaveData.value = false
@@ -689,6 +689,7 @@ defineExpose({
overflow-y: auto; overflow-y: auto;
overflow-x: auto; overflow-x: auto;
margin-right: 10px; margin-right: 10px;
.content-tree { .content-tree {
width: 100%; width: 100%;
height: 100%; height: 100%;
@@ -725,10 +726,12 @@ defineExpose({
margin-top: 10px; margin-top: 10px;
margin-bottom: 10px; margin-bottom: 10px;
display: flex; display: flex;
.el-tabs { .el-tabs {
width: 100%; width: 100%;
} }
} }
.content-left { .content-left {
height: 100%; height: 100%;
border: 1px solid #e0e0e0; border: 1px solid #e0e0e0;
@@ -740,6 +743,7 @@ defineExpose({
} }
} }
} }
:deep(.el-tabs--border-card > .el-tabs__content) { :deep(.el-tabs--border-card > .el-tabs__content) {
height: 367px; height: 367px;
} }