Compare commits
No commits in common. "908c57959104ebbc52b695c8aa8c7d8c1e31f3c6" and "7b27578efd66466332361aba77a0b61adc428cf7" have entirely different histories.
908c579591
...
7b27578efd
@ -73,20 +73,6 @@ struct UserInfo {
|
||||
@State FaceOpenStatue: string = '0'; //是否开启人脸识别
|
||||
subscriber;
|
||||
@State faceCatchImg: string = ''
|
||||
// 过程照片拍照
|
||||
getPhoto = async (empty?: boolean) => {
|
||||
const singlePlay = globalThis.singlePlay
|
||||
//单机模式返回空照片
|
||||
if (singlePlay) {
|
||||
return ''
|
||||
} else {
|
||||
const {filePhoto} = this;
|
||||
const photoBase64 = await filePhoto.getPhoto();
|
||||
return photoBase64
|
||||
}
|
||||
}
|
||||
private filePhoto: FilePhoto
|
||||
private avPlayer
|
||||
private AccountTable = new AccountTable(() => {
|
||||
}, USER);
|
||||
private context = getContext(this) as common.UIAbilityContext;
|
||||
@ -359,13 +345,6 @@ struct UserInfo {
|
||||
}
|
||||
this.pageIndex++;
|
||||
this.dataList = this.list.slice(this.pageIndex * 4, this.pageIndex * 4 + 4)
|
||||
this.dataList.forEach(listData => {
|
||||
for (let i in listData) {
|
||||
listData[i] = decodeURI(listData[i])
|
||||
}
|
||||
listData.kszp = this.photo + listData.kszp
|
||||
listData.ksmjzp = this.photo + listData.ksmjzp
|
||||
})
|
||||
}
|
||||
|
||||
prevClick() {
|
||||
@ -374,13 +353,6 @@ struct UserInfo {
|
||||
}
|
||||
this.pageIndex--;
|
||||
this.dataList = this.list.slice(this.pageIndex * 4, this.pageIndex * 4 + 4)
|
||||
this.dataList.forEach(listData => {
|
||||
for (let i in listData) {
|
||||
listData[i] = decodeURI(listData[i])
|
||||
}
|
||||
listData.kszp = this.photo + listData.kszp
|
||||
listData.ksmjzp = this.photo + listData.ksmjzp
|
||||
})
|
||||
}
|
||||
|
||||
//获取下载考生
|
||||
@ -520,7 +492,11 @@ struct UserInfo {
|
||||
return
|
||||
}
|
||||
// }
|
||||
await upDateTableByArray('USER', [this.currentUser])
|
||||
this.AccountTable.query('0', (result) => {
|
||||
if (result.length == 0) {
|
||||
this.isExamStart = true
|
||||
this.AccountTable.insertData(this.currentUser, (id) => {
|
||||
this.AccountTable.query('0', (result) => {
|
||||
globalThis.statue = 4
|
||||
this.stepFlag = false
|
||||
router.pushUrl({
|
||||
@ -532,7 +508,39 @@ struct UserInfo {
|
||||
}
|
||||
}, router.RouterMode.Single);
|
||||
this.stopDeviceById()
|
||||
})
|
||||
})
|
||||
} else {
|
||||
this.AccountTable.updateData(this.currentUser, (id) => {
|
||||
this.AccountTable.query('0', (result) => {
|
||||
this.stepFlag = false
|
||||
router.pushUrl({
|
||||
url:'pages/Judge',
|
||||
params: {
|
||||
examItems: examItems?.getExaminationItemRsp?.body?.ykxx ,
|
||||
sczb:Number(this.isBoardPrePareSetPopupOpen),
|
||||
kfdm:this.sczbkf
|
||||
}
|
||||
}, router.RouterMode.Single);
|
||||
globalThis.statue = 4
|
||||
this.stopDeviceById()
|
||||
})
|
||||
})
|
||||
}
|
||||
})
|
||||
this.stepFlag = false
|
||||
}
|
||||
// 过程照片拍照
|
||||
getPhoto = async (empty?: boolean) => {
|
||||
const singlePlay = globalThis.singlePlay
|
||||
//单机模式返回空照片
|
||||
if (singlePlay) {
|
||||
return ''
|
||||
} else {
|
||||
const {filePhoto} = this;
|
||||
const photoBase64 = await filePhoto.getPhoto();
|
||||
return photoBase64
|
||||
}
|
||||
}
|
||||
|
||||
// 检测车门、熄火信号
|
||||
@ -546,8 +554,7 @@ struct UserInfo {
|
||||
const msgArr = msg.split(',')
|
||||
const mkg = msgArr[14];
|
||||
const fdjzs = msgArr[25];
|
||||
globalThis.udpClient.onMessage_1(() => {
|
||||
});
|
||||
globalThis.udpClient.onMessage_1(()=>{});
|
||||
//TODO
|
||||
console.info('surenjun mkg=>', mkg)
|
||||
console.info('surenjun fdjzs=>', fdjzs)
|
||||
@ -571,7 +578,6 @@ struct UserInfo {
|
||||
})
|
||||
})
|
||||
}
|
||||
|
||||
// 开始考试
|
||||
async beginExam(){
|
||||
const carInfo = globalThis.carInfo;
|
||||
@ -766,7 +772,10 @@ struct UserInfo {
|
||||
if (globalThis.singlePlay) {
|
||||
const {examSubject} = globalThis.carInfo;
|
||||
console.info('surenjun => sczbkf',JSON.stringify(this.sczbkf))
|
||||
await upDateTableByArray('USER', [this.currentUser])
|
||||
this.AccountTable.query('0', (result) => {
|
||||
if (result.length == 0) {
|
||||
this.AccountTable.insertData(this.currentUser, (id) => {
|
||||
this.AccountTable.query('0', (result) => {
|
||||
router.pushUrl({
|
||||
url: examSubject == 3 ? 'pages/Roads':'pages/Judge',
|
||||
params:{
|
||||
@ -775,6 +784,23 @@ struct UserInfo {
|
||||
}
|
||||
}, router.RouterMode.Single);
|
||||
this.stopDeviceById()
|
||||
})
|
||||
})
|
||||
} else {
|
||||
this.AccountTable.updateData(this.currentUser, (id) => {
|
||||
this.AccountTable.query('0', (result) => {
|
||||
router.pushUrl({
|
||||
url: examSubject == 3?'pages/Roads':'pages/Judge',
|
||||
params:{
|
||||
sczb:Number(this.isBoardPrePareSetPopupOpen),
|
||||
kfdm:this.sczbkf
|
||||
}
|
||||
}, router.RouterMode.Single);
|
||||
this.stopDeviceById()
|
||||
})
|
||||
})
|
||||
}
|
||||
})
|
||||
return
|
||||
}
|
||||
if (this.FaceOpenStatue != '0') {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user