carcheck
This commit is contained in:
		
							parent
							
								
									61628b2294
								
							
						
					
					
						commit
						449bbb0672
					
				| @ -4,13 +4,13 @@ | ||||
|       { | ||||
|         "name": "default", | ||||
|         "material": { | ||||
|           "certpath": "C:\\Users\\93218\\.ohos\\config\\openharmony\\auto_ohos_default_subject-two_com.oh.dts.cer", | ||||
|           "storePassword": "0000001B506B2A36F5061652E84DA29003CACEDDCE520572D4070878BE43BB261D6E415822EE2CC5E29829", | ||||
|           "certpath": "C:\\Users\\13440\\.ohos\\config\\openharmony\\auto_ohos_default_subject-two_com.oh.dts.cer", | ||||
|           "storePassword": "0000001BE410627DD52C5C73834D78AC4BADFF2D9D79998A989A7BF29D1B371B1FAF53A7CEF428EBA50327", | ||||
|           "keyAlias": "debugKey", | ||||
|           "keyPassword": "0000001BDEE0EE8B2C50BC5AAA8DD074192F3E77D412A6D72EAF123FFEF0867B12BDE41DD4DE67A9D51775", | ||||
|           "profile": "C:\\Users\\93218\\.ohos\\config\\openharmony\\auto_ohos_default_subject-two_com.oh.dts.p7b", | ||||
|           "keyPassword": "0000001B596816B48544B690EFFF90D7C662F374F02FC0D5AF0CA2CDC10012DD6D1009FDF9135896C5E106", | ||||
|           "profile": "C:\\Users\\13440\\.ohos\\config\\openharmony\\auto_ohos_default_subject-two_com.oh.dts.p7b", | ||||
|           "signAlg": "SHA256withECDSA", | ||||
|           "storeFile": "C:\\Users\\93218\\.ohos\\config\\openharmony\\auto_ohos_default_subject-two_com.oh.dts.p12" | ||||
|           "storeFile": "C:\\Users\\13440\\.ohos\\config\\openharmony\\auto_ohos_default_subject-two_com.oh.dts.p12" | ||||
|         } | ||||
|       } | ||||
|     ], | ||||
|  | ||||
| @ -107,8 +107,8 @@ export const WarnFlagTipData = { | ||||
|   9: ['dianhuoVideo.wav', 'xihuoVideo.wav'], | ||||
|   10: ['check31.wav'], | ||||
|   11: ['check30.wav'], | ||||
|   12: ['check28.wav'], | ||||
|   13: ['check29.wav'], | ||||
|   12: ['check29.wav'], | ||||
|   13: ['check28.wav'], | ||||
|   14: ['check11.wav'], | ||||
|   15: ['check12.wav'], | ||||
|   16: ['check13.wav'], | ||||
| @ -136,8 +136,8 @@ export const RealNumData = { | ||||
|   8: 18, | ||||
|   9: 5, | ||||
|   10: 29, | ||||
|   11: 30, | ||||
|   12: 31, | ||||
|   11: 31, | ||||
|   12: 30, | ||||
|   13: 32, | ||||
|   14: 28, | ||||
|   15: 28, | ||||
|  | ||||
| @ -5,6 +5,9 @@ import TopLogo from './compontents/TopLogo'; | ||||
| import testNapi from '@ohos.hiserialsdk'; | ||||
| import { dateFormat } from '../common/utils/tools'; | ||||
| import { DwMapData, PassData, RealNumData, StackValueData, WarnFlagData, WarnFlagTipData } from '../mock'; | ||||
| import FileUtil from '../common/utils/File'; | ||||
| import { GlobalConfig } from '../config'; | ||||
| import common from '@ohos.app.ability.common'; | ||||
| 
 | ||||
| @Entry | ||||
| @Component | ||||
| @ -37,6 +40,7 @@ export default struct Index { | ||||
|   @State stopFlag: boolean = false | ||||
|   @State fromIndex: boolean = false | ||||
|   private vocObj = null; | ||||
|   private context = getContext(this) as common.UIAbilityContext; | ||||
| 
 | ||||
|   // private AccountTable = new AccountTable(()=>{},CommonConstants); | ||||
|   aboutToAppear() { | ||||
| @ -114,39 +118,11 @@ export default struct Index { | ||||
|   } | ||||
| 
 | ||||
|   // | ||||
|   carConfigurationInfoFn() { | ||||
|     // const fileUtil = new FileUtil(context) | ||||
|     // const data = await fileUtil.readFile(GlobalConfig.comoonfileWriteAddress + '/config/deviceNo.txt'); | ||||
|     // if (data === '' || data === undefined) { | ||||
|     //   promptAction.showToast({ | ||||
|     //     message: `请先进行设备注册`, | ||||
|     //     duration: 3000 | ||||
|     //   }); | ||||
|     //   globalThis.type='1' | ||||
|     //   globalThis.title=decodeURIComponent('请先进行设备注册') | ||||
|     //   globalThis.errorDialog.open() | ||||
|     //   resolve('') | ||||
|     // } else { | ||||
|     //   const fileData=JSON.parse(data) | ||||
|     //   globalThis.deviceNo = fileData.deviceName | ||||
|     //   console.log('globalThis.deviceNo', globalThis.deviceNo) | ||||
|     //   // getCarInfo() | ||||
|     //   resolve(fileData.deviceName) | ||||
|     // } | ||||
|     if (globalThis.singlePlay) { | ||||
|       const str = "1:5;2:5;3:5;4:5;5:5;6:5;7:5;8:5;9:5;10:5;11:5;12:5;13:5;14:5;15:5;16:5;17:5;18:5;19:5;20:5;21:5;22:2;23:5;24:5" | ||||
|       const data = str.split(';') | ||||
|       this.checkList = [] | ||||
|       const list = data | ||||
|       list.map(res => { | ||||
|         const arr = res.split(':') | ||||
|         this.checkList.push({ | ||||
|           'key': parseInt(arr[0]) + 2, 'time': arr[1] | ||||
|         }) | ||||
|       }) | ||||
|       this.checkListCopy = JSON.parse(JSON.stringify(this.checkList)) | ||||
|       return | ||||
|     } | ||||
|   async carConfigurationInfoFn() { | ||||
|     const fileUtil = new FileUtil(this.context) | ||||
|     const checkListStr = await fileUtil.readFile(GlobalConfig.comoonfileWriteAddress + '/config/carcheck.txt'); | ||||
| 
 | ||||
|     if (checkListStr === '' || checkListStr === undefined) { | ||||
|       //模拟真实数据 | ||||
|       const param = { | ||||
|         "body": | ||||
| @ -157,6 +133,10 @@ export default struct Index { | ||||
|       } | ||||
| 
 | ||||
|       carConfigurationInfo(param).then(res => { | ||||
|         // @ts-ignore | ||||
|         console.log('ES_CHECK_CAR_ITEM',JSON.stringify(res.body)) | ||||
|         // @ts-ignore | ||||
|         if(res?.body?.ES_CHECK_CAR_ITEM){ | ||||
|           // @ts-ignore | ||||
|           const data = res.body.ES_CHECK_CAR_ITEM[0].ITEMS.split(';'); | ||||
|           this.checkList = [] | ||||
| @ -168,9 +148,48 @@ export default struct Index { | ||||
|             }) | ||||
|           }) | ||||
|           this.checkListCopy = JSON.parse(JSON.stringify(this.checkList)) | ||||
|         }else{ | ||||
|           const str = "1:5;2:5;3:5;4:5;5:5;6:5;7:5;8:5;9:5;10:5;11:5;12:5;13:5;14:5;15:5;16:5;17:5;18:5;19:5;20:5;21:5;22:2;23:5;24:5" | ||||
|           const data = str.split(';') | ||||
|           this.checkList = [] | ||||
|           const list = data | ||||
|           list.map(res => { | ||||
|             const arr = res.split(':') | ||||
|             this.checkList.push({ | ||||
|               'key': parseInt(arr[0]) + 2, 'time': arr[1] | ||||
|             }) | ||||
|           }) | ||||
|           this.checkListCopy = JSON.parse(JSON.stringify(this.checkList)) | ||||
|         } | ||||
| 
 | ||||
|       }).catch((error) => { | ||||
|         console.log('error12error' + error) | ||||
|         const str = "1:5;2:5;3:5;4:5;5:5;6:5;7:5;8:5;9:5;10:5;11:5;12:5;13:5;14:5;15:5;16:5;17:5;18:5;19:5;20:5;21:5;22:2;23:5;24:5" | ||||
|         const data = str.split(';') | ||||
|         this.checkList = [] | ||||
|         const list = data | ||||
|         list.map(res => { | ||||
|           const arr = res.split(':') | ||||
|           this.checkList.push({ | ||||
|             'key': parseInt(arr[0]) + 2, 'time': arr[1] | ||||
|           }) | ||||
|         }) | ||||
|         this.checkListCopy = JSON.parse(JSON.stringify(this.checkList)) | ||||
|       }) | ||||
|     }else { | ||||
|       const data = checkListStr.split(';') | ||||
|       this.checkList = [] | ||||
|       const list = data | ||||
|       list.map(res => { | ||||
|         const arr = res.split(':') | ||||
|         this.checkList.push({ | ||||
|           'key': parseInt(arr[0]) + 2, 'time': arr[1] | ||||
|         }) | ||||
|       }) | ||||
|       this.checkListCopy = JSON.parse(JSON.stringify(this.checkList)) | ||||
|       return | ||||
|     } | ||||
| 
 | ||||
|   } | ||||
| 
 | ||||
|   async kszj() { | ||||
| @ -224,8 +243,10 @@ export default struct Index { | ||||
|           this.warnFlag[26] = '2' | ||||
|         } | ||||
|       } | ||||
| 
 | ||||
|       console.log('msgmsgmsg',msg) | ||||
|       if (that.index == 10 || that.index == 11 || that.index == 12 || that.index == 13) { | ||||
|         console.log('msgmsgmsg000',that.index,that.signArr[that.realNum[that.index]]) | ||||
| 
 | ||||
|         if (that.signArr[that.realNum[that.index]] != '1200') { | ||||
|           that.warnFlag[that.index] = '2' | ||||
|         } else { | ||||
| @ -456,14 +477,14 @@ export default struct Index { | ||||
|             } | ||||
| 
 | ||||
|             Row() { | ||||
|               Image(this.warnFlag[12] == '1' ? $r('app.media.zh_r') : this.warnFlag[12] == '2' ? $r('app.media.zh') : '') | ||||
|                 .width(103 * this.ratio) | ||||
|                 .height(118.5 * this.ratio) | ||||
|                 .visibility(this.passArray[12] ? Visibility.Visible : Visibility.Hidden) | ||||
|               Image(this.warnFlag[13] == '1' ? $r('app.media.yh_r') : this.warnFlag[13] == '2' ? $r('app.media.yh') : '') | ||||
|               Image(this.warnFlag[13] == '1' ? $r('app.media.zh_r') : this.warnFlag[13] == '2' ? $r('app.media.zh') : '') | ||||
|                 .width(103 * this.ratio) | ||||
|                 .height(118.5 * this.ratio) | ||||
|                 .visibility(this.passArray[13] ? Visibility.Visible : Visibility.Hidden) | ||||
|               Image(this.warnFlag[12] == '1' ? $r('app.media.yh_r') : this.warnFlag[12] == '2' ? $r('app.media.yh') : '') | ||||
|                 .width(103 * this.ratio) | ||||
|                 .height(118.5 * this.ratio) | ||||
|                 .visibility(this.passArray[12] ? Visibility.Visible : Visibility.Hidden) | ||||
|             } | ||||
|           } | ||||
|           .backgroundImage($r('app.media.rc')) | ||||
|  | ||||
| @ -1,7 +1,7 @@ | ||||
| //考试回放开关
 | ||||
| export const judgeConfig = { | ||||
|   //本地目录开关
 | ||||
|   isTrajectoryOpen: false, | ||||
|   isTrajectoryOpen: true, | ||||
|   //是否开启拍照
 | ||||
|   isPhotoOpen: true, | ||||
|   //扣分语音是否强制开启
 | ||||
| @ -15,7 +15,7 @@ export const judgeConfig = { | ||||
|   // 本地模型地址
 | ||||
|   modelPath: 'models/model_enc', | ||||
|   // 济南科目三
 | ||||
|   trajectoryPath: 'logs/2024_12_26/2024_12_26_14_12_51_2412505941910_370125200404041910_赵宇/judge_exam_data.txt', | ||||
|   trajectoryPath: 'logs/2024_10_12/2024_10_12_11_50_10_9999427676823_744299437502336256_隋统/judge_exam_data.txt', | ||||
|   //四合一画面配置
 | ||||
|   fourInOneScreen:{ | ||||
|     //gps位数
 | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user