|
|
|
@ -81,8 +81,8 @@ class ShixunHomeworkPage extends Component {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
confirmysl(url) {
|
|
|
|
|
this.refs.DownloadMessage.confirmysl(url);
|
|
|
|
|
confirmysl(child,url) {
|
|
|
|
|
child.confirmysl(url);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
onRef = (ref) => {
|
|
|
|
@ -91,33 +91,40 @@ class ShixunHomeworkPage extends Component {
|
|
|
|
|
this.state.child= ref
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
homeworkendss(){
|
|
|
|
|
// console.log(this.contentMdRef.current);
|
|
|
|
|
homeworkendss(child){
|
|
|
|
|
// console.log(child);
|
|
|
|
|
// // console.log(this.refs.childModel);
|
|
|
|
|
// console.log(this.state.child);
|
|
|
|
|
|
|
|
|
|
// .homeworkends();
|
|
|
|
|
// console.log(child);
|
|
|
|
|
child.homeworkends();
|
|
|
|
|
//
|
|
|
|
|
}
|
|
|
|
|
homeworkstarts(){
|
|
|
|
|
homeworkstarts(child){
|
|
|
|
|
// console.log(this.contentMdRef.current);
|
|
|
|
|
// console.log(this.state.child);
|
|
|
|
|
child.homeworkstart();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// .homeworkstart();
|
|
|
|
|
}
|
|
|
|
|
workshowmodels(){
|
|
|
|
|
workshowmodels(child){
|
|
|
|
|
// console.log(this.contentMdRef.current)
|
|
|
|
|
// console.log(this.state.child);
|
|
|
|
|
// console.log(this.child);
|
|
|
|
|
child.workshowmodel();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// .workshowmodel();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
bindRef = ref => { this.child = ref }
|
|
|
|
|
///////////////教师截止
|
|
|
|
|
|
|
|
|
|
render() {
|
|
|
|
|
let {tab, teacherdata, jobsettingsdata} = this.state;
|
|
|
|
|
|
|
|
|
|
const isAdmin = this.props.isAdmin();
|
|
|
|
|
// console.log("126");
|
|
|
|
|
// console.log(this.child);/
|
|
|
|
|
return (
|
|
|
|
|
<div className="newMain clearfix ">
|
|
|
|
|
<div className={"educontent mb20"} style={{width: "1200px"}}>
|
|
|
|
@ -208,27 +215,27 @@ class ShixunHomeworkPage extends Component {
|
|
|
|
|
导出<i className="iconfont icon-xiajiantou font-12 ml2"></i>
|
|
|
|
|
<ul className="drop_down_menu" style={{"right": "-0px", "left": "unset", "height": "auto"}}>
|
|
|
|
|
<li><a
|
|
|
|
|
onClick={() => this.confirmysl(`/zip/shixun_report?homework_common_id=${this.props.match.params.homeworkid}&work_status=${this.state.course_groupyslstwo}&course_group=${this.state.checkedValuesineinfo}&search=${this.state.searchtext}`)}>实训报告</a>
|
|
|
|
|
onClick={(child) => this.confirmysl(this.child,`/zip/shixun_report?homework_common_id=${this.props.match.params.homeworkid}&work_status=${this.state.course_groupyslstwo}&course_group=${this.state.checkedValuesineinfo}&search=${this.state.searchtext}`)}>实训报告</a>
|
|
|
|
|
</li>
|
|
|
|
|
<li><a
|
|
|
|
|
onClick={() => this.confirmysl(`/homework_commons/${this.props.match.params.homeworkid}/works_list.xlsx?group_id=${this.state.checkedValuesineinfo}&search=${this.state.searchtext}`)}>学生成绩</a>
|
|
|
|
|
onClick={(child) => this.confirmysl(this.child,`/homework_commons/${this.props.match.params.homeworkid}/works_list.xlsx?group_id=${this.state.checkedValuesineinfo}&search=${this.state.searchtext}`)}>学生成绩</a>
|
|
|
|
|
</li>
|
|
|
|
|
|
|
|
|
|
</ul>
|
|
|
|
|
</li> : ""}
|
|
|
|
|
{this.props.isAdmin() ?
|
|
|
|
|
teacherdata && teacherdata.end_immediately === true ?
|
|
|
|
|
<a className="fr color-blue font-16" onClick={this.homeworkendss}>立即截止</a>
|
|
|
|
|
<a className="fr color-blue font-16" onClick={(child)=>this.homeworkendss(this.child)}>立即截止</a>
|
|
|
|
|
: ""
|
|
|
|
|
: ""}
|
|
|
|
|
{this.props.isAdmin() ?
|
|
|
|
|
teacherdata && teacherdata.publish_immediately === true ?
|
|
|
|
|
<a className="fr color-blue font-16" onClick={this.homeworkstarts}>立即发布</a>
|
|
|
|
|
<a className="fr color-blue font-16" onClick={(child)=>this.homeworkstarts(this.child)}>立即发布</a>
|
|
|
|
|
: ""
|
|
|
|
|
: ""}
|
|
|
|
|
{this.props.isAdmin() ?
|
|
|
|
|
teacherdata && teacherdata.code_review === true ?
|
|
|
|
|
<a className="fr color-blue font-16" onClick={this.workshowmodels}>代码查重</a>
|
|
|
|
|
<a className="fr color-blue font-16" onClick={(child)=>this.workshowmodels(this.child)}>代码查重</a>
|
|
|
|
|
: "" : ""}
|
|
|
|
|
{this.state.view_report === true ? <Link className="fr color-blue font-16" target={"_blank"}
|
|
|
|
|
to={`/courses/${this.props.match.params.coursesId}/${this.state.shixuntypes}/${this.props.match.params.homeworkid}/shixun_work_report`}>
|
|
|
|
@ -252,21 +259,21 @@ class ShixunHomeworkPage extends Component {
|
|
|
|
|
{
|
|
|
|
|
// 教师列表
|
|
|
|
|
parseInt(tab) === 0 ? (isAdmin === true ?
|
|
|
|
|
<Listofworks {...this.props} {...this.state} onRef={this.onRef}
|
|
|
|
|
<Listofworks triggerRef={this.bindRef} {...this.props} {...this.state}
|
|
|
|
|
Getdataback={(jobsettingsdata, teacherdata) => this.Getdataback(jobsettingsdata, teacherdata)}></Listofworks>
|
|
|
|
|
:
|
|
|
|
|
<Listofworksstudentone ref={this.contentMdRef} {...this.props} {...this.state} onRef={(ref)=>{ this.child = ref}}
|
|
|
|
|
<Listofworksstudentone triggerRef={this.bindRef} {...this.props} {...this.state}
|
|
|
|
|
Getdataback={(jobsettingsdata, teacherdata) => this.Getdataback(jobsettingsdata, teacherdata)}></Listofworksstudentone>)
|
|
|
|
|
:
|
|
|
|
|
parseInt(tab) === 1 ?
|
|
|
|
|
<Workquestionandanswer ref={this.contentMdRef} {...this.props} {...this.state} onRef={(ref)=>{ this.child = ref}}
|
|
|
|
|
<Workquestionandanswer triggerRef={this.bindRef} {...this.props} {...this.state}
|
|
|
|
|
Getdataback={(jobsettingsdata, teacherdata) => this.Getdataback(jobsettingsdata, teacherdata)}></Workquestionandanswer>
|
|
|
|
|
:
|
|
|
|
|
parseInt(tab) === 2 ?
|
|
|
|
|
<ShixunStudentWork ref={this.contentMdRef} {...this.props} {...this.state} onRef={(ref)=>{ this.child = ref}}
|
|
|
|
|
<ShixunStudentWork triggerRef={this.bindRef} {...this.props} {...this.state}
|
|
|
|
|
Getdataback={(jobsettingsdata, teacherdata) => this.Getdataback(jobsettingsdata, teacherdata)}></ShixunStudentWork>
|
|
|
|
|
:
|
|
|
|
|
<Trainingjobsetting ref={this.contentMdRef} {...this.props} {...this.state} onRef={(ref)=>{ this.child = ref}}
|
|
|
|
|
<Trainingjobsetting triggerRef={this.bindRef} {...this.props} {...this.state}
|
|
|
|
|
Getdataback={(jobsettingsdata, teacherdata) => this.Getdataback(jobsettingsdata, teacherdata)}></Trainingjobsetting>
|
|
|
|
|
}
|
|
|
|
|
</div>
|
|
|
|
|