满分学习优化
This commit is contained in:
parent
010f5fb5da
commit
92cb6838d2
@ -24,12 +24,11 @@ import {
|
||||
SYSTEMPARMARR
|
||||
} from './judgeSDK/api/judgeSDK.d';
|
||||
|
||||
import { chunkArr, formatTime, getCurrentHourTime, getCurrentTime } from '../common/utils/tools';
|
||||
import { formatTime, getCurrentHourTime, getCurrentTime } from '../common/utils/tools';
|
||||
import { getSyncData } from '../common/service/initable';
|
||||
import { judgeConfig } from './judgeSDK/utils/judgeConfig';
|
||||
import FileUtil from '../common/utils/File';
|
||||
import SignDisplayCom from './compontents/signDisplayCom';
|
||||
import systemDateTime from '@ohos.systemDateTime';
|
||||
|
||||
|
||||
@Entry
|
||||
@ -37,7 +36,6 @@ import systemDateTime from '@ohos.systemDateTime';
|
||||
struct Index {
|
||||
// 考试模式 1:白考,2:夜考,3:增驾(模拟灯光未考),4:增驾(模拟灯光已考),5:满分学习
|
||||
private mode: number = 1
|
||||
private mfxxn: boolean = false
|
||||
|
||||
async aboutToDisappear() {
|
||||
clearInterval(this.mileageTimer)
|
||||
@ -247,7 +245,7 @@ struct Index {
|
||||
const systemParms: SYSTEMPARMARR[] = sysParam || (await getSyncData('MA_SYSTEMPARM')) as SYSTEMPARMARR[]
|
||||
|
||||
let currentParams: any = router.getParams();
|
||||
const {carName,carType,examSubject} = this;
|
||||
const {carName} = this;
|
||||
if (this.mode === 2) {
|
||||
this.totalScore = Number(currentParams.score) || this.totalScore
|
||||
}
|
||||
@ -294,24 +292,23 @@ struct Index {
|
||||
this.examMileage = mileage[0]
|
||||
}
|
||||
}
|
||||
// 满分学习里程
|
||||
if (this.mode === 5 && no1 == 3 && no2 == Number(carNo) && no3 == 63) {
|
||||
let data = decodeURI(systemParm.txt1)?.split("^")
|
||||
this.examMileage = data[1] || this.examMileage
|
||||
// 满分学习扣分
|
||||
this.mfxxn = data[3] != "1"
|
||||
}
|
||||
//获取当前考车的考试项目
|
||||
if (this.mode === 2 && no1 == 3 && no2 == Number(carNo) && no3 == 46) {
|
||||
// 夜考必考项目读取
|
||||
allItems = decodeURIComponent(systemParm.txt1).split(',').filter(txt => txt !== '')
|
||||
} else if (this.mode !== 2 && no1 == 3 && no2 == Number(carNo) && no3 == 10) {
|
||||
// 其他模式必考项目获取
|
||||
allItems = decodeURIComponent(systemParm.txt1).split(',').filter(txt => txt !== '')
|
||||
} else if (this.mode == 5 && no1 == 3 && no2 == Number(carNo) && no3 == 63) {
|
||||
// 满分学习项目
|
||||
let data = decodeURI(systemParm.txt1)?.split("^").filter(item => item)
|
||||
allItems = data[2]?.split(",") || []
|
||||
allItems = data[0]?.split(",") || []
|
||||
}
|
||||
|
||||
if (no1 == 6) {
|
||||
const name = decodeURI(systemParm.txt1)
|
||||
// 夜间行驶
|
||||
@ -368,7 +365,6 @@ struct Index {
|
||||
this.ddxkKsxmArr.push(txt2)
|
||||
}
|
||||
}
|
||||
|
||||
this.systemparmArr.push({
|
||||
'NO1': no1 * 1,
|
||||
'NO2': no2 * 1,
|
||||
|
||||
@ -801,8 +801,7 @@ export default class Judge {
|
||||
dmndg: judgeUI.mode === 3 || judgeUI.mode === 5,
|
||||
// 是否满分学习
|
||||
mfxx: judgeUI.mode === 5,
|
||||
// TODO 满分学习是否扣分参数
|
||||
mfxxn: judgeUI.mfxxn,
|
||||
// 是否增驾
|
||||
zeng: judgeUI.mode === 3 || judgeUI.mode === 4
|
||||
}
|
||||
console.info(judgeTag, '5.获取开始考试数据完成')
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user