| | |
| | | { |
| | | "name": "sign-tool", |
| | | "version": "2.7.3", |
| | | "version": "2.7.4", |
| | | "icon": "public/favicon.ico", |
| | | "main": "dist/electron/main/index.js", |
| | | "author": "", |
| | |
| | | timeJg:10000, |
| | | base_api:"", |
| | | face_push:3, |
| | | beginWorkTime:5, |
| | | endWorkTime:22, |
| | | Is_ce_wen:false, |
| | | portPath:'COM5', |
| | | baudRate:115200, |
| | |
| | | import { ElMessage } from 'element-plus' |
| | | import { confingInfoStore } from '@/stores/StoresConfing' |
| | | |
| | | // let BASE_URL = 'http://testbs.ihemodialysis.com' |
| | | let BASE_URL = 'https://hemobs.icoldchain.cn' |
| | | let BASE_URL = 'http://testbs.ihemodialysis.com' |
| | | // let BASE_URL = 'https://hemobs.icoldchain.cn' |
| | | const TIME_OUT = 10 * 1000 |
| | | |
| | | // setTimeout(()=>{ |
| | |
| | | import { Data } from "electron/main" |
| | | |
| | | import { confingInfoStore } from '@/stores/StoresConfing' |
| | | /** |
| | | * 时间日期转换 |
| | | * @param date 当前时间,new Date() 格式 |
| | |
| | | var differenceInSeconds = Math.floor(differenceInMilliseconds / 1000); |
| | | return differenceInSeconds |
| | | } |
| | | // 获取工作时间 |
| | | export function isworkTime(param: Date): boolean { |
| | | const begin=confingInfoStore().confingInfo.beginWorkTime |
| | | const endW=confingInfoStore().confingInfo.endWorkTime |
| | | const hour: number = new Date(param).getHours() |
| | | if(begin===undefined||endW===undefined) return true |
| | | if (hour < begin||hour>endW) return false |
| | | else return true |
| | | } |
| | | |
| | |
| | | import Speech from 'speak-tts' |
| | | import { reactive,computed, toRefs, onMounted, watch, ref } from "vue" |
| | | import { sendPationCodeApi } from '../../samples/httpApi' |
| | | import { formatDate,jgTime } from '@/utils/formatTime' |
| | | import { formatDate,jgTime,isworkTime } from '@/utils/formatTime' |
| | | import { confingInfoStore } from '@/stores/StoresConfing' |
| | | import {base64toFile} from '@/samples/faceApi' |
| | | import{initPort} from '@/samples/portApi' |
| | |
| | | // console.log('没有监测到---') |
| | | msg.value = "没识别到人脸..."; |
| | | } else if(event.data.length >= 1){ |
| | | |
| | | trackerTask.stop(); |
| | | msg.value = "检测到人脸"; |
| | | console.log('监测到人脸2样') |
| | | console.log('监测到人脸样') |
| | | console.log(event.data) |
| | | const myCanvas = document.getElementById("myCanvas");// |
| | | const thisContext = myCanvas?.getContext("2d"); |
| | |
| | | const X= jgTime(lsDateTime,new Date()) |
| | | |
| | | // 转文件 |
| | | // 识别框显示才能到传阿里云识别 |
| | | if(dialogVisible.value&&X>configData.value.face_push){ |
| | | // 识别框显示才能到传阿里云识别并且时间要是工作时间 |
| | | if(dialogVisible.value&&X>configData.value.face_push&&isworkTime(new Date())){ |
| | | lsDateTime=new Date() |
| | | console.log(X,'上传阿里识别间隔') |
| | | base64toFile(imgSrc) |