fix: 修复信号未能正确显示,以及当前项目无法正确显示问题

This commit is contained in:
wangzhongjie 2025-07-24 10:20:54 +08:00
parent e22def4691
commit 95a6ddec29
3 changed files with 17 additions and 13 deletions

View File

@ -691,9 +691,13 @@ struct JudgePage {
Column() { Column() {
// 顶部 // 顶部
HeaderComponent({ HeaderComponent({
logoExpansionBuilder: this.logoExpansionBuilder, logoExpansionBuilder: () => {
this.logoExpansionBuilder()
},
customizeReturnArea: true, customizeReturnArea: true,
backAreaBuilder: this.backAreaBuilder backAreaBuilder: () => {
this.backAreaBuilder()
}
}) })
Row() { Row() {
Row() { Row() {

View File

@ -1,6 +1,7 @@
import SignalDisplayComponent from './compontents/SignalDisplay'; import SignalDisplayComponent from './compontents/SignalDisplay';
import router from '@ohos.router'; import router from '@ohos.router';
import TabComponent from './compontents/Tab'; import TabComponent from './compontents/Tab';
import { InitialPerLane } from '../mock';
@Entry @Entry
@Component @Component
@ -41,7 +42,8 @@ struct SignDisplayPage {
}.width("100%").height(100) }.width("100%").height(100)
SignalDisplayComponent({ SignalDisplayComponent({
active: this.active active: this.active,
laneSignal: InitialPerLane
}) })
} }
.width('100%') .width('100%')

View File

@ -285,14 +285,14 @@ export default class Judge {
if (stachArr[0] != '#DN_GD' || this.isUdpEnd) { if (stachArr[0] != '#DN_GD' || this.isUdpEnd) {
return return
} }
if (msg[336]) { const gpsPart = msg.split("#END$GPS,")[1];
if (msg[336] === "4") { const gpsStatus = gpsPart.split(",")[0];
dConsole.log(JudgeTag, "差分状态正常") if (gpsStatus === "4") {
this.judgeUI.isDwztRight = true dConsole.log(JudgeTag, "差分状态正常", gpsStatus)
} else { this.judgeUI.isDwztRight = true
dConsole.log(JudgeTag, "差分状态异常") } else {
this.judgeUI.isDwztRight = false dConsole.log(JudgeTag, "差分状态异常", gpsStatus)
} this.judgeUI.isDwztRight = false
} }
this.judgeUI.isDwztRight this.judgeUI.isDwztRight
const plcData = await this.getPlcData(msg); const plcData = await this.getPlcData(msg);
@ -1850,7 +1850,6 @@ export default class Judge {
} }
} }
//开始评判 //开始评判
private async judging(callBack: Function) { private async judging(callBack: Function) {
const judgeUI = this.judgeUI; const judgeUI = this.judgeUI;
@ -1862,7 +1861,6 @@ export default class Judge {
const manualMarkRules = judgeUI.manualMarkRules const manualMarkRules = judgeUI.manualMarkRules
const getJudgeBeginData = this.getJudgeBeginData; const getJudgeBeginData = this.getJudgeBeginData;
const handDistance = this.getJudgeBeginData; const handDistance = this.getJudgeBeginData;
const handleTrajectoryUdp = this.handleTrajectoryUdp; const handleTrajectoryUdp = this.handleTrajectoryUdp;