This commit is contained in:
sjl
2025-01-13 22:42:14 +08:00
parent b584142f5e
commit 5199ee2db0
8 changed files with 31 additions and 32 deletions

View File

@@ -19,6 +19,6 @@ VITE_API_URL=/api
# 开发环境跨域代理,支持配置多个 # 开发环境跨域代理,支持配置多个
VITE_PROXY=[["/api","http://192.168.1.124:18092/"]] VITE_PROXY=[["/api","http://192.168.1.125:18092/"]]
#VITE_PROXY=[["/api","http://192.168.1.125:18092/"]] #VITE_PROXY=[["/api","http://192.168.1.125:18092/"]]
# VITE_PROXY=[["/api","http://192.168.1.138:8080/"]]张文 # VITE_PROXY=[["/api","http://192.168.1.138:8080/"]]张文

View File

@@ -252,16 +252,16 @@ watch(webMsgSend,function (newValue,oldValue){
firstCoefficientVO.bIeXi = newValue.data.bIeXi; firstCoefficientVO.bIeXi = newValue.data.bIeXi;
firstCoefficientVO.cIeData = parseFloat(newValue.data.cIeData).toFixed(4); firstCoefficientVO.cIeData = parseFloat(newValue.data.cIeData).toFixed(4);
firstCoefficientVO.cIeXi = newValue.data.cIeXi; firstCoefficientVO.cIeXi = newValue.data.cIeXi;
console.log(newValue.data.devName + '对象:', firstCoefficientVO); //console.log(newValue.data.devName + '对象:', firstCoefficientVO);
activeIndex.value++; activeIndex.value++;
} else { } else {
console.log('未找到匹配的'+ newValue.data.devName+'对象'); console.log('未找到匹配的'+ newValue.data.devName+'对象');
} }
} else { } else {
console.log(newValue.data.devName + '数组为空'); //console.log(newValue.data.devName + '数组为空');
} }
} else { } else {
console.log('未找到'+newValue.data.devName+'对应的数组'); //console.log('未找到'+newValue.data.devName+'对应的数组');
} }
} }
break; break;
@@ -508,7 +508,7 @@ const updateErrorState = (index: number, hasError: boolean) => {
const currentTableData = initializeTableData(dataTemplates, i); const currentTableData = initializeTableData(dataTemplates, i);
tableDataMap.set(i,currentTableData) tableDataMap.set(i,currentTableData)
} }
console.log('tableDataMap',tableDataMap); //console.log('tableDataMap',tableDataMap);
} }
const handleCancel=() => { const handleCancel=() => {

View File

@@ -422,9 +422,9 @@ const scrollContainer = ref<HTMLElement | null>(null); // 声明 scrollContainer
const scrollToBottom = () => { const scrollToBottom = () => {
if (scrollContainer.value) { if (scrollContainer.value) {
console.log(scrollContainer.value) //console.log(scrollContainer.value)
scrollContainer.value.scrollTop = scrollContainer.value.scrollHeight; scrollContainer.value.scrollTop = scrollContainer.value.scrollHeight;
console.log(scrollContainer.value) //console.log(scrollContainer.value)
} }
}; };
@@ -541,7 +541,7 @@ function traverseTableData(data: any[], id: string): void {
item[field1] = "danger"; item[field1] = "danger";
item[field2] = "×"; item[field2] = "×";
columnList.value.push(activeIndex.value.toString()); columnList.value.push(activeIndex.value.toString());
console.log(id,activeIndex.value,columnList.value) // console.log(id,activeIndex.value,columnList.value)
} }
else { else {
item[field1] = "success"; item[field1] = "success";
@@ -561,7 +561,7 @@ function traverseTableData(data: any[], id: string): void {
const updateTableData = (id: string) => { const updateTableData = (id: string) => {
traverseTableData(tableData.value, id); traverseTableData(tableData.value, id);
console.log(id) // console.log(id)
}; };
let timer: any = ref(""); let timer: any = ref("");
@@ -582,7 +582,7 @@ const handleFinishTest = () => {
}; };
const handleClick = (row: any) => { const handleClick = (row: any) => {
console.log(111, row) // console.log(111, row)
dataCheckSingleChannelSingleTestDialogVisable.value = true; dataCheckSingleChannelSingleTestDialogVisable.value = true;
}; };
@@ -1885,7 +1885,7 @@ const startTimer = () => {
//if (timer.value !== null) return; // 如果定时器已经启动,则不再重复启动 //if (timer.value !== null) return; // 如果定时器已经启动,则不再重复启动
timer.value = setInterval(() => { timer.value = setInterval(() => {
console.log(activeIndex.value, 111) // console.log(activeIndex.value, 111)
if (activeIndex.value <= activeTotalNum.value) { if (activeIndex.value <= activeTotalNum.value) {
activeIndex.value++; activeIndex.value++;
@@ -1943,10 +1943,10 @@ const startTimer = () => {
} }
else { else {
console.log(activeIndex.value, 222) // console.log(activeIndex.value, 222)
clearInterval(timer.value) clearInterval(timer.value)
reportDisabled.value = false; reportDisabled.value = false;
console.log(activeIndex.value, 333) // console.log(activeIndex.value, 333)
} }
qualified.value = 92 qualified.value = 92
}, 100); }, 100);

View File

@@ -145,7 +145,7 @@ const monitorIdxList = [
}, },
] ]
const handleNodeClick = (data) => { const handleNodeClick = (data) => {
console.log(data); // console.log(data);
}; };
const MonIsShow = ref(false) const MonIsShow = ref(false)
const DevIsShow = ref(false) const DevIsShow = ref(false)

View File

@@ -194,7 +194,7 @@ const handleNodeClick = async (data: any) => {
}; };
watch(() => formContent.chnNum, async (newVal, oldVal) => { watch(() => formContent.chnNum, async (newVal, oldVal) => {
console.log("通道号", newVal); // console.log("通道号", newVal);
if (newVal) { if (newVal) {
// 发起请求,查询该测试项的检测结果 // 发起请求,查询该测试项的检测结果
@@ -217,7 +217,7 @@ watch(() => formContent.chnNum, async (newVal, oldVal) => {
}) })
watch(currentHarmNum, (newVal, oldVal) => { watch(currentHarmNum, (newVal, oldVal) => {
console.log("谐波次数", newVal); // console.log("谐波次数", newVal);
if (newVal !== '-1') { if (newVal !== '-1') {
let resCheckResult: CheckData.ResCheckResult = resTableData.resultData.get(newVal.toString()) let resCheckResult: CheckData.ResCheckResult = resTableData.resultData.get(newVal.toString())
setCheckResultData(resCheckResult) setCheckResultData(resCheckResult)
@@ -233,7 +233,7 @@ watch(currentHarmNum, (newVal, oldVal) => {
}) })
watch(currentCheckItem, (newVal, oldVal) => { watch(currentCheckItem, (newVal, oldVal) => {
console.log("当前检测项", newVal); // console.log("当前检测项", newVal);
if (newVal) { if (newVal) {
let key = newVal.toString() === 'Voltage' ? '电压幅值' : '持续时间' let key = newVal.toString() === 'Voltage' ? '电压幅值' : '持续时间'
let resCheckResult: CheckData.ResCheckResult = resTableData.resultData.get(key) let resCheckResult: CheckData.ResCheckResult = resTableData.resultData.get(key)
@@ -277,9 +277,9 @@ const defaultOperate = () => {
} }
const updateTableData = async () => { const updateTableData = async () => {
console.log("左侧树被选中的叶子节点checkIndex", checkIndex.value); // console.log("左侧树被选中的叶子节点checkIndex", checkIndex.value);
if (checkIndex.value) { if (checkIndex.value) {
console.log("更新表格数据"); // console.log("更新表格数据");
// 发起请求,查询该测试项的检测结果 // 发起请求,查询该测试项的检测结果
const {data} = await getTableData({ const {data} = await getTableData({
scriptType, scriptType,
@@ -415,7 +415,7 @@ const close = () => {
}; };
const setCheckResultData = (data: CheckData.ResCheckResult) => { const setCheckResultData = (data: CheckData.ResCheckResult) => {
console.log("检测结果", data); // console.log("检测结果", data);
let result: CheckData.CheckResult[] = [] let result: CheckData.CheckResult[] = []
if (data.dataA != null && data.dataB != null && data.dataC != null) { if (data.dataA != null && data.dataB != null && data.dataC != null) {
result.push({ result.push({
@@ -466,7 +466,7 @@ const formatHarmNum = (num: string) => {
} }
const setRawData = (data: CheckData.RawDataItem[]) => { const setRawData = (data: CheckData.RawDataItem[]) => {
console.log("原始数据", data) // console.log("原始数据", data)
data.forEach((item: CheckData.RawDataItem) => { data.forEach((item: CheckData.RawDataItem) => {
item.dataA = item.dataA == null || item.dataA == undefined ? '/' : Number(item.dataA).toFixed(fixed).replace(/-/g, "") item.dataA = item.dataA == null || item.dataA == undefined ? '/' : Number(item.dataA).toFixed(fixed).replace(/-/g, "")
item.dataB = item.dataB == null || item.dataB == undefined ? '/' : Number(item.dataB).toFixed(fixed).replace(/-/g, "") item.dataB = item.dataB == null || item.dataB == undefined ? '/' : Number(item.dataB).toFixed(fixed).replace(/-/g, "")

View File

@@ -17,8 +17,8 @@
<!-- 表格 header 按钮 --> <!-- 表格 header 按钮 -->
<template #tableHeader=""> <template #tableHeader="">
<el-form :model="form" :inline="true"> <el-form :model="form" :inline="true">
<el-form-item label="关键字"> <el-form-item label="关键字" >
<el-input v-model="form.search" placeholder="请输入设备名称" clearable></el-input> <el-input v-model="form.search" placeholder="请输入设备名称" clearable style="width: 150px;"></el-input>
</el-form-item> </el-form-item>
<el-form-item label="检测状态" v-if="form.activeTabs != 3 && form.activeTabs != 4 && form.activeTabs != 5"> <el-form-item label="检测状态" v-if="form.activeTabs != 3 && form.activeTabs != 4 && form.activeTabs != 5">
<el-select v-model="form.checkStatus" clearable> <el-select v-model="form.checkStatus" clearable>
@@ -59,9 +59,9 @@
<el-button type="primary" :icon="Search" @click="handleSearch" <el-button type="primary" :icon="Search" @click="handleSearch"
>查询</el-button >查询</el-button
> >
<el-button :icon="Delete" @click="handleRefresh" <!-- <el-button :icon="Delete" @click="handleRefresh"
>重置</el-button >重置</el-button
> > -->
<!-- :disabled='!scope.isSelected' --> <!-- :disabled='!scope.isSelected' -->
<el-button <el-button
type="primary" type="primary"
@@ -160,7 +160,7 @@
:icon="Notebook" :icon="Notebook"
@click="openDrawer('归档', scope.row)" @click="openDrawer('归档', scope.row)"
v-if="form.activeTabs === 4" v-if="form.activeTabs === 4"
:disabled = "scope.row.checkState != 2" :disabled = "scope.row.reportState != 1"
>归档</el-button> >归档</el-button>
<el-button <el-button
@@ -471,7 +471,6 @@ const columns = reactive<ColumnProps<Device.ResPqDev>[]>([
render: (scope) => { render: (scope) => {
// 查找设备类型名称 // 查找设备类型名称
const name = devTypeOptions.value.find(option => option.id === scope.row.devType); const name = devTypeOptions.value.find(option => option.id === scope.row.devType);
console.log('表格')
return <span>{name?.name}</span> return <span>{name?.name}</span>
}, },
}, },
@@ -1028,7 +1027,6 @@ const openDrawer = async (title: string, row: any) => {
if(title === '生成') if(title === '生成')
{ {
await useDownload(downloadDevData,'调试报告'+formatDate(new Date()), {planId:checkStore.planId,devId:row.id}, false,'.docx') await useDownload(downloadDevData,'调试报告'+formatDate(new Date()), {planId:checkStore.planId,devId:row.id}, false,'.docx')
emit('batchGenerateClicked'); // 触发事件 emit('batchGenerateClicked'); // 触发事件
} }
@@ -1045,7 +1043,6 @@ const openDrawer = async (title: string, row: any) => {
if (title === '归档') if (title === '归档')
{ {
await documentedPqDev([row.id]) await documentedPqDev([row.id])
emit('batchGenerateClicked'); // 触发事件 emit('batchGenerateClicked'); // 触发事件
// const loading = ElLoading.service({ // const loading = ElLoading.service({

View File

@@ -452,7 +452,7 @@ onUnmounted(() => {
}) })
const handleBatchGenerate = () => { const handleBatchGenerate = () => {
console.log('批量生成按钮被点击了'); // console.log('批量生成按钮被点击了');
// 在这里添加其他逻辑,比如显示对话框、更新状态等 // 在这里添加其他逻辑,比如显示对话框、更新状态等
getPieData(currentId.value) getPieData(currentId.value)

View File

@@ -428,8 +428,10 @@ const handleDevTypeChange = (value: string) => {
const handleInput = (value: string) => { const handleInput = (value: string) => {
// 在这里处理选中事件的逻辑 // 在这里处理选中事件的逻辑
formContent.value.name = value if(scene.value === '1'){
formContent.value.name = value
}
} }