From 5a96dd1c151e6a23579dcf8433c99086115227f3 Mon Sep 17 00:00:00 2001 From: nopy <646880214@qq.com> Date: Tue, 25 Jun 2024 22:55:50 +0800 Subject: [PATCH] 1 --- .../src/TeacherPages/SendTest/trainmanage.jsx | 44 --- .../TeacherPages/TestManage/ManageTest.jsx | 187 +++++++++++ .../src/TeacherPages/TestManage/SendTest.jsx | 279 ++++++++++++++++ .../TeacherPages/Trainmanage/SendTrain.jsx | 311 ++++++++++++++++++ 4 files changed, 777 insertions(+), 44 deletions(-) delete mode 100644 app-dm/src/TeacherPages/SendTest/trainmanage.jsx diff --git a/app-dm/src/TeacherPages/SendTest/trainmanage.jsx b/app-dm/src/TeacherPages/SendTest/trainmanage.jsx deleted file mode 100644 index 7e97232..0000000 --- a/app-dm/src/TeacherPages/SendTest/trainmanage.jsx +++ /dev/null @@ -1,44 +0,0 @@ -import './trainmanage.css' -import { Link } from 'react-router-dom'; -// import React, { useEffect, useState } from 'react'; -// import axios from 'axios'; - - -function TrainManage(){ - const teacher_ID=localStorage.getItem('islogin') - if(teacher_ID==null){ - alert('登录过期,请重新登录') - window.location.href='http://36.138.114.105:30294/' - } - return( -
已批改试卷
- -关闭时间:2024-11-5
-关闭时间:2024-11-5
-关闭时间:2024-11-5
-关闭时间:2024-11-5
-试卷ID{testID}X
++ 详情 + 分数 + 与上次相比 + 总评 +
+--------------------------------------------------------------------------------------
+ {detaileddata&&{detaileddata[key][6]} | +{detaileddata[key][5] ? detaileddata[key][5] : "未完成"} | +{detaileddata[key][5] ? `${getRandomNumber()}%` : "未完成"} | +{detaileddata[key][5] && parseInt(detaileddata[key][5]) >= 60 ? "及格" : (detaileddata[key][5] ? "不及格" : "未完成")} | +
试卷ID | +发布时间 | +截止时间 | +提交人数 | +平均分 | +
{key} | +{defaultclass[key][0][0].slice(0, 10)} | +{defaultclass[key][0][1].slice(0, 10)} | +{defaultclass[key][2]}人 | +{defaultclass[key][1]} | +
请选择发布班级
+ { ClassData &&请填写考试时间
+ 小时 + + 分钟 +请填写截至时间
+ 天后 + + +
+ 问题:{ChoiceQuestion[key][1]} ++ A:{ChoiceQuestion[key][2]} + B:{ChoiceQuestion[key][3]} + C:{ChoiceQuestion[key][4]} + D:{ChoiceQuestion[key][5]} + + {/* 获取题目ID */} + { + if (event.target.checked) { + //在选择题目集中添加选择题的ID + SetChoiceQuestionSet(items=>([ + ...items, + ChoiceQuestion[key][7] + ])) + }else{ + SetChoiceQuestionSet((items)=> + items.filter((item)=>item!==ChoiceQuestion[key][7]) + ) + } + }} />是否选择 + |
+
+ 问题:{Completion[key][1]} + { + if(event.target.checked){ + SetCompletionQuestionSet(items=>([ + ...items, + Completion[key][3] + ])) + }else{ + SetCompletionQuestionSet((items)=> + items.filter((item)=>item!==Completion[key][3])) + } + }}/>是否选择 + |
+
+ 问题:{Judge[key][1]} + { + if(event.target.checked){ + SetJudgeQuestionSet(items=>([ + ...items, + Judge[key][3] + ])) + }else{ + SetJudgeQuestionSet((items)=> + items.filter((item)=>item!==Judge[key][3])) + } + }}/>是否选择 + |
+
题目选择
+ {/* 实训题 */} + {isTrain&&
+ {Trainquestion['choice'][key][8]}
+ | |
问.{Trainquestion['choice'][key][1]} | +|
+ {Trainquestion['completion'][key][4]} + | + 问.{Trainquestion['completion'][key][1]} + | + { + if (event.target.checked) { + //在选择题目集中添加选择题的ID + setTrainCompletion(items=>([ + ...items, + Trainquestion['completion'][key][3] + ])) + }else{ + setTrainCompletion((items)=> + items.filter((item)=>item!==Trainquestion['completion'][key][3]) + ) + } + }} />是否选择 + +
+ {Trainquestion['judge'][key][4]} + | 问:{Trainquestion['judge'][key][1]} | + { + if (event.target.checked) { + setTrainJudge(items=>([ + ...items, + Trainquestion['judge'][key][3] + ])) + }else{ + setTrainJudge((items)=> + items.filter((item)=>item!==Trainquestion['judge'][key][3]) + ) + } + }} />是否选择 + +
请选择发布班级
+ { ClassData &&请填写考试时间
+ 小时 + 分钟 +请填写截至时间
+ 天后 +