This commit is contained in:
caozehui
2025-08-28 16:29:00 +08:00
parent 8b578d4d8b
commit 6e979c5dcb
3 changed files with 15 additions and 6 deletions

View File

@@ -292,6 +292,7 @@ const getResults = async () => {
const close = () => {
visible.value = false
formContent.num=''
// 可以在这里添加其他清理逻辑
}

View File

@@ -8,7 +8,8 @@
<el-input v-model='formContent.scriptName' :disabled="true"/>
</el-form-item>
<el-form-item label="误差体系">
<el-select :disabled="checkStore.showDetailType===2 || checkStore.showDetailType===0" v-model="formContent.errorSysId" placeholder="请选择误差体系" autocomplete="off"
<el-select :disabled="checkStore.showDetailType===2 || checkStore.showDetailType===0" v-model="formContent.errorSysId" placeholder="请选择误差体系"
autocomplete="off"
@change="handleErrorSysChange">
<el-option
v-for="(option) in pqErrorList"
@@ -107,7 +108,6 @@ import {reactive, ref, watch} from 'vue'
import DataCheckResultTable from './dataCheckResultTable.vue'
import DataCheckRawDataTable from './dataCheckRawDataTable.vue'
import {CheckData} from "@/api/check/interface";
import {useDictStore} from "@/stores/modules/dict";
import {useCheckStore} from "@/stores/modules/check";
import {changeErrorSystem, deleteTempTable, exportRawData, getFormData, getTableData, getTreeData, reCalculate} from "@/api/check/test";
import {generateDevReport, getPqErrSysList} from '@/api/plan/plan'
@@ -115,6 +115,11 @@ import {useDownload} from "@/hooks/useDownload";
import {Histogram, Postcard} from "@element-plus/icons-vue";
import {ResultEnum} from "@/enums/httpEnum";
import {ElMessage} from "element-plus";
import {useDictStore} from "@/stores/modules/dict";
import {useModeStore} from "@/stores/modules/mode";
const dictStore = useDictStore()
const modeStore = useModeStore()
const {appendToBody} = withDefaults(defineProps<{
appendToBody: boolean
@@ -125,7 +130,6 @@ const defaultProps = {
children: "children",
};
const dictStore = useDictStore()
const checkStore = useCheckStore()
const visible = ref(false)
@@ -226,6 +230,7 @@ const handleErrorSysChange = async () => {
errorSysId: formContent.errorSysId,
deviceId: deviceId,
code: checkStore.plan.code + '',
patternId: dictStore.getDictData('Pattern').find(item => item.name === modeStore.currentMode)?.id ?? '',
}).then((res) => {
if (res.code === ResultEnum.SUCCESS) {
ElMessage.success('切换误差体系成功')
@@ -440,7 +445,7 @@ const open = async (_deviceId: string, chnNum: string, _scriptType: string | nul
}
const handleGenerateReport = async () => {
await generateDevReport({'planId': checkStore.plan.id, 'devIdList': [deviceId],'scriptId':checkStore.plan.scriptId,'planCode':planCode})
await generateDevReport({'planId': checkStore.plan.id, 'devIdList': [deviceId], 'scriptId': checkStore.plan.scriptId, 'planCode': planCode})
ElMessage.success({message: `报告生成成功!`})
}
@@ -450,7 +455,8 @@ const handleReCalculate = async () => {
scriptId: checkStore.plan.scriptId,
errorSysId: formContent.errorSysId,
deviceId: deviceId,
code: checkStore.plan.code + ''
code: checkStore.plan.code + '',
patternId: dictStore.getDictData('Pattern').find(item => item.name === modeStore.currentMode)?.id ?? '',
}).then((res) => {
ElMessage.success('重新计算成功!')
// if (originErrorSysId != formContent.errorSysId) {
@@ -596,7 +602,7 @@ const dataToShow = (num: number): string => {
if (num == null || num == undefined) {
return '/'
}
return num+''
return num + ''
}