Compare commits
	
		
			No commits in common. "7f891b3644fd41a829c067eda911b607e69bbe60" and "f98ce3d83246e371ebac120ec66f7c4d09a3bcba" have entirely different histories.
		
	
	
		
			7f891b3644
			...
			f98ce3d832
		
	
		
@ -128,8 +128,6 @@ export async function getDoubleCeneterTable(param) {
 | 
				
			|||||||
export async function getSingleCenterTable(param) {
 | 
					export async function getSingleCenterTable(param) {
 | 
				
			||||||
  return new Promise((reslove, reject) => {
 | 
					  return new Promise((reslove, reject) => {
 | 
				
			||||||
    upDataZhongxinginitialization(param).then((result) => {
 | 
					    upDataZhongxinginitialization(param).then((result) => {
 | 
				
			||||||
      console.log('teststetfinsh01')
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      if (result) {
 | 
					      if (result) {
 | 
				
			||||||
        reslove(true)
 | 
					        reslove(true)
 | 
				
			||||||
      } else {
 | 
					      } else {
 | 
				
			||||||
 | 
				
			|||||||
@ -85,10 +85,10 @@ function sqlInsertCommonFn(tableName, resultArr, context?, delFlag = true) {
 | 
				
			|||||||
    }, map[tableName], context);
 | 
					    }, map[tableName], context);
 | 
				
			||||||
    accountTable.getRdbStore(() => {
 | 
					    accountTable.getRdbStore(() => {
 | 
				
			||||||
      accountTable.query('0', async (result) => {
 | 
					      accountTable.query('0', async (result) => {
 | 
				
			||||||
        console.log('teststet3',)
 | 
					        console.log('sqlsqlinsertresult',JSON.stringify(result))
 | 
				
			||||||
 | 
					 | 
				
			||||||
        // console.log('表长度',result.length,tableName)
 | 
					        // console.log('表长度',result.length,tableName)
 | 
				
			||||||
        if (result.length == 0) {
 | 
					        if (result.length == 0) {
 | 
				
			||||||
 | 
					          console.log('sqlsqlinsert00000')
 | 
				
			||||||
          let INSERT_SQL = "INSERT INTO " + tableName
 | 
					          let INSERT_SQL = "INSERT INTO " + tableName
 | 
				
			||||||
            + " (" + map[tableName].ACCOUNT_TABLE.columns.toString() + ") VALUES "
 | 
					            + " (" + map[tableName].ACCOUNT_TABLE.columns.toString() + ") VALUES "
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@ -109,10 +109,8 @@ function sqlInsertCommonFn(tableName, resultArr, context?, delFlag = true) {
 | 
				
			|||||||
            }
 | 
					            }
 | 
				
			||||||
            INSERT_SQL += str
 | 
					            INSERT_SQL += str
 | 
				
			||||||
          })
 | 
					          })
 | 
				
			||||||
          console.log('sqlsINSERT_SQLINSERT_SQL', INSERT_SQL)
 | 
					          console.log('sqlsqlinsertINSERT_SQLINSERT_SQL', INSERT_SQL)
 | 
				
			||||||
          accountTable.sqlOperate(INSERT_SQL, tableName, (val) => {
 | 
					          accountTable.sqlOperate(INSERT_SQL, tableName, (val) => {
 | 
				
			||||||
            console.log('teststet3',val,tableName)
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
            console.log('sqlsqlinsert,', val, 'tableName', tableName)
 | 
					            console.log('sqlsqlinsert,', val, 'tableName', tableName)
 | 
				
			||||||
            resolve(val)
 | 
					            resolve(val)
 | 
				
			||||||
          })
 | 
					          })
 | 
				
			||||||
@ -169,8 +167,8 @@ export async function getDataBaseTable(params, reqParam) {
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
//依据数组和表名更新sql表
 | 
					//依据数组和表名更新sql表
 | 
				
			||||||
export async function upDateTableByArray(tableName, arr) {
 | 
					export async function upDateTableByArray(tableName, arr) {
 | 
				
			||||||
  return new Promise(async (reslove, reject) => {
 | 
					  return new Promise(async (reslove,reject)=>{
 | 
				
			||||||
    const data = await sqlInsertCommonFn(tableName, arr)
 | 
					    const data =await sqlInsertCommonFn(tableName, arr)
 | 
				
			||||||
    reslove(data)
 | 
					    reslove(data)
 | 
				
			||||||
  })
 | 
					  })
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
@ -329,26 +327,30 @@ export async function getEsCarModel(context) {
 | 
				
			|||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
export async function upDataZhongxinginitialization(param) {
 | 
					export async function upDataZhongxinginitialization(param) {
 | 
				
			||||||
  return new Promise(async(resolve, reject) => {
 | 
					  return new Promise((resolve, reject) => {
 | 
				
			||||||
    if (!param.carId) {
 | 
					    if (!param.carId) {
 | 
				
			||||||
      resolve(false)
 | 
					      resolve(false)
 | 
				
			||||||
      return
 | 
					      return
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    if (param.singlePlay) {
 | 
					    if(param.singlePlay){
 | 
				
			||||||
      console.log('teststet0')
 | 
					 | 
				
			||||||
      const fileUtil = new FileUtil(param.context)
 | 
					      const fileUtil = new FileUtil(param.context)
 | 
				
			||||||
      const tableList = ['MA_SYSSET', 'MA_SYSTEMPARM', 'MA_MARKRULE', 'MA_MARKRULESET','ES_CARINFO','MA_MAP_ROAD','MA_MAP_ROAD_LANE','MAP_SUBITEM','MA_T_CARPARMSET','MA_MAP_ITEMCLASS','MA_MAP_POINT','MA_MAP_POINT_ITEM'];
 | 
					      const tableList=['MA_ITEMINFO','MA_MARKRULE','MA_SYSTEMPARM','MA_MAP_COLLECT','MA_MAP_COLLECT_SHAPE','MA_MAP_ITEMCLASS','MA_MAP_POINT','MA_MAP_POINT_ITEM','MA_MAP_ROAD','MA_MAP_ROAD_LANE','MAP_SUBITEM','MA_SYSSET','ES_CARINFO','MA_MARKRULESET','MA_CDSBINFO','MA_T_CARPARMSET'];
 | 
				
			||||||
 | 
					      tableList.map(async(tableName)=>{
 | 
				
			||||||
     for(let i=0;i<=tableList.length-1;i++){
 | 
					        const data = await fileUtil.readFile(GlobalConfig.comoonfileWriteAddress + `/config/tableList/${tableName}.txt`);
 | 
				
			||||||
       console.log('teststet1',tableList[i])
 | 
					        if(data&&JSON.parse(data)){
 | 
				
			||||||
       const data = await fileUtil.readFile(GlobalConfig.comoonfileWriteAddress + `/config/tableList/${tableList[i]}.txt`);
 | 
					          sqlInsertCommonFn(tableName, JSON.parse(data), param.context).then((result) => {
 | 
				
			||||||
       console.log('teststet1',data)
 | 
					            console.log(key, '单机表建立成功')
 | 
				
			||||||
 | 
					            if (result) {
 | 
				
			||||||
       await sqlInsertCommonFn(tableList[i], JSON.parse(data) || [], param.context)
 | 
					              resolve(true)
 | 
				
			||||||
       console.log('teststet2',data)
 | 
					            } else {
 | 
				
			||||||
     }
 | 
					              resolve(false)
 | 
				
			||||||
      console.log('teststetfinsh')
 | 
					            }
 | 
				
			||||||
      resolve(true)
 | 
					          }).catch((msg) => {
 | 
				
			||||||
 | 
					            reject(false)
 | 
				
			||||||
 | 
					            console.log(key, '单机表建立失败')
 | 
				
			||||||
 | 
					          })
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					      })
 | 
				
			||||||
      return
 | 
					      return
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    const str = {
 | 
					    const str = {
 | 
				
			||||||
@ -391,7 +393,7 @@ export async function upDataZhongxinginitialization(param) {
 | 
				
			|||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
function setSyncCenterSqlData(key, res, param) {
 | 
					function setSyncCenterSqlData(key, res, param) {
 | 
				
			||||||
  return new Promise(async (resolve, reject) => {
 | 
					  return new Promise(async(resolve, reject) => {
 | 
				
			||||||
    const mapName = {
 | 
					    const mapName = {
 | 
				
			||||||
      'ItemInfo': 'MA_ITEMINFO',
 | 
					      'ItemInfo': 'MA_ITEMINFO',
 | 
				
			||||||
      'MarkRule': 'MA_MARKRULE',
 | 
					      'MarkRule': 'MA_MARKRULE',
 | 
				
			||||||
 | 
				
			|||||||
@ -115,19 +115,9 @@ export default class TcpClient {
 | 
				
			|||||||
          // socketTimeout: 3000,
 | 
					          // socketTimeout: 3000,
 | 
				
			||||||
        }, err => {
 | 
					        }, err => {
 | 
				
			||||||
          if (err) {
 | 
					          if (err) {
 | 
				
			||||||
            console.log('testTagtestTagerrrrr,success')
 | 
					 | 
				
			||||||
            if(this.num>3){
 | 
					 | 
				
			||||||
              return
 | 
					 | 
				
			||||||
            }
 | 
					 | 
				
			||||||
            setTimeout(() => {
 | 
					 | 
				
			||||||
              getTCP()
 | 
					 | 
				
			||||||
              resolve(false)
 | 
					 | 
				
			||||||
            }, 2000)
 | 
					 | 
				
			||||||
            return;
 | 
					            return;
 | 
				
			||||||
          }
 | 
					          }
 | 
				
			||||||
        });
 | 
					        });
 | 
				
			||||||
        console.log('testTagtestTagconnect,success')
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
        globalThis.getCloseTcp = false
 | 
					        globalThis.getCloseTcp = false
 | 
				
			||||||
        resolve(true)
 | 
					        resolve(true)
 | 
				
			||||||
      }).catch(err => {
 | 
					      }).catch(err => {
 | 
				
			||||||
@ -140,7 +130,7 @@ export default class TcpClient {
 | 
				
			|||||||
          getTCP()
 | 
					          getTCP()
 | 
				
			||||||
          resolve(false)
 | 
					          resolve(false)
 | 
				
			||||||
        }, 2000)
 | 
					        }, 2000)
 | 
				
			||||||
        console.log('testTagtestTagconnect,error')
 | 
					        console.log('testTagconnect,error')
 | 
				
			||||||
 | 
					
 | 
				
			||||||
      });
 | 
					      });
 | 
				
			||||||
    })
 | 
					    })
 | 
				
			||||||
@ -162,7 +152,7 @@ export default class TcpClient {
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
  onMessage(callback?) {
 | 
					  onMessage(callback?) {
 | 
				
			||||||
    this.tcp.on('message', value => {
 | 
					    this.tcp.on('message', value => {
 | 
				
			||||||
      console.log(TAG, 'Tcponmessage', value)
 | 
					      console.log(TAG, 'Tcponmessage', value.length, value)
 | 
				
			||||||
      globalThis.tcpUdpError = false
 | 
					      globalThis.tcpUdpError = false
 | 
				
			||||||
 | 
					
 | 
				
			||||||
      // console.log('messageLengt',,value.message.length))
 | 
					      // console.log('messageLengt',,value.message.length))
 | 
				
			||||||
 | 
				
			|||||||
@ -132,9 +132,10 @@ struct Index {
 | 
				
			|||||||
              if (this.loading) {
 | 
					              if (this.loading) {
 | 
				
			||||||
                return
 | 
					                return
 | 
				
			||||||
              }
 | 
					              }
 | 
				
			||||||
              this.testXMLToJSONInWorker()
 | 
					              router.pushUrl({
 | 
				
			||||||
 | 
					                url: 'pages/UserInfo',
 | 
				
			||||||
           ;
 | 
					                params: { judge: true }
 | 
				
			||||||
 | 
					              }, router.RouterMode.Single);
 | 
				
			||||||
            })
 | 
					            })
 | 
				
			||||||
          }
 | 
					          }
 | 
				
			||||||
          Image($r('app.media.index_zj')).width('28%').height('71%').margin({right:80* globalThis.ratio}).onClick(() => {
 | 
					          Image($r('app.media.index_zj')).width('28%').height('71%').margin({right:80* globalThis.ratio}).onClick(() => {
 | 
				
			||||||
@ -284,7 +285,7 @@ struct Index {
 | 
				
			|||||||
      let workData: WorkData = e.data;
 | 
					      let workData: WorkData = e.data;
 | 
				
			||||||
      if (workData.isComplete) {
 | 
					      if (workData.isComplete) {
 | 
				
			||||||
        router.pushUrl({
 | 
					        router.pushUrl({
 | 
				
			||||||
          url: globalThis.singlePlay?'pages/UserInfo':'pages/ExaminerLogin',
 | 
					          url: 'pages/ExaminerLogin',
 | 
				
			||||||
        }, router.RouterMode.Single)
 | 
					        }, router.RouterMode.Single)
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
      this.loading = false
 | 
					      this.loading = false
 | 
				
			||||||
 | 
				
			|||||||
@ -22,7 +22,7 @@ struct Index {
 | 
				
			|||||||
  // @State inputTextList2: string[] = ['192.168.7.124','20022']
 | 
					  // @State inputTextList2: string[] = ['192.168.7.124','20022']
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  // @State inputTextList1: string[] = ['172.37.55.191','18782','192.168.7.1','8082','255.255.255.0','192.168.7.170','114.114.114.114','192.168.7.124','20022','172.37.55.59','20122']
 | 
					  // @State inputTextList1: string[] = ['172.37.55.191','18782','192.168.7.1','8082','255.255.255.0','192.168.7.170','114.114.114.114','192.168.7.124','20022','172.37.55.59','20122']
 | 
				
			||||||
  @State inputTextList1: string[] = ['192.168.1.144','18782','192.168.1.146','8082','255.255.255.0','192.168.7.1','114.114.114.114','192.168.7.124','20022','192.168.7.170','20122']
 | 
					  @State inputTextList1: string[] = ['192.168.1.146','18782','192.168.1.146','8082','255.255.255.0','192.168.7.1','114.114.114.114','192.168.7.124','20022','192.168.7.170','20122']
 | 
				
			||||||
  // @State inputTextList2: string[] = []
 | 
					  // @State inputTextList2: string[] = []
 | 
				
			||||||
  // 112.80.35.83 11052
 | 
					  // 112.80.35.83 11052
 | 
				
			||||||
  // @State inputTextList1: string[] = ['192.168.36.2','8084','192.168.36.200','20122','255.255.255.0','192.168.36.1','','','114.114.114.114','192.168.36.139','8000']
 | 
					  // @State inputTextList1: string[] = ['192.168.36.2','8084','192.168.36.200','20122','255.255.255.0','192.168.36.1','','','114.114.114.114','192.168.36.139','8000']
 | 
				
			||||||
 | 
				
			|||||||
@ -17,15 +17,17 @@ import promptAction from '@ohos.promptAction';
 | 
				
			|||||||
import FilePhoto from './judgeSDK/utils/filePhoto';
 | 
					import FilePhoto from './judgeSDK/utils/filePhoto';
 | 
				
			||||||
import { getSyncData, upDateTableByArray } from '../common/service/initable';
 | 
					import { getSyncData, upDateTableByArray } from '../common/service/initable';
 | 
				
			||||||
import { CandidateData, EmptyCandidateObject } from '../mock/CandidateData';
 | 
					import { CandidateData, EmptyCandidateObject } from '../mock/CandidateData';
 | 
				
			||||||
import BoardPrePareSetPopup from './compontents/judge/BoardPrePareSetPopup';
 | 
					import BoardPrePareSetPopup from './compontents/judge/BoardPrePareSetPopup'
 | 
				
			||||||
import LoadingPopup from './compontents/judge/LoadingPopup';
 | 
					import LoadingPopup from './compontents/judge/LoadingPopup';
 | 
				
			||||||
import VoiceAnnounce from './judgeSDK/utils/voiceAnnouncements';
 | 
					import VoiceAnnounce from './judgeSDK/utils/voiceAnnouncements';
 | 
				
			||||||
 | 
					import { JudgeConfig } from '../config/judge';
 | 
				
			||||||
import { judgeConfig } from './judgeSDK/utils/judgeConfig';
 | 
					import { judgeConfig } from './judgeSDK/utils/judgeConfig';
 | 
				
			||||||
import { initJudgeUdp } from '../common/utils/UdpJudge';
 | 
					import { initJudgeUdp } from '../common/utils/UdpJudge';
 | 
				
			||||||
 | 
					 | 
				
			||||||
@Entry
 | 
					@Entry
 | 
				
			||||||
@Component
 | 
					@Component
 | 
				
			||||||
struct UserInfo {
 | 
					struct UserInfo {
 | 
				
			||||||
 | 
					  private filePhoto: FilePhoto
 | 
				
			||||||
 | 
					  private avPlayer
 | 
				
			||||||
  @State pageIndex: number = 0
 | 
					  @State pageIndex: number = 0
 | 
				
			||||||
  @State ratio: number = 1700 / 960
 | 
					  @State ratio: number = 1700 / 960
 | 
				
			||||||
  @State index: number = 0
 | 
					  @State index: number = 0
 | 
				
			||||||
@ -44,12 +46,9 @@ struct UserInfo {
 | 
				
			|||||||
  @State isBoardPrePareSetPopupOpen: boolean = false
 | 
					  @State isBoardPrePareSetPopupOpen: boolean = false
 | 
				
			||||||
  @State isFirstBoardPrePareSetPopupBtnShow: boolean = false
 | 
					  @State isFirstBoardPrePareSetPopupBtnShow: boolean = false
 | 
				
			||||||
  @State isBoardPrePareSetPopupShow: boolean = false
 | 
					  @State isBoardPrePareSetPopupShow: boolean = false
 | 
				
			||||||
  @State isLoadingPopupVisible: boolean = false;
 | 
					  @State isLoadingPopupVisible:boolean = false;
 | 
				
			||||||
  @State loadingText: string = '正在认证监管信息,请稍后...'
 | 
					  @State loadingText:string = '正在认证监管信息,请稍后...'
 | 
				
			||||||
  @State sczbkf: {
 | 
					  @State sczbkf:{xmdm:number,kfdm:string}[] = []
 | 
				
			||||||
    xmdm: number,
 | 
					 | 
				
			||||||
    kfdm: string
 | 
					 | 
				
			||||||
  }[] = []
 | 
					 | 
				
			||||||
  @State currentUser: User = EmptyCandidateObject
 | 
					  @State currentUser: User = EmptyCandidateObject
 | 
				
			||||||
  @State dataList: Array<User> = []
 | 
					  @State dataList: Array<User> = []
 | 
				
			||||||
  @State list: Array<User> = []
 | 
					  @State list: Array<User> = []
 | 
				
			||||||
@ -62,7 +61,7 @@ struct UserInfo {
 | 
				
			|||||||
  @State idCard: string = '';
 | 
					  @State idCard: string = '';
 | 
				
			||||||
  @State grantDept: string = '';
 | 
					  @State grantDept: string = '';
 | 
				
			||||||
  //是否已经开始考试
 | 
					  //是否已经开始考试
 | 
				
			||||||
  @State isExamStart: boolean = false;
 | 
					  @State isExamStart:boolean = false;
 | 
				
			||||||
  @State effectDate: string = '';
 | 
					  @State effectDate: string = '';
 | 
				
			||||||
  @State interval: any = null;
 | 
					  @State interval: any = null;
 | 
				
			||||||
  @State studentRefreshStatue: string = '0';
 | 
					  @State studentRefreshStatue: string = '0';
 | 
				
			||||||
@ -74,7 +73,7 @@ struct UserInfo {
 | 
				
			|||||||
  @State faceFlag: string = '0';
 | 
					  @State faceFlag: string = '0';
 | 
				
			||||||
  @State FaceOpenStatue: string = '0'; //是否开启人脸识别
 | 
					  @State FaceOpenStatue: string = '0'; //是否开启人脸识别
 | 
				
			||||||
  @State faceCatchImg: string = ''
 | 
					  @State faceCatchImg: string = ''
 | 
				
			||||||
  @State Param803Str: string = ''
 | 
					  @State Param803Str:string = ''
 | 
				
			||||||
  // 过程照片拍照
 | 
					  // 过程照片拍照
 | 
				
			||||||
  getPhoto = async (empty?: boolean) => {
 | 
					  getPhoto = async (empty?: boolean) => {
 | 
				
			||||||
    const singlePlay = globalThis.singlePlay
 | 
					    const singlePlay = globalThis.singlePlay
 | 
				
			||||||
@ -87,10 +86,7 @@ struct UserInfo {
 | 
				
			|||||||
      return photoBase64
 | 
					      return photoBase64
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
  private filePhoto: FilePhoto
 | 
					  private AccountTable = new AccountTable(() => {}, USER);
 | 
				
			||||||
  private avPlayer
 | 
					 | 
				
			||||||
  private AccountTable = new AccountTable(() => {
 | 
					 | 
				
			||||||
  }, USER);
 | 
					 | 
				
			||||||
  private context = getContext(this) as common.UIAbilityContext;
 | 
					  private context = getContext(this) as common.UIAbilityContext;
 | 
				
			||||||
  private labelBlocks = [
 | 
					  private labelBlocks = [
 | 
				
			||||||
    { label: '考生姓名', key: 'xm' },
 | 
					    { label: '考生姓名', key: 'xm' },
 | 
				
			||||||
@ -265,8 +261,8 @@ struct UserInfo {
 | 
				
			|||||||
        this.isBoardPrePareSetPopupOpen = true;
 | 
					        this.isBoardPrePareSetPopupOpen = true;
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
      // 开始考试前必须解开安全带或关车门
 | 
					      // 开始考试前必须解开安全带或关车门
 | 
				
			||||||
      if (sys.v_no === '803') {
 | 
					      if (sys.v_no === '803'){
 | 
				
			||||||
        this.Param803Str = sys.v_value + '';
 | 
					        this.Param803Str = sys.v_value+'';
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
    })
 | 
					    })
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@ -316,13 +312,13 @@ struct UserInfo {
 | 
				
			|||||||
        const studentRefreshParam = syssetParams.filter(sys => sys.v_no === '452')
 | 
					        const studentRefreshParam = syssetParams.filter(sys => sys.v_no === '452')
 | 
				
			||||||
        that.studentRefreshStatue = studentRefreshParam?.[0]?.v_value || '0'
 | 
					        that.studentRefreshStatue = studentRefreshParam?.[0]?.v_value || '0'
 | 
				
			||||||
        const openCheckFlagParam = syssetParams.filter(sys => sys.v_no == '17')
 | 
					        const openCheckFlagParam = syssetParams.filter(sys => sys.v_no == '17')
 | 
				
			||||||
        const openCheckFlag = openCheckFlagParam?.[0]?.v_value == '1' ? '1' : '0'
 | 
					        const openCheckFlag =openCheckFlagParam?.[0]?.v_value == '1' ? '1' : '0'
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        const faceParam = syssetParams.filter(sys => sys.v_no == '2413')
 | 
					        const faceParam = syssetParams.filter(sys => sys.v_no == '2413')
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        // faceParam?.[0]?.v_value ||
 | 
					        // faceParam?.[0]?.v_value ||
 | 
				
			||||||
        // 1身份证读卡器 2指纹 3人脸
 | 
					        // 1身份证读卡器 2指纹 3人脸
 | 
				
			||||||
        if (openCheckFlag == '1') {
 | 
					        if(openCheckFlag=='1'){
 | 
				
			||||||
          that.FaceOpenStatue = faceParam?.[0]?.v_value == '3' ? '1' : '0'
 | 
					          that.FaceOpenStatue = faceParam?.[0]?.v_value == '3' ? '1' : '0'
 | 
				
			||||||
          this.faceFlag = faceParam?.[0]?.v_value || '0'
 | 
					          this.faceFlag = faceParam?.[0]?.v_value || '0'
 | 
				
			||||||
          if (faceParam?.[0]?.v_value == '1') {
 | 
					          if (faceParam?.[0]?.v_value == '1') {
 | 
				
			||||||
@ -386,7 +382,7 @@ struct UserInfo {
 | 
				
			|||||||
      return
 | 
					      return
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    const param = `<getExaminationStudentInfoReq><head><checkCode>${Md5.Instance.get_md5(globalThis.carInfo.carId + globalThis.carInfo.examinationRoomId + globalThis.username)}</checkCode></head><body><carId>${globalThis.carInfo.carId}</carId><examinationRoomId>${globalThis.carInfo.examinationRoomId}</examinationRoomId><examinerName>${globalThis.username}</examinerName></body></getExaminationStudentInfoReq>`
 | 
					    const param = `<getExaminationStudentInfoReq><head><checkCode>${Md5.Instance.get_md5(globalThis.carInfo.carId + globalThis.carInfo.examinationRoomId + globalThis.username)}</checkCode></head><body><carId>${globalThis.carInfo.carId}</carId><examinationRoomId>${globalThis.carInfo.examinationRoomId}</examinationRoomId><examinerName>${globalThis.username}</examinerName></body></getExaminationStudentInfoReq>`
 | 
				
			||||||
    getExaminationStudentInfo(param).then(async (res) => {
 | 
					    getExaminationStudentInfo(param).then(async(res) => {
 | 
				
			||||||
      setTimeout(() => {
 | 
					      setTimeout(() => {
 | 
				
			||||||
        this.updateTimeLimit = true
 | 
					        this.updateTimeLimit = true
 | 
				
			||||||
      }, 30000)
 | 
					      }, 30000)
 | 
				
			||||||
@ -434,8 +430,8 @@ struct UserInfo {
 | 
				
			|||||||
      globalThis.ksyh = this.currentUser.ksy1sfzmhm || this.currentUser.ksy2sfzmhm
 | 
					      globalThis.ksyh = this.currentUser.ksy1sfzmhm || this.currentUser.ksy2sfzmhm
 | 
				
			||||||
      console.log('this.currentUse3' + JSON.stringify(this.currentUser))
 | 
					      console.log('this.currentUse3' + JSON.stringify(this.currentUser))
 | 
				
			||||||
      this.pageIndex = 0
 | 
					      this.pageIndex = 0
 | 
				
			||||||
      getSyncData('USER').then(data => {
 | 
					      getSyncData('USER').then(data=>{
 | 
				
			||||||
        if (data?.[0]) {
 | 
					        if(data?.[0]){
 | 
				
			||||||
          this.getCurrentStudent(data[0].sfzmhm)
 | 
					          this.getCurrentStudent(data[0].sfzmhm)
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
      })
 | 
					      })
 | 
				
			||||||
@ -522,13 +518,13 @@ struct UserInfo {
 | 
				
			|||||||
    this.currentUser.id = '1'
 | 
					    this.currentUser.id = '1'
 | 
				
			||||||
    const avPlayer = this.avPlayer;
 | 
					    const avPlayer = this.avPlayer;
 | 
				
			||||||
    this.isLoadingPopupVisible = true
 | 
					    this.isLoadingPopupVisible = true
 | 
				
			||||||
    avPlayer.playAudio([`voice/监管通信中.mp3`], false, async () => {
 | 
					    avPlayer.playAudio([`voice/监管通信中.mp3`],false,async ()=>{
 | 
				
			||||||
      const temp = await this.beginExam();
 | 
					      const temp = await this.beginExam();
 | 
				
			||||||
      console.info('surenjun', JSON.stringify(temp))
 | 
					      console.info('surenjun',JSON.stringify(temp))
 | 
				
			||||||
      if (temp.code != 1) {
 | 
					      if (temp.code != 1) {
 | 
				
			||||||
        promptAction.showToast({
 | 
					        promptAction.showToast({
 | 
				
			||||||
          message: temp.message,
 | 
					          message:temp.message,
 | 
				
			||||||
          duration: 4000
 | 
					          duration:4000
 | 
				
			||||||
        })
 | 
					        })
 | 
				
			||||||
        return
 | 
					        return
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
@ -554,15 +550,15 @@ struct UserInfo {
 | 
				
			|||||||
    const {isCheckFireOpen} = judgeConfig
 | 
					    const {isCheckFireOpen} = judgeConfig
 | 
				
			||||||
    const {Param803Str,isBoardPrePareSetPopupOpen} = this;
 | 
					    const {Param803Str,isBoardPrePareSetPopupOpen} = this;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    if (Param803Str === '') {
 | 
					    if(Param803Str === ''){
 | 
				
			||||||
      return true
 | 
					      return true
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    return new Promise((resolve, reject) => {
 | 
					    return new Promise((resolve,reject)=>{
 | 
				
			||||||
      if (isCheckFireOpen) {
 | 
					      if(isCheckFireOpen){
 | 
				
			||||||
        resolve(true)
 | 
					        resolve(true)
 | 
				
			||||||
        return
 | 
					        return
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
      let plcValue = globalThis.udpClient.getCurrentMessage();
 | 
					      let plcValue =  globalThis.udpClient.getCurrentMessage();
 | 
				
			||||||
      const msgArr = plcValue.split(',') || ''
 | 
					      const msgArr = plcValue.split(',') || ''
 | 
				
			||||||
      const mkg = msgArr[14];
 | 
					      const mkg = msgArr[14];
 | 
				
			||||||
      const fdjzs = msgArr[25];
 | 
					      const fdjzs = msgArr[25];
 | 
				
			||||||
@ -572,79 +568,79 @@ struct UserInfo {
 | 
				
			|||||||
      const ssc = msgArr[13];
 | 
					      const ssc = msgArr[13];
 | 
				
			||||||
      const dw = msgArr[28];
 | 
					      const dw = msgArr[28];
 | 
				
			||||||
      // 开始考试信号检测
 | 
					      // 开始考试信号检测
 | 
				
			||||||
      if (Param803Str !== '') {
 | 
					      if(Param803Str !== ''){
 | 
				
			||||||
        //安全带
 | 
					        //安全带
 | 
				
			||||||
        if (aqd == 1 && Param803Str.includes('1')) {
 | 
					        if(aqd == 1 && Param803Str.includes('1')){
 | 
				
			||||||
          this.avPlayer.playAudio(['voice/请解开安全带.mp3'])
 | 
					          this.avPlayer.playAudio(['voice/请解开安全带.mp3'])
 | 
				
			||||||
          promptAction.showToast({
 | 
					          promptAction.showToast({
 | 
				
			||||||
            message: '请解开安全带',
 | 
					            message:'请解开安全带',
 | 
				
			||||||
            duration: 4000
 | 
					            duration:4000
 | 
				
			||||||
          })
 | 
					          })
 | 
				
			||||||
          reject(false)
 | 
					          reject(false)
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
        //门开关
 | 
					        //门开关
 | 
				
			||||||
        if (mkg == 1 && Param803Str.includes('2')) {
 | 
					        if(mkg == 1 && Param803Str.includes('2')){
 | 
				
			||||||
          this.avPlayer.playAudio(['voice/关门.mp3'])
 | 
					          this.avPlayer.playAudio(['voice/关门.mp3'])
 | 
				
			||||||
          promptAction.showToast({
 | 
					          promptAction.showToast({
 | 
				
			||||||
            message: '请关闭车门',
 | 
					            message:'请关闭车门',
 | 
				
			||||||
            duration: 4000
 | 
					            duration:4000
 | 
				
			||||||
          })
 | 
					          })
 | 
				
			||||||
          reject(false)
 | 
					          reject(false)
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
        //远、近光灯
 | 
					        //远、近光灯
 | 
				
			||||||
        if ((jgd == 1 || ygd == 1) && Param803Str.includes('3')) {
 | 
					        if((jgd == 1 || ygd == 1) && Param803Str.includes('3')){
 | 
				
			||||||
          this.avPlayer.playAudio(['voice/请关闭远近光灯.mp3'])
 | 
					          this.avPlayer.playAudio(['voice/请关闭远近光灯.mp3'])
 | 
				
			||||||
          promptAction.showToast({
 | 
					          promptAction.showToast({
 | 
				
			||||||
            message: '请关闭远近光灯',
 | 
					            message:'请关闭远近光灯',
 | 
				
			||||||
            duration: 4000
 | 
					            duration:4000
 | 
				
			||||||
          })
 | 
					          })
 | 
				
			||||||
          reject(false)
 | 
					          reject(false)
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
        //拉手刹
 | 
					        //拉手刹
 | 
				
			||||||
        if (ssc == 0 && Param803Str.includes('4')) {
 | 
					        if(ssc == 0 && Param803Str.includes('4')){
 | 
				
			||||||
          this.avPlayer.playAudio(['voice/请拉手刹.mp3'])
 | 
					          this.avPlayer.playAudio(['voice/请拉手刹.mp3'])
 | 
				
			||||||
          promptAction.showToast({
 | 
					          promptAction.showToast({
 | 
				
			||||||
            message: '请拉手刹',
 | 
					            message:'请拉手刹',
 | 
				
			||||||
            duration: 4000
 | 
					            duration:4000
 | 
				
			||||||
          })
 | 
					          })
 | 
				
			||||||
          reject(false)
 | 
					          reject(false)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
        //请点火
 | 
					        //请点火
 | 
				
			||||||
        if (fdjzs * 1 <= 0 && Param803Str.includes('5')) {
 | 
					        if(fdjzs*1 <=0 && Param803Str.includes('5')){
 | 
				
			||||||
          this.avPlayer.playAudio(['voice/点火.mp3'])
 | 
					          this.avPlayer.playAudio(['voice/点火.mp3'])
 | 
				
			||||||
          promptAction.showToast({
 | 
					          promptAction.showToast({
 | 
				
			||||||
            message: '请点火',
 | 
					            message:'请点火',
 | 
				
			||||||
            duration: 4000
 | 
					            duration:4000
 | 
				
			||||||
          })
 | 
					          })
 | 
				
			||||||
          reject(false)
 | 
					          reject(false)
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
        //置空档
 | 
					        //置空档
 | 
				
			||||||
        if (dw != 0 && Param803Str.includes('6')) {
 | 
					        if(dw != 0 && Param803Str.includes('6')){
 | 
				
			||||||
          this.avPlayer.playAudio(['voice/请置空档.mp3'])
 | 
					          this.avPlayer.playAudio(['voice/请置空档.mp3'])
 | 
				
			||||||
          promptAction.showToast({
 | 
					          promptAction.showToast({
 | 
				
			||||||
            message: '请置空档',
 | 
					            message:'请置空档',
 | 
				
			||||||
            duration: 4000
 | 
					            duration:4000
 | 
				
			||||||
          })
 | 
					          })
 | 
				
			||||||
          reject(false)
 | 
					          reject(false)
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
      // 考前绕车一周信号检测
 | 
					      // 考前绕车一周信号检测
 | 
				
			||||||
      if (isBoardPrePareSetPopupOpen) {
 | 
					      if(isBoardPrePareSetPopupOpen){
 | 
				
			||||||
        //请熄火
 | 
					        //请熄火
 | 
				
			||||||
        if (fdjzs * 1 > 0) {
 | 
					        if(fdjzs*1 > 0){
 | 
				
			||||||
          this.avPlayer.playAudio(['voice/熄火.mp3'])
 | 
					          this.avPlayer.playAudio(['voice/熄火.mp3'])
 | 
				
			||||||
          promptAction.showToast({
 | 
					          promptAction.showToast({
 | 
				
			||||||
            message: '请熄火',
 | 
					            message:'请熄火',
 | 
				
			||||||
            duration: 4000
 | 
					            duration:4000
 | 
				
			||||||
          })
 | 
					          })
 | 
				
			||||||
          reject(false)
 | 
					          reject(false)
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
        if (mkg == 1) {
 | 
					        if(mkg == 1){
 | 
				
			||||||
          this.avPlayer.playAudio(['voice/关门.mp3'])
 | 
					          this.avPlayer.playAudio(['voice/关门.mp3'])
 | 
				
			||||||
          promptAction.showToast({
 | 
					          promptAction.showToast({
 | 
				
			||||||
            message: '请关闭车门',
 | 
					            message:'请关闭车门',
 | 
				
			||||||
            duration: 4000
 | 
					            duration:4000
 | 
				
			||||||
          })
 | 
					          })
 | 
				
			||||||
          reject(false)
 | 
					          reject(false)
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
@ -682,7 +678,7 @@ struct UserInfo {
 | 
				
			|||||||
      //接口标识
 | 
					      //接口标识
 | 
				
			||||||
      jkid: '17C51',
 | 
					      jkid: '17C51',
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    console.info('surenjun', JSON.stringify(param))
 | 
					    console.info('surenjun',JSON.stringify(param))
 | 
				
			||||||
    const temp = await writeObjectOut(param);
 | 
					    const temp = await writeObjectOut(param);
 | 
				
			||||||
    globalThis.lsh = this.currentUser.lsh
 | 
					    globalThis.lsh = this.currentUser.lsh
 | 
				
			||||||
    globalThis.ksyh = this.currentUser.ksy1sfzmhm || this.currentUser.ksy2sfzmhm;
 | 
					    globalThis.ksyh = this.currentUser.ksy1sfzmhm || this.currentUser.ksy2sfzmhm;
 | 
				
			||||||
@ -736,7 +732,7 @@ struct UserInfo {
 | 
				
			|||||||
            .backgroundImage(item.sfzmhm != this.currentUser.sfzmhm ? $r('app.media.userbox2') : $r('app.media.userboxbg'))
 | 
					            .backgroundImage(item.sfzmhm != this.currentUser.sfzmhm ? $r('app.media.userbox2') : $r('app.media.userboxbg'))
 | 
				
			||||||
            .backgroundImageSize({ width: '100%', height: '100%' })
 | 
					            .backgroundImageSize({ width: '100%', height: '100%' })
 | 
				
			||||||
            .onClick(() => {
 | 
					            .onClick(() => {
 | 
				
			||||||
              if (this.isExamStart) {
 | 
					              if(this.isExamStart){
 | 
				
			||||||
                return
 | 
					                return
 | 
				
			||||||
              }
 | 
					              }
 | 
				
			||||||
              this.currentUser = item
 | 
					              this.currentUser = item
 | 
				
			||||||
@ -861,7 +857,7 @@ struct UserInfo {
 | 
				
			|||||||
                    this.sfbdinterfaceFn()
 | 
					                    this.sfbdinterfaceFn()
 | 
				
			||||||
                  }
 | 
					                  }
 | 
				
			||||||
                } catch (e) {
 | 
					                } catch (e) {
 | 
				
			||||||
                  console.info('Throw Error', JSON.stringify(e))
 | 
					                  console.info('Throw Error',JSON.stringify(e))
 | 
				
			||||||
                }
 | 
					                }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
              })
 | 
					              })
 | 
				
			||||||
@ -924,7 +920,7 @@ struct UserInfo {
 | 
				
			|||||||
      }
 | 
					      }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
      // loading
 | 
					      // loading
 | 
				
			||||||
      if (this.isLoadingPopupVisible) {
 | 
					      if(this.isLoadingPopupVisible){
 | 
				
			||||||
        LoadingPopup({
 | 
					        LoadingPopup({
 | 
				
			||||||
          title: this.loadingText,
 | 
					          title: this.loadingText,
 | 
				
			||||||
        })
 | 
					        })
 | 
				
			||||||
@ -964,7 +960,7 @@ struct CommText {
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
  build() {
 | 
					  build() {
 | 
				
			||||||
    Text(this.text)
 | 
					    Text(this.text)
 | 
				
			||||||
      .fontSize(19.5 * this.ratio)
 | 
					      .fontSize(16 * this.ratio)
 | 
				
			||||||
      .lineHeight(30 * this.ratio)
 | 
					      .lineHeight(30 * this.ratio)
 | 
				
			||||||
      .fontWeight(500)
 | 
					      .fontWeight(500)
 | 
				
			||||||
      .fontColor(this.color)
 | 
					      .fontColor(this.color)
 | 
				
			||||||
 | 
				
			|||||||
@ -31,7 +31,6 @@ workerPort.onmessage = (e: MessageEvents): void => {
 | 
				
			|||||||
  if(param.mode=='1'){
 | 
					  if(param.mode=='1'){
 | 
				
			||||||
    //单中心
 | 
					    //单中心
 | 
				
			||||||
    getSingleCenterTable(param).then((ret) => {
 | 
					    getSingleCenterTable(param).then((ret) => {
 | 
				
			||||||
      console.log('teststetfinsh1')
 | 
					 | 
				
			||||||
      if (ret) {
 | 
					      if (ret) {
 | 
				
			||||||
        workerPort.postMessage({ isComplete: true });
 | 
					        workerPort.postMessage({ isComplete: true });
 | 
				
			||||||
      }else{
 | 
					      }else{
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user