123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212 |
- <template>
- <div class="test">
- <div class="close" @click="confirmExit"></div>
- <div class="toolList">
- <div class="li">{{ date }}</div>
- <div class="li btn speck" @click="speckCancel"></div>
- <div class="li btn screen" @click="getFullScreen"></div>
- </div>
- <div class="logo"> <img src="@/assets/images/logo.png">
- </img>
- <div class="title"><i></i><span>{{ dic.project[parameter.project] || "" }}</span></div>
- </div>
- <div class="main">
- <div class="main-left">
- <div class="main-left-top">
- <div class="top-left" @click="getChooseStudent">
- <div class="top-left-center">
- <div class="pic" :class="{ 'pic2': faceCheckStu.student_id }" v-if="faceCheckStu.student_id"> <img
- :src="faceCheckStu.logo_url || faceCheckStu.face_pic" /></div>
- <div class="pic" v-else>
- <img src="@/assets/images/test/profilePicture.png" />
- </div>
- <div class="name" :class="{ 'name2': faceCheckStu.student_id }">
- {{ faceCheckStu.student_id ? faceCheckStu.name : "虚伪以待" }}
- </div>
- </div>
- </div>
- <div class="top-right">
- <div class="time" v-if="needStart && [42, 43].includes(examState)">{{
- time.countdownNum
- }}</div>
- <div class="tips" v-if="examState == 41">
- <img v-if="parameter.gesture" src="@/assets/images/test/ready1.png" />
- <img v-if="!parameter.gesture" src="@/assets/images/test/ready2.png" />
- </div>
- <div class="complete" v-if="faceCheckStu.student_id">
- <div class="scoreBox">
- <div class="score">{{ currentResultObj.count }}</div>
- <!-- <div class="unit" v-if="currentResultObj.count">{{ unit }}</div> -->
- </div>
- <div class="fractionViolation">
- <div class="fraction">
- <div class="lable">得分:</div>
- <div class="value">{{ currentResultObj.score }}</div>
- </div>
- <div class="violation">
- <div class="lable">{{ ['jumprope'].includes(parameter.project) ? '中断' : '犯规' }}</div>
- <div class="value">{{ currentResultObj.back_num }}</div>
- </div>
- </div>
- </div>
- <div v-if="examState == 42 && backReason.length">
- <div>违规项</div>
- <div v-for="(item, index) in backReason" :key="index">{{ item }}</div>
- </div>
- <div class="btn" @click="getStartOneTest" v-if="needStart && examState == 43">开始测试</div>
- <!-- <div v-if="needStart"> -->
- <!-- <div class="btn" @click="getOpenOneTestAndStartFace" v-if="examState == 3 || examState == 40">开始识别</div> -->
- <!-- <div class="btn" @click="getStopFace" v-if="examState == 41 && !parameter.gesture">停止人脸识别</div> -->
- <!-- <div class="btn" @click="getStartOneTest" v-if="examState == 43">开始测试</div> -->
- <!-- <div @click="getRetestFace" v-if="examState == 43 || examState == 42">重新识别</div> -->
- <!-- </div> -->
- <!-- <div>当前状态:({{ examState == 3 ? "初始化完成" : examState == 40 ? "创建测试" : examState == 41 ? "正在人脸识别":examState == 43 ? "停止人脸识别" : examState == 42 ? "正在测试" : "请初始化" }})</div> -->
- <!-- <div @click="getAgain" v-if="examState == 42 || showTestAgain">再测一次</div> -->
- </div>
- <i></i>
- </div>
- <div class="main-left-bottom">
- <div class="bottom-left">
- <div class="tips"><img src="/src/assets/images/test/tips.png" /></div>
- <div class="pic"><img :src="'/src/assets/images/test/tips/' + parameter.project + '.png'" /></div>
- </div>
- <div class="bottom-right" v-html="dic.projectNote[parameter.project]">
- </div>
- </div>
- </div>
- <div class="main-right">
- <div class="title">测试记录</div>
- <ul>
- <li v-for="(item, index) in reportList " :key="index">
- <div class="left">
- <div class="pic"><img :src="item.face_pic || item.logo_url" /></div>
- <div class="txt">
- <div>
- <div class="name">{{ item.student_name }}</div>
- <div class="className"></div>
- </div>
- </div>
- </div>
- <div class="right">
- <div class="score">{{ item.result }}
- </div>
- <div class="unit">{{ unit }}</div>
- </div>
- </li>
- </ul>
- <div class="erweima"> <img src="@/assets/images/login/erweima.png" />
- <span>扫码查看详情</span>
- </div>
- </div>
- </div>
- <FaceWindow ref="faceWindowRef" :faceCheckStu="faceCheckStu" />
- <ChooseStudent ref="chooseStudentRef" @returnData="returnStudent" />
- </div>
- </template>
- <script setup name="TrainTest" lang="ts">
- import { initSpeech, speckText, speckCancel, chineseNumber } from '@/utils/speech'
- import { initWs, examEnds, openOneTest, startFace, stopFace, faceConfirmOnly, startOneTest, finishOneTest, closeOneTest, suspendFaceRecognitionChannels, resumeFaceRecognitionChannels } from '@/utils/ws'
- import dayjs from 'dayjs'
- import dataDictionary from "@/utils/dataDictionary"
- const { proxy } = getCurrentInstance() as any;
- const router = useRouter();
- const route = useRoute();
- const faceWindowRef = ref();
- const chooseStudentRef = ref();
- const myInfo: any = localStorage.getItem("userInfo");
- const dic: any = dataDictionary;
- const data = reactive<any>({
- timerManager: {},//计时器管理
- parameter: {},//参数
- time: {
- testTime: 60,//时长
- countdownNum: 0,//计时
- },
- userInfo: {},//用户信息
- examState: 0,//当前状态
- resultId: null,//测试ID
- currentResultObj: {},//成绩
- faceCheckStu: {},//人脸信息
- unit: "",//单位
- backReason: [],//犯规项
- needStart: false,//是否需要按钮
- showTestAgain: false,//再测一次按钮
- reportList: [],//测试列表
- date: "",//当前时间
- });
- const { timerManager, parameter, time, userInfo, examState, resultId, faceCheckStu, currentResultObj, unit, backReason, needStart, showTestAgain, reportList, date } = toRefs(data);
- /**
- * 接收消息
- */
- const getMessage = (e: any) => {
- //console.log("WS响应:", e)
- //实时状态
- if (e.cmd === 'exam_status') {
- examState.value = e.data;
- }
- //工作站状态
- if (e.cmd === 'init_result') {
- }
- //测试违规
- if (e.cmd === 'warning_result') {
- }
- //后端播报语音
- if (e.cmd === 'return_audio_msg') {
- }
- //错误提示
- if (e.cmd === 'info_result') {
- proxy?.$modal.msgError(e.data.message);
- }
- //错误提示
- if (e.cmd === 'error_result') {
- proxy?.$modal.msgError(e.data.message);
- }
- //测试中违规提示
- if (e.cmd === 'warning_notify') {
- }
- //断线状态
- if (e.cmd === 'disconnect_request') {
- if (e.data.message) {
- speckText(e.data.message);
- }
- getExit();
- }
- //状态变更
- if (e.cmd === 'set_exam_state') {
- examState.value = e.data;
- if (e.data === 3) {
- initProject();
- }
- if (e.data === 40) {
- cleanData();
- }
- if (e.data == 41) {
- getFaceWindow(true);
- }
- if (e.data == 43) {
- }
- if (e.data == 42) {
- }
- }
- //新建测试后返回信息,获取result_id
- if (e.cmd === 'open_one_test_ack') {
- resultId.value = e.data.result_id;
- }
- //人脸识别状态
- if (e.cmd === 'face_check_result') {
- let myData = e.data[0] || e.data;
- returnStudent(myData);
- }
- //测试结束结果
- if (e.cmd === 'oneresult') {
- if (e.data.length) {
- let data = e.data[0];
- getAchievement(data)
- }
- }
- //结果生成完成(视频图片)
- if (e.cmd === 'static_urls_finished') {
- }
- //选择学生或测试结束后返回的数据
- if (e.cmd === 'result_info') {
- }
- };
- /**
- * 开始识别
- */
- const getOpenOneTestAndStartFace = async () => {
- if (examState.value > 3) {
- await closeOneTest();
- }
- await openOneTest();
- await startFace();
- };
- /**
- * 停止人脸识别
- */
- const getStopFace = async () => {
- // 旧版识别成功直接43了这里先屏蔽
- // if (examState.value != 41) {
- // return false;
- // }
- getClearTimer("face");
- speckText(faceCheckStu.value.name + ",请准备");
- await stopFace();
- if (faceCheckStu.value.student_id) {
- getFaceConfirmOnly();
- }
- };
- /**
- * 确定人脸信息
- */
- const getFaceConfirmOnly = (data?: any) => {
- if (data) {
- faceCheckStu.value = data;
- }
- faceConfirmOnly({
- result_id: resultId.value,
- student_id: faceCheckStu.value.student_id,
- gender: faceCheckStu.value.gender
- }, () => {
- faceWindowRef.value?.close();
- //不需要按钮的自动进入下一步
- if (needStart.value == false) {
- getStartOneTest();
- }
- });
- };
- /**
- * 重新识别
- */
- const getRetestFace = () => {
- proxy?.$modal.confirm("确定重新识别吗?").then(() => {
- if (needStart.value == false) {
- //自动流程项目重新识别直接返回3
- closeOneTest();
- } else {
- //手动流程项目重新识别43返回41,42返回3
- if (examState.value == 43) {
- cleanData();
- startFace();
- } else {
- closeOneTest();
- }
- }
- }).finally(() => {
- });
- };
- /**
- * 开始测试
- */
- const getStartOneTest = () => {
- if (examState.value != 43 || !faceCheckStu.value.student_id) {
- return false;
- }
- if (!faceCheckStu.value.student_id) {
- proxy?.$modal.msgError("请选择人员!");
- return false;
- }
- startOneTest(data == null, () => {
- //显示再测一次按钮
- showTestAgain.value = true;
- //停止播报;
- speckCancel()
- //计时项目才开
- if (needStart.value == true) {
- //时间为0的为正计时,大于0的为倒计时
- if (time.value.testTime == 0) {
- getCounting("+");
- } else {
- getCounting("-");
- }
- speckText("哨声");
- } else {
- speckText(faceCheckStu.value.name + ",请开始测试");
- }
- })
- };
- /**
- * 再测一次
- */
- const getAgain = async () => {
- //预存测试人员
- let student = JSON.parse(JSON.stringify(faceCheckStu.value));
- //测试中
- if (examState.value == 42) {
- await finishOneTest();
- }
- //其他状态
- if (examState.value > 3) {
- await closeOneTest();
- }
- //重新走一次流程
- await openOneTest();
- await startFace();
- await stopFace();
- getFaceConfirmOnly(student);
- };
- /**
- * 确认退出
- */
- const confirmExit = () => {
- proxy?.$modal.confirm("确定退出吗?").then(() => {
- getExit();
- }).finally(() => {
- });
- };
- /**
- * 退出
- */
- const getExit = () => {
- getClearTimer();//清除计时器
- examEnds();//通知工作站关闭
- speckCancel()//停止播报;
- router.push({ path: '/' });//跳转
- };
- /**
- * 清空定时任务
- */
- const getClearTimer = (data?: any) => {
- if (data) {
- //清除指定
- clearInterval(timerManager.value[data])
- timerManager.value[data] = null;
- } else {
- //清除全部
- for (let key in timerManager.value) {
- if (timerManager.value.hasOwnProperty(key)) {
- clearInterval(timerManager.value[key])
- timerManager.value[key] = null;
- }
- }
- }
- };
- /**
- * 选择学生
- */
- const getChooseStudent = () => {
- if (examState.value < 41) {
- if (needStart.value) {
- proxy?.$modal.msgError("请点击开始识别");
- } else {
- proxy?.$modal.msgError("请等待");
- }
- }
- if (examState.value == 41) {
- chooseStudentRef.value.open();
- //然后定时自动关闭
- setTimeout(() => {
- faceWindowRef.value.close();
- }, 3000)
- }
- if (examState.value == 43) {
- getRetestFace();
- }
- };
- /**
- * 返回被选学生
- */
- const returnStudent = (data: any) => {
- faceCheckStu.value = data;
- faceWindowRef.value.open();
- //然后定时自动关闭
- setTimeout(() => {
- faceWindowRef.value.close();
- }, 1000)
- getStopFace();
- };
- /**
- * 清除历史记录
- */
- const cleanData = () => {
- time.value.countdownNum = time.value.testTime;
- showTestAgain.value = false;
- faceCheckStu.value = {};
- currentResultObj.value = {};
- backReason.value = [];
- };
- /**
- * 自动初始化项目
- */
- const initProject = () => {
- //停止计时
- getClearTimer("countdownTimer");
- //自动项目定时进入下一步
- let time = 0;
- //控制新建测试的时间,第一次快,之后就慢
- if (!faceCheckStu.value.student_id) {
- time = 1000;
- } else {
- time = 6000;
- }
- setTimeout(() => {
- //再加一个判断以免和再测一次冲突
- if (examState.value == 3) {
- getOpenOneTestAndStartFace();
- }
- }, time)
- };
- /**
- * 时间转换
- */
- // const countdownNumFormat = computed(() => {
- // return time.value.countdownNum;
- // //return proxy?.$utils.timeFormat(time.value.countdownNum);
- // });
- /**
- * 倒计时
- */
- const getCounting = (type: string) => {
- timerManager.value.countdownTimer = setInterval(() => {
- //正计时
- if (type == "+") {
- time.value.countdownNum++;
- }
- //倒计时
- if (type == "-") {
- if (time.value.countdownNum <= 0) {
- getClearTimer("countdownTimer");
- } else {
- time.value.countdownNum--;
- }
- }
- }, 1000);
- };
- /**
- * 人脸窗口
- */
- const getFaceWindow = (data: boolean) => {
- let txt = parameter.value.gesture ? "请举手看摄像头人脸识别" : "请看摄像头进行人脸识别";
- speckText(txt);
- //data=true为弹出框,data=false为不要弹出框
- if (data) {
- faceWindowRef.value.open();
- //然后定时自动关闭
- setTimeout(() => {
- if (examState.value == 41 && faceWindowRef.value.faceState == true) {
- faceWindowRef.value.close();
- }
- }, 3000)
- }
- //定时检查如果一直停留在人脸识别就提示
- timerManager.value.face = setInterval(() => {
- getClearTimer("face");
- if (examState.value == 41) {
- getFaceWindow(false);
- }
- }, 15000)
- };
- /**
- * 成绩
- */
- const getAchievement = (data: any) => {
- //console.log("成绩", data);
- let type = parameter.value.project;
- let count =
- data?.[dic.typeResultKey[type]]?.toFixed(0);
- if (["trijump", "solidball", "shotput", "longjump"].includes(type)) {
- count =
- data?.[dic.typeResultKey[type]]?.toFixed(2);
- count = Math.round(count) / 100;
- }
- data.count = count || "0";
- data.score = data.score || "0";
- currentResultObj.value = data;
- //违规处理
- let arr = backReason.value;
- if (["situp", "pullup", "sidepullup", "jumprope", "jumpingjack", "jump", "longjump", "verticaljump"]
- .indexOf(type) > -1) {
- if (["pullup", "situp", "jumprope", "jumpingjack"].indexOf(type) > -1) {
- currentResultObj.value.back_num = data?.all_failed_num;
- }
- if (type === "sidepullup") {
- currentResultObj.value.back_num = data?.["0"]?.hip_failed_num;
- }
- if (['jump', 'longjump', 'verticaljump'].includes(type)) {
- if (data?.startline_check == 0) {
- let txt = "踩线违规";
- arr.push(txt)
- }
- if (data?.singleleg_jump_check == 0) {
- let txt = "单脚跳违规";
- arr.push(txt)
- }
- if (data?.outside_check == 0) {
- let txt = "跳出测试区违规";
- arr.push(txt)
- }
- }
- if (
- data?.elbow_check == false
- ) {
- let txt = "肘部违规";
- arr.push(txt);
- }
- if (
- ["situp", "pullup"].indexOf(type) > -1 &&
- data?.knee_check === false
- ) {
- let txt = "腿部违规";
- if (!arr.includes(txt)) {
- arr.push(txt);
- }
- }
- if (["situp"].indexOf(type) > -1 && data?.hand_check === false) {
- let txt = "手部违规";
- if (!arr.includes(txt)) {
- arr.push(txt);
- }
- }
- if (
- ["pullup"].indexOf(type) > -1 &&
- data?.["0"]?.elbow_check === false
- ) {
- let txt = "手部违规";
- if (!arr.includes(txt)) {
- arr.push(txt);
- }
- }
- if (["situp"].indexOf(type) > -1 && data?.["0"]?.back_check === false) {
- let txt = "背部违规";
- if (!arr.includes(txt)) {
- arr.push(txt);
- }
- }
- if (
- ["sidepullup", "situp"].indexOf(type) > -1 &&
- data?.["0"]?.hip_check === false
- ) {
- let txt = "臀部违规";
- if (!arr.includes(txt)) {
- arr.push(txt);
- }
- }
- }
- backReason.value = arr;
- if (data.isfinish) {
- if (['jump'].includes(type) && backReason.value.length) {
- speckText("请重新测试");
- return false;
- }
- speckText(faceCheckStu?.value.name + "成绩为" + (chineseNumber(count) || 0) + unit.value + ",请下一位准备!" || "");
- getReportList();
- }
- };
- /**
- * 当天成绩列表
- */
- const getReportList = () => {
- let params: any = {
- start_date: dayjs().format("YYYY-MM-DD"),
- end_date: dayjs().format("YYYY-MM-DD"),
- exam_name: parameter.value.project,
- page: 1,
- per_page: 9000
- };
- proxy?.$http.common.reportList(params).then((res: any) => {
- if (res.data.length > 0) {
- reportList.value = res.data;
- }
- });
- };
- /**
- * 更新时间
- */
- const setDate = () => {
- date.value = proxy?.$utils.getDate();
- setTimeout(setDate, 1000);
- };
- /**
- * 更新时间
- */
- const getFullScreen = () => {
- date.value = proxy?.$utils.fullScreen();
- };
- onMounted(() => {
- setDate();
- parameter.value = route.query;
- let project = parameter.value.project;
- let area = parameter.value.area;
- parameter.value.examId = `${project}_${area}`; //项目+区
- if (parameter.value.time) {
- time.value.testTime = parameter.value.time
- }
- time.value.countdownNum = time.value.testTime;
- userInfo.value = JSON.parse(myInfo);
- unit.value = dic.unit[project];
- if (parameter.value.gesture == 'true') {
- parameter.value.gesture = true
- } else {
- parameter.value.gesture = false
- }
- //需要开始按钮的项目
- if (["jumprope", "skiprope", "jumpingjack", "situp"].includes(project)) {
- needStart.value = true;
- }
- //加载WS
- initWs({ parameter: parameter.value, testTime: time.value.testTime }, (data: any) => {
- getMessage(data);
- });
- initSpeech();
- getReportList();
- })
- onUnmounted(() => {
- getExit();
- })
- </script>
- <style lang="scss" scoped>
- $topPadding: 5.19rem;
- $waiPadding: 6.51rem;
- .logo {
- position: absolute;
- left: $waiPadding;
- top: $topPadding;
- display: flex;
- align-items: center;
- img {
- width: 14.563rem;
- }
- .title {
- width: auto;
- padding: 0 1.2rem 0 0.7rem;
- height: 3rem;
- line-height: 3rem;
- border-radius: 1.5rem;
- color: #ffffff;
- font-size: 1.7rem;
- margin-left: 1rem;
- background: linear-gradient(180deg, #FFB200 0%, #ED7905 72%);
- box-shadow: inset 0px 1px 0px 1px rgba(255, 255, 255, 0.5);
- display: flex;
- align-items: center;
- i {
- width: 2.5rem;
- height: 2.1rem;
- margin-right: 0.8rem;
- background-image: url("@/assets/images/test/ai.png");
- background-position: center;
- background-repeat: no-repeat;
- background-size: 100% 100%;
- }
- }
- }
- .close {
- width: 3.2rem;
- height: 3.2rem;
- position: absolute;
- right: calc($waiPadding - 3.2rem);
- top: calc($topPadding / 2 - 3.2rem/4);
- box-sizing: border-box;
- border: 1px solid #979797;
- background-image: url("@/assets/images/common/close.png");
- background-position: center;
- background-repeat: no-repeat;
- background-size: 45% 45%;
- background-color: rgba(216, 216, 216, 0.8);
- border-radius: 50%;
- transition: all 0.5s;
- cursor: pointer;
- &:hover {
- transform: rotate(180deg);
- background-color: rgba(216, 216, 216, 1);
- }
- }
- .toolList {
- position: absolute;
- right: $waiPadding;
- top: calc($topPadding / 2);
- color: #00FFE8;
- font-size: 1.1rem;
- display: flex;
- .li {
- margin-right: 3rem;
- }
- .btn {
- width: 1.1rem;
- height: 1.1rem;
- display: block;
- cursor: pointer;
- }
- .speck {
- background-image: url("@/assets/images/common/speck.png");
- background-position: center;
- background-repeat: no-repeat;
- background-size: 100% auto;
- }
- .screen {
- background-image: url("@/assets/images/common/screen.png");
- background-position: center;
- background-repeat: no-repeat;
- background-size: 100% auto;
- }
- }
- .main {
- width: calc(100% - ($waiPadding * 2));
- height: 78vh;
- padding-top: 10rem;
- margin: 0 auto;
- display: flex;
- justify-content: space-between;
- overflow: hidden;
- .main-left {
- width: 71.5%;
- display: flex;
- flex-direction: column;
- justify-content: space-between;
- .main-left-top {
- display: flex;
- justify-content: space-between;
- height: 55.8%;
- position: relative;
- .top-left {
- width: 37.4%;
- height: 100%;
- border-radius: 29px;
- background: radial-gradient(122% 126% at 97% 6%, #35FFC6 0%, #00FFE8 100%);
- text-align: center;
- display: flex;
- align-items: center;
- justify-content: center;
- cursor: pointer;
- .top-left-center {
- .pic {
- width: 22.3vh;
- height: 22.3vh;
- border-radius: 50%;
- display: flex;
- justify-content: center;
- align-items: center;
- overflow: hidden;
- margin: 0 auto 2vh auto;
- img {
- width: 100%;
- }
- }
- .pic2 {
- box-sizing: border-box;
- border: 0.44rem solid rgba(26, 41, 58, 0.6315);
- }
- .name {
- width: 100%;
- color: #1A293A;
- font-size: 2.21rem;
- }
- .name2 {
- padding: 0 0.3rem;
- border-radius: 1.1rem;
- background: radial-gradient(96% 96% at 2% 32%, #FFFFFF 0%, #FCFDFD 54%, #E1E4E7 100%);
- box-shadow: inset 0px 1px 0px 2px rgba(255, 255, 255, 0.9046), inset 0px 3px 6px 0px rgba(0, 0, 0, 0.0851);
- }
- }
- }
- .top-right {
- width: 62%;
- height: 100%;
- border-radius: 29px;
- opacity: 1;
- background: #ffffff;
- box-sizing: border-box;
- border: 0.55rem solid #13ED84;
- display: flex;
- align-items: center;
- justify-content: center;
- flex-wrap: wrap;
- position: relative;
- .time {
- width: 28vh;
- height: 28vh;
- line-height: 28vh;
- border-radius: 50%;
- color: #FF9402;
- font-size: 11vh;
- text-align: center;
- background-image: url("@/assets/images/test/time.png");
- background-position: center;
- background-repeat: no-repeat;
- background-size: 100% 100%;
- position: absolute;
- right: -1.5vh;
- top: -11vh;
- font-family: 'Saira-BlackItalic';
- }
- .tips {
- display: flex;
- justify-content: center;
- align-items: center;
- height: 100%;
- img {
- max-height: 80%;
- max-height: 80%;
- }
- }
- .complete {
- padding-top: 5vh;
- padding-left: 20%;
- width: 100%;
- }
- .scoreBox {
- height: 10vh;
- color: #1A293A;
- display: flex;
- align-items: center;
- margin-bottom: 5vh;
- .score {
- font-size: 7.178rem;
- font-family: 'Saira-BlackItalic';
- }
- .unit {
- font-size: 2rem;
- margin-left: 10px;
- }
- }
- .fractionViolation {
- height: 10vh;
- display: flex;
- align-items: center;
- margin-bottom: 5vh;
- .fraction {
- width: 40%;
- height: 11vh;
- line-height: 11vh;
- border-radius: 5.5vh;
- display: flex;
- align-items: center;
- justify-content: center;
- background: linear-gradient(138deg, #38536C 21%, #1A293A 75%);
- box-shadow: inset 0px 1px 13px 0px rgba(255, 255, 255, 0.9452);
- .lable {
- font-size: 1.93rem;
- color: #13ED84;
- }
- .value {
- font-size: 6.62rem;
- color: #00FFE8;
- font-family: 'Saira-BlackItalic';
- }
- }
- .violation {
- height: 8vh;
- line-height: 8vh;
- border-radius: 4vh;
- box-sizing: border-box;
- border: 0.25rem solid #ED7905;
- display: flex;
- align-items: center;
- margin-left: 11px;
- .lable {
- font-size: 1.2rem;
- color: #ffffff;
- width: 6vh;
- height: 6vh;
- line-height: 6vh;
- background: #ED7905;
- border-radius: 50%;
- margin: 0 1vh;
- text-align: center;
- }
- .value {
- font-size: 3.2rem;
- color: #ED7905;
- font-family: 'Saira-BlackItalic';
- }
- }
- }
- .btn {
- font-size: 2.21rem;
- color: #FFFFFF;
- text-align: center;
- width: 50%;
- line-height: 8vh;
- line-height: 8vh;
- border-radius: 15px;
- opacity: 1;
- background: radial-gradient(159% 126% at 5% 93%, #F99F02 0%, #ED7905 100%);
- box-shadow: 3px 6px 4px 1px rgba(0, 0, 0, 0.1874), inset 0px 1px 0px 2px rgba(255, 255, 255, 0.5577);
- cursor: pointer;
- }
- }
- i {
- width: 4vw;
- height: 4vw;
- display: block;
- position: absolute;
- top: 50%;
- left: 37.5%;
- margin-top: calc(4vw * -0.5);
- margin-left: calc(4vw * -0.5);
- background-image: url("@/assets/images/test/yuan.png");
- background-position: center;
- background-repeat: no-repeat;
- background-size: 100% 100%;
- border-radius: 50%;
- flex-shrink: 0;
- transition: all 0.5s;
- }
- }
- .main-left-bottom {
- display: flex;
- justify-content: space-between;
- height: calc(100% - 55.8% - 3vh);
- overflow: hidden;
- .bottom-left {
- width: 58%;
- padding-right: 1rem;
- display: flex;
- flex-direction: column;
- .tips {
- height: 2.8vh;
- img {
- height: 100%;
- }
- }
- .pic {
- text-align: center;
- width: 100%;
- height: 100%;
- display: flex;
- justify-content: center;
- overflow: hidden;
- img {
- max-width: 100%;
- max-height: 100%;
- }
- }
- }
- .bottom-right {
- width: 41%;
- height: 100%;
- overflow-y: scroll;
- color: #F9F9F9;
- font-size: 1.1rem;
- line-height: 1.6rem;
- &::-webkit-scrollbar {
- width: 10px;
- }
- &::-webkit-scrollbar-thumb {
- border-width: 2px;
- border-radius: 4px;
- border-style: dashed;
- border-color: transparent;
- background-color: rgba(26, 62, 78, 0.9);
- background-clip: padding-box;
- }
- &::-webkit-scrollbar-button:hover {
- border-radius: 6px;
- background: rgba(26, 62, 78, 1);
- }
- }
- }
- }
- .main-right {
- width: 27%;
- border-radius: 1.6rem;
- background: linear-gradient(29deg, #092941 -82%, #2A484B 94%);
- box-shadow: inset 0px 1px 0px 2px rgba(255, 255, 255, 0.4);
- display: flex;
- flex-direction: column;
- overflow: hidden;
- .title {
- height: 7.05vh;
- line-height: 7.05vh;
- width: 100%;
- text-align: center;
- color: #1A293A;
- font-size: 1.65rem;
- background: radial-gradient(120% 126% at 5% 93%, #8EFFA9 0%, #07FFE7 100%);
- }
- ul {
- height: 100%;
- overflow-y: scroll;
- li {
- border-bottom: 1px solid #48677E;
- padding: 8px 30px;
- display: flex;
- justify-content: space-between;
- align-items: center;
- cursor: pointer;
- &:hover {
- background: rgba(255, 255, 255, 0.4);
- }
- .left {
- display: flex;
- .pic {
- width: 7.5vh;
- height: 7.5vh;
- border-radius: 50%;
- display: flex;
- justify-content: center;
- align-items: center;
- overflow: hidden;
- box-sizing: border-box;
- border: 1px solid rgba(255, 255, 255, 0.5);
- margin-right: 13px;
- img {
- width: 100%;
- }
- }
- .txt {
- display: flex;
- align-items: center;
- .name {
- color: #F9F9F9;
- font-size: 1.38rem;
- }
- .className {
- color: #13ED84;
- font-size: 1.1rem;
- }
- }
- }
- .right {
- display: flex;
- font-weight: bold;
- align-items: center;
- .score {
- color: #ffffff;
- font-size: 1.1rem;
- font-family: 'Saira-ExtraBold';
- }
- .unit {
- color: #ffffff;
- font-size: 0.8rem;
- margin-left: 2px;
- }
- }
- }
- &::-webkit-scrollbar {
- width: 0px;
- }
- &::-webkit-scrollbar-thumb {
- border-width: 2px;
- border-radius: 4px;
- border-style: dashed;
- border-color: transparent;
- background-color: rgba(216, 216, 216, 0.8);
- background-clip: padding-box;
- }
- &::-webkit-scrollbar-button:hover {
- border-radius: 6px;
- background: rgba(216, 216, 216, 0.8);
- }
- }
- .erweima {
- text-align: center;
- padding: 1vh 0;
- img {
- width: 5rem;
- }
- span {
- display: block;
- color: #FFFFFF;
- font-size: 1.1rem;
- padding-top: 3px;
- }
- }
- }
- }
- .chengji {
- font-family: "Saira Black";
- }
- </style>
|