import React, {Component} from "react";
import {WordsBtn} from 'educoder';
import { Form, Select, Input, Button,Checkbox,Upload,Icon,message,Modal, Table, Divider,InputNumber, Tag,DatePicker,Radio,Tooltip,Spin} from "antd";
import {Link,Switch,Route,Redirect} from 'react-router-dom';
import axios from 'axios';
import ShixunCustomsPass from "./Shixunworkdetails/ShixunCustomsPass";
import '../css/members.css';
import "../common/formCommon.css";
import '../css/Courses.css';
import './style.css';
class ShixunWorkDetails extends Component {
constructor(props) {
super(props);
this.state = {
data:undefined,
spinning:true
}
}
componentDidMount() {
this.setState({
spinning:true
})
let homeworkid=this.props.match.params.homeworkid;
let userid=this.props.match.params.userid;
let url = "/homework_commons/"+homeworkid+"/code_review_detail.json";
axios.get(url,{
params: {
user_id:userid,
}
}).then((result) => {
if (result.status === 200) {
this.setState({
data:result.data,
spinning:false
})
}
}).catch((error) => {
console.log(error)
})
let query = this.props.location.pathname;
const type = query.split('/');
this.setState({
shixuntypes:type[3]
})
}
goback=(sum)=>{
// let{data}=this.state
// if(sum===1){
// window.location.href = "/courses/"+data.course_id+"/students";
// }else{
// window.history.go(-1)
// }
this.props.history.goBack()
}
render() {
let{data}=this.state;
return (
{data&&data.course_name}
>
实训作业
>
*/} // {/**/} // {/**/} // {/**/} // {/**/} // {/*第{item.position}关*/} // {/**/} // {/*{item.subject}*/} // {/**/} // {/**/} // {/*
*/} // {/**/} // {/*最近通过的代码*/} // {/*{item.path}*/} // {/*
*/} // // {/*