This commit is contained in:
caozehui
2025-09-29 14:49:29 +08:00
parent a4a64ef0f9
commit 7c0ec5844a
2 changed files with 170 additions and 196 deletions

View File

@@ -226,184 +226,161 @@ watch(webMsgSend, function (newValue, oldValue) {
}
switch (newValue.requestId) {
case 'yjc_sbtxjy':
switch (newValue.operateCode) {
case 'INIT_GATHER$02':
if (newValue.code == 10200) {
step1InitLog.value.push({
type: 'info',
log: newValue.data,
})
} else if (newValue.code == 10201) {
step1.value = 'process'
step1InitLog.value = [{
type: 'wait',
log: '正在进行设备通讯校验.....',
}];
} else if (newValue.code == 10551) {
step1InitLog.value.push({
type: 'error',
log: newValue.data + '设备触发报告异常!',
})
step1.value = 'error'
ts.value = 'error'
step5.value = 'error'
} else if (newValue.code == 10552) {
step1InitLog.value = [{
type: 'error',
log: '存在已经初始化步骤,执行自动关闭,请重新发起检测!',
}];
step1.value = 'error'
ts.value = 'error'
step5.value = 'error'
} else if (newValue.code == 25001) {
activeIndex.value = 1
step1.value = 'success'
step2.value = 'process'
}
break;
case 'INIT_GATHER$03':
if (newValue.code == 10200) {
step1InitLog.value.push({
type: 'info',
log: newValue.data,
})
}else if (newValue.code == 25001) {
step1InitLog.value.push({
type: 'info',
log: newValue.data,
})
activeIndex.value = 1
step1.value = 'success'
step2.value = 'process'
}
break;
case 'DATA_REQUEST$03':
if (newValue.code == 25001) {
activeIndex.value = 1
step1.value = 'success'
step2.value = 'process'
}
break;
if (newValue.code == 10200) {
step1InitLog.value.push({
type: 'info',
log: newValue.data,
})
}
if (newValue.code == 10201) {
step1.value = 'process'
step1InitLog.value = [{
type: 'wait',
log: '正在进行设备通讯校验.....',
}];
}
if (newValue.code == 10551) {
step1InitLog.value.push({
type: 'error',
log: newValue.data + '设备触发报告异常!',
})
step1.value = 'error'
ts.value = 'error'
step5.value = 'error'
}
if (newValue.code == 10552) {
step1InitLog.value = [{
type: 'error',
log: '存在已经初始化步骤,执行自动关闭,请重新发起检测!',
}];
step1.value = 'error'
ts.value = 'error'
step5.value = 'error'
}
if (newValue.code == 25001) {
step1InitLog.value.push({
type: 'info',
log: newValue.data,
})
activeIndex.value = 1
step1.value = 'success'
step2.value = 'process'
}
break;
case 'record_wave_step1':
switch (newValue.operateCode) {
case 'DATA_REQUEST$03':
if (newValue.code == 25002) { //某一路录波校验失败
step1InitLog.value.push({
type: 'error',
log: newValue.data ,
})
}else if (newValue.code == 25003) { //最终失败
step1.value = 'error'
ts.value = 'error'
step5.value = 'error'
}
if (newValue.code == 25002) { //某一路录波校验失败
step1InitLog.value.push({
type: 'error',
log: newValue.data,
})
} else if (newValue.code == 25003) { //最终失败
step1.value = 'error'
ts.value = 'error'
step5.value = 'error'
}
break;
case 'yjc_mxyzxjy':
switch (newValue.operateCode){
case 'DATA_REQUEST$02':
if (newValue.code == 10200) { //单个监测点成功
step2InitLog.value.push({
type: 'info',
log: newValue.data + '模型一致性检验成功!',
})
}else if (newValue.code == 10201) {
step2.value = 'process'
step2InitLog.value = [{
type: 'wait',
log: '正在进行模型一致性校验.....',
}];
} else if (newValue.code == 25002) { //单个监测点失败
step2InitLog.value.push({
type: 'error',
log: newValue.data +'模型一致性检验失败!',
})
}else if (newValue.code == 25001) { //最终成功
step2.value = 'success'
step3.value = 'process'
activeIndex.value = 2
}else if (newValue.code == 25003) { //最终失败
step2.value = 'error'
ts.value = 'error'
step5.value = 'error'
}
break;
if (newValue.code == 10200) { //单个监测点成功
step2InitLog.value.push({
type: 'info',
log: newValue.data + '模型一致性检验成功!',
})
}
break;
if (newValue.code == 10201) {
step2.value = 'process'
step2InitLog.value = [{
type: 'wait',
log: '正在进行模型一致性校验.....',
}];
}
if (newValue.code == 25002) { //单个监测点失败
step2InitLog.value.push({
type: 'error',
log: newValue.data + '模型一致性检验失败!',
})
}
if (newValue.code == 25001) { //最终成功
step2.value = 'success'
step3.value = 'process'
activeIndex.value = 2
}
if (newValue.code == 25003) { //最终失败
step2.value = 'error'
ts.value = 'error'
step5.value = 'error'
}
break;
case 'yjc_align':
switch (newValue.operateCode){
case 'DATA_REQUEST$02':
if (newValue.code == 10200) { //单个监测点成功
step3InitLog.value.push({
type: 'info',
log: newValue.data +'实时数据对齐检验成功!',
})
}else if (newValue.code == 10201) {
step3.value = 'process'
step3InitLog.value = [{
type: 'wait',
log: '正在进行实时数据对齐检验.....',
}];
}else if (newValue.code == 25002) { //单个监测点失败
step3InitLog.value.push({
type: 'error',
log: newValue.data + '实时数据对齐检验失败!',
})
}else if (newValue.code == 25001 && newValue.data) { //最终成功
isShowDialog.value = true
step3.value = 'success'
step4.value = 'process'
activeIndex.value = 3
testDataStructure.value = newValue.data
}else if (newValue.code == 25003) { //最终失败
isShowDialog.value = true
step3.value = 'error'
ts.value = 'error'
step5.value = 'error'
testDataStructure.value = newValue.data
}
break;
if (newValue.code == 10200) { //单个监测点成功
step3InitLog.value.push({
type: 'info',
log: newValue.data + '数据对齐检验成功!',
})
}
break;
if (newValue.code == 10201) {
step3.value = 'process'
step3InitLog.value = [{
type: 'wait',
log: '正在进行数据对齐检验.....',
}];
}
if (newValue.code == 25002) { //单个监测点失败
step3InitLog.value.push({
type: 'error',
log: newValue.data + '数据对齐检验失败!',
})
}
if (newValue.code == 25001 && newValue.data) { //最终成功
isShowDialog.value = true
step3.value = 'success'
step4.value = 'process'
activeIndex.value = 3
testDataStructure.value = newValue.data
}
if (newValue.code == 25003) { //最终失败
isShowDialog.value = true
step3.value = 'error'
ts.value = 'error'
step5.value = 'error'
testDataStructure.value = newValue.data
}
break;
case 'YJC_xujy':
switch (newValue.operateCode) {
case 'DATA_REQUEST$02':
if (newValue.code == 10200) {
step4InitLog.value.push({
type: 'info',
log: newValue.data,
})
}else if (newValue.code == 10201) {
step4.value = 'process'
step4InitLog.value = [{
type: 'wait',
log: '正在进行相序性检.....',
}];
} else if(newValue.code == 25002){
step4InitLog.value.push({
type: 'error',
log: newValue.data,
})
} else if (newValue.code == 25003) {
step4InitLog.value.push({
type: 'error',
log: newValue.data,
})
step4.value = 'error'
ts.value = 'error'
step5.value = 'error'
} else if (newValue.code == 25001) {
step4.value = 'success'
step5.value = 'success'
ts.value = 'success'
activeIndex.value = 4
}
break
if (newValue.code == 10200) {
step4InitLog.value.push({
type: 'info',
log: newValue.data,
})
}
if (newValue.code == 10201) {
step4.value = 'process'
step4InitLog.value = [{
type: 'wait',
log: '正在进行相序性检.....',
}];
}
if (newValue.code == 25002) {
step4InitLog.value.push({
type: 'error',
log: newValue.data,
})
}
if (newValue.code == 25003) {
step4InitLog.value.push({
type: 'error',
log: newValue.data,
})
step4.value = 'error'
ts.value = 'error'
step5.value = 'error'
}
if (newValue.code == 25001) {
step4.value = 'success'
step5.value = 'success'
ts.value = 'success'
activeIndex.value = 4
}
break;
case 'quit':