qwe
This commit is contained in:
parent
0573e4f702
commit
abe873d7bb
|
@ -9,7 +9,7 @@ In the project directory, you can run:
|
|||
### `npm start`
|
||||
|
||||
Runs the app in the development mode.\
|
||||
Open [http://localhost:3000](http://localhost:3000) to view it in your browser.
|
||||
Open [http://36.138.114.105:30294/signin](http://36.138.114.105:30294/signin) to view it in your browser.
|
||||
|
||||
The page will reload when you make changes.\
|
||||
You may also see any lint errors in the console.
|
||||
|
|
|
@ -12,7 +12,7 @@ function Marking(){
|
|||
const currentTime = new Date().toLocaleString()
|
||||
if(teacher_ID==null){
|
||||
alert('登录过期,请重新登录')
|
||||
window.location.href='http://36.138.114.105:30294/'
|
||||
window.location.href='http://36.138.114.105:30294/signin'
|
||||
}
|
||||
|
||||
const [istrue,setistrue]=useState(false)
|
||||
|
|
|
@ -24,7 +24,7 @@ function StudentLink(){
|
|||
const submit=()=>{
|
||||
sumbitScore()
|
||||
alert('批改成功')
|
||||
window.location.href='http://localhost:3000/teacher/mark'
|
||||
window.location.href='http://36.138.114.105:30294/teacher/mark'
|
||||
}
|
||||
|
||||
const [TestLink,setTestLink]=useState()
|
||||
|
|
|
@ -9,7 +9,7 @@ function TeacherPage() {
|
|||
const teacher_ID = localStorage.getItem('islogin')
|
||||
if(teacher_ID==null){
|
||||
alert('登录过期,请重新登录')
|
||||
window.location.href='http://36.138.114.105:30294/'
|
||||
window.location.href='http://36.138.114.105:30294/signin'
|
||||
}
|
||||
const [classData, setClassData] = useState({});
|
||||
const log=(key)=>{
|
||||
|
|
|
@ -25,7 +25,7 @@
|
|||
const teacher_ID=localStorage.getItem('islogin')
|
||||
if(teacher_ID==null){
|
||||
alert('登录过期,请重新登录')
|
||||
window.location.href='http://36.138.114.105:30294/'
|
||||
window.location.href='http://36.138.114.105:30294/signin'
|
||||
}
|
||||
|
||||
//学生表格
|
||||
|
|
|
@ -38,20 +38,6 @@ function HeaderNav() {
|
|||
{/* <div>
|
||||
头像
|
||||
</div> */}
|
||||
<ul className="narbar-nav mr-auto">
|
||||
<li className='nav-item'>
|
||||
<Link className='nav-link' to='/'>学生</Link>
|
||||
</li>
|
||||
<li className='nav-item'>
|
||||
<Link className='nav-link' to='/teacher'>教师</Link>
|
||||
</li>
|
||||
<li className='nav-item'>
|
||||
<Link className='nav-link' to='/signup'>注册</Link>
|
||||
</li>
|
||||
<li className='nav-item'>
|
||||
<Link className='nav-link' to='/signin'>登录</Link>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div className='left-nav-li'>
|
||||
<ul>
|
||||
|
|
|
@ -14,7 +14,7 @@ function Home(){
|
|||
const [isChecked,setisChecked]=useState(false)
|
||||
const student_ID=localStorage.getItem('islogin')
|
||||
if(student_ID==null){
|
||||
window.location.href='http://localhost:3000/signin'
|
||||
window.location.href='http://36.138.114.105:30294/signin'
|
||||
alert('未登录,请前往登录')
|
||||
}
|
||||
|
||||
|
|
|
@ -11,7 +11,7 @@ function SubjectPage(){
|
|||
const student_ID=localStorage.getItem('islogin')
|
||||
if(student_ID==null){
|
||||
alert('登录过期,请重新登录')
|
||||
window.location.href='http://36.138.114.105:30294/'
|
||||
window.location.href='http://36.138.114.105:30294/signin'
|
||||
}
|
||||
//点击li弹出图像窗口
|
||||
const [SubjectModal,setSubjectModal] = useState(false);
|
||||
|
@ -54,10 +54,6 @@ function SubjectPage(){
|
|||
};
|
||||
|
||||
|
||||
const click=()=>{
|
||||
console.log(score);
|
||||
}
|
||||
|
||||
//获取历史实训记录
|
||||
const [HistoryTrain,setHisToryTrain]=useState()
|
||||
|
||||
|
@ -86,22 +82,14 @@ function SubjectPage(){
|
|||
<img src={Computer} alt="" width='35px' height='35px'/>
|
||||
<p>
|
||||
<p className='p'>{eval(HistoryTrain[key][1][11])}</p>
|
||||
|
||||
<span>{HistoryTrain[key][1][5]}</span>
|
||||
</p>
|
||||
</li>
|
||||
))}
|
||||
</ul>
|
||||
</div>}
|
||||
<button onClick={click}>万能的测试按钮</button>
|
||||
<div className='right-vertical-nav'>
|
||||
<p>课程</p>
|
||||
<ul>
|
||||
<li>达梦数据库</li>
|
||||
<li className='li-deep'>数据结构</li>
|
||||
<li>python</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
{SubjectModal && (
|
||||
<div className='outbox-test-analyse'>
|
||||
|
@ -115,8 +103,9 @@ function SubjectPage(){
|
|||
{/* 图表或者文字分析 */}
|
||||
<ul>
|
||||
<li>总得分:{parseInt(PieData['datasets'][0]['data'][0])+parseInt(PieData['datasets'][0]['data'][1])}/{score}</li>
|
||||
<li>分析:{parseInt(PieData['datasets'][0]['data'][0])>parseInt(PieData['datasets'][0]['data'][1]) ? '基础题得分略低':'实训题得分略低'}</li>
|
||||
<li>建议:{parseInt(PieData['datasets'][0]['data'][0])>parseInt(PieData['datasets'][0]['data'][1]) ? '巩固基础,稳步提升':'加强实训,手动操作'}</li>
|
||||
<li>分析:{parseInt(PieData['datasets'][0]['data'][0])>parseInt(PieData['datasets'][0]['data'][1]) ? '基础题得分略低':'提高实训得分需优化学习方法与题目理解。'}</li>
|
||||
<br />
|
||||
<li>老师建议:{parseInt(PieData['datasets'][0]['data'][0])>parseInt(PieData['datasets'][0]['data'][1]) ? '巩固基础,稳步提升':'加强HTML语法'}</li>
|
||||
</ul>
|
||||
</div>}
|
||||
</div>
|
||||
|
|
|
@ -8,10 +8,9 @@ import moment from 'moment';
|
|||
// 首页 题目集
|
||||
function SubjectPage(){
|
||||
const student_ID=localStorage.getItem('islogin')
|
||||
|
||||
if(student_ID==null){
|
||||
alert('登录过期,请重新登录')
|
||||
window.location.href='http://36.138.114.105:30294/'
|
||||
window.location.href='http://36.138.114.105:30294/signin'
|
||||
}
|
||||
const [testdata,settestdata]=useState('')
|
||||
const [FalseData,setFalseData]=useState('')
|
||||
|
|
|
@ -49,7 +49,7 @@ function SubjectPage(){
|
|||
const student_ID=localStorage.getItem('islogin')
|
||||
if(student_ID==null){
|
||||
alert('登录过期,请重新登录')
|
||||
window.location.href='http://36.138.114.105:30294/'
|
||||
window.location.href='http://36.138.114.105:30294/signin'
|
||||
}
|
||||
const [title,setTitle]=useState()
|
||||
// 获取实训标题
|
||||
|
|
|
@ -26,7 +26,7 @@ import Marking from '../TeacherPages/MarkingPages/Marking';
|
|||
import SendTrain from '../TeacherPages/Trainmanage/SendTrain'
|
||||
import TrainManage from '../TeacherPages/Trainmanage/Trainmanage'
|
||||
import StudentLink from '../TeacherPages/MarkingPages/StudentLink';
|
||||
import Test from '../TeacherPages/TestManage/Test.tsx'
|
||||
import Test from '../TeacherPages/TestManage/Test'
|
||||
|
||||
|
||||
// 定义一个组件来包裹除了特定页面(exam)外的所有页面使其有导航
|
||||
|
|
Loading…
Reference in New Issue