This commit is contained in:
lvyuankang 2024-12-05 13:51:36 +08:00
parent 56f6a671eb
commit cd245ac226
9 changed files with 31 additions and 22 deletions

View File

@ -99,6 +99,7 @@ function isSevenDaysAgo(date,saveDays?) {
}
export async function setVideoParam() {
return
const fileUtil = new FileUtil(context)
console.log('configconfig',)
try{

View File

@ -9,8 +9,6 @@ import FileUtil from '../../common/utils/File'
//获取设备信息
export async function getDeviceInfo(context) {
globalThis.deviceNo = 'MAC-53EB31E0'
return 'MAC-53EB31E0'
return new Promise(async (resolve, reject) => {
const fileUtil = new FileUtil(context)
const data = await fileUtil.readFile(GlobalConfig.comoonfileWriteAddress + '/config/deviceNo.txt');

View File

@ -32,6 +32,10 @@ export const GlobalConfig={
ly:{
km2:['2022.06.29.01','2022.12.18.1'],
km3:['2022.08.13.01','2022.12.05.1'],
}
},
sz:{
km2:['2024.08.21.01','2024.08.24.1'],
km3:[],
},
}
}

View File

@ -30,8 +30,8 @@ export default class EntryAbility extends UIAbility {
globalThis.deviceNo = '';
globalThis.hasAuth = false
globalThis.version = GlobalConfig.version.jn.km3[0];
globalThis.judgeVersion = GlobalConfig.version.jn.km3[1];
globalThis.version = GlobalConfig.version.sz.km2[0];
globalThis.judgeVersion = GlobalConfig.version.sz.km2[1];
globalThis.videoVersion= '1.0'

View File

@ -114,6 +114,9 @@ export default struct Index {
}, router.RouterMode.Single);
console.log('res11', JSON.stringify(res))
globalThis.ksyxm=res.examinerLoginRsp.body.ksyxm
globalThis.kgxm=res.examinerLoginRsp.body.name
globalThis.username = this.inputTextArr[0]
}).catch(err=>{
console.log('jiangsong12',JSON.stringify(err))

View File

@ -419,7 +419,7 @@ struct Index {
this.context.resourceManager.getRawFileContent("welcome.wav").then(value => {
this.vocObj.playAudio({
type: 1,
name: '111.mp3'
name: 'welcome.wav'
})
// let rawFile = value;
}).catch(error => {

View File

@ -180,6 +180,8 @@ struct UserInfo {
if (this.dataList.length) {
setTimeout(()=>{
this.currentUser = this.dataList[0]
this.currentUser.ksy2= globalThis.ksyxm
globalThis.lsh=this.currentUser.lsh
},200)
} else {
@ -251,6 +253,8 @@ struct UserInfo {
if (res.sfzmhm == id) {
flag = true
this.currentUser = res
this.currentUser.ksy2= globalThis.ksyxm
this.lsh = this.currentUser.lsh
globalThis.lsh = this.currentUser.lsh
globalThis.ksyh = this.currentUser.ksy1sfzmhm
@ -280,6 +284,8 @@ struct UserInfo {
await upDateTableByArray('USER', [])
setTimeout(()=>{
this.currentUser = this.list[0]
this.currentUser.ksy2= globalThis.ksyxm
globalThis.lsh = this.currentUser.lsh
},200)
@ -364,6 +370,8 @@ struct UserInfo {
this.pageIndex = 0
this.dataList = this.list.slice(this.pageIndex * 4, this.pageIndex * 4 + 4)
this.currentUser = this.dataList[0]
this.currentUser.ksy2= globalThis.ksyxm
this.lsh = this.currentUser.lsh
globalThis.ksyh = this.currentUser.ksy1sfzmhm
globalThis.lsh = this.lsh
@ -608,6 +616,7 @@ struct UserInfo {
if (this.dataList.length) {
setTimeout(()=>{
this.currentUser = this.dataList[0]
this.currentUser.ksy2= globalThis.ksyxm
globalThis.lsh=this.currentUser.lsh
},200)
// this.currentUser = this.dataList[0]
@ -1013,6 +1022,8 @@ struct UserInfo {
globalThis.lsh = item.lsh;
setTimeout(()=>{
this.currentUser = item
this.currentUser.ksy2= globalThis.ksyxm
},200)
})

View File

@ -411,11 +411,13 @@ export default struct SignDisplayCom {
for (let i = 34; i <= 46; i++) {
this.sjxhColum[i].value = this.signArr[i+2]
}
let t = 0
for (let i = 83; i <= 97; i++) {
this.GPSColum[t].value = ((Number((this.signArr[97]||0))*1.852).toFixed(2)).toString()
t++
}
// let t = 0
// for (let i = 83; i <= 97; i++) {
// if(t==14){
// }
// t++
// }
this.GPSColum[14].value = ((Number((this.signArr[97]||0))*1.852).toFixed(2)).toString()
this.sjxhColum = JSON.parse(JSON.stringify((this.sjxhColum)))
that.signArr = JSON.parse(JSON.stringify((this.signArr)))
that.GPSColum = JSON.parse(JSON.stringify((this.GPSColum)))

View File

@ -78,17 +78,7 @@ export default class FileLog {
// 过程评判日志调数据
public setExamJudgeLogData = async (str:string) => {
const {fileUtil,folderPath} = this;
await fileUtil.editFile(`${folderPath}/judge_log_data.txt`,str);
// 设置四合一画面数据
public setFourAndOneLogData = async (str:string) => {
const {fileUtil,folderPath} = this;
await fileUtil.editFile(`${folderPath}/four_one_log_data.txt`,str);
}
public setFourAndOneLogDataBytes = async (str:string) => {
const {fileUtil,folderPath} = this;
await fileUtil.editFile(`${folderPath}/four_one_log_byte_data.txt`,str);
await fileUtil.editFile(`${folderPath}/judge_log_data.txt`, str);
}
// 设置四合一画面数据