|
|
@ -90,7 +90,7 @@ class Listofworksstudentone extends Component {
|
|
|
|
var data = {
|
|
|
|
var data = {
|
|
|
|
search: "",
|
|
|
|
search: "",
|
|
|
|
order: "",
|
|
|
|
order: "",
|
|
|
|
b_order: "asc",
|
|
|
|
b_order: "desc",
|
|
|
|
page: 1,
|
|
|
|
page: 1,
|
|
|
|
limit: 20,
|
|
|
|
limit: 20,
|
|
|
|
work_status: "",
|
|
|
|
work_status: "",
|
|
|
@ -107,6 +107,9 @@ class Listofworksstudentone extends Component {
|
|
|
|
publish_immediately: result.data.publish_immediately,
|
|
|
|
publish_immediately: result.data.publish_immediately,
|
|
|
|
end_immediately: result.data.end_immediately,
|
|
|
|
end_immediately: result.data.end_immediately,
|
|
|
|
id: result.data.id,
|
|
|
|
id: result.data.id,
|
|
|
|
|
|
|
|
work_efficiency: result.data.work_efficiency,
|
|
|
|
|
|
|
|
code_review: result.data.code_review,
|
|
|
|
|
|
|
|
challenges_count:result.data.challenges_count,
|
|
|
|
})
|
|
|
|
})
|
|
|
|
if (result.data.student_works === undefined || result.data.student_works === null || JSON.stringify(result.data.student_works) === "[]") {
|
|
|
|
if (result.data.student_works === undefined || result.data.student_works === null || JSON.stringify(result.data.student_works) === "[]") {
|
|
|
|
this.seacthdata();
|
|
|
|
this.seacthdata();
|
|
|
@ -154,6 +157,13 @@ class Listofworksstudentone extends Component {
|
|
|
|
task_status: result.data.task_status,
|
|
|
|
task_status: result.data.task_status,
|
|
|
|
course_group_info: result.data.course_group_info,
|
|
|
|
course_group_info: result.data.course_group_info,
|
|
|
|
student_works: result.data.student_works,
|
|
|
|
student_works: result.data.student_works,
|
|
|
|
|
|
|
|
loadingstate: false,
|
|
|
|
|
|
|
|
jobsettingsdata: result,
|
|
|
|
|
|
|
|
publish_immediately: result.data.publish_immediately,
|
|
|
|
|
|
|
|
work_efficiency: result.data.work_efficiency,
|
|
|
|
|
|
|
|
end_immediately: result.data.end_immediately,
|
|
|
|
|
|
|
|
code_review: result.data.code_review,
|
|
|
|
|
|
|
|
challenges_count:result.data.challenges_count,
|
|
|
|
})
|
|
|
|
})
|
|
|
|
if (result.data.student_works === undefined || result.data.student_works === null || JSON.stringify(result.data.student_works) === "[]") {
|
|
|
|
if (result.data.student_works === undefined || result.data.student_works === null || JSON.stringify(result.data.student_works) === "[]") {
|
|
|
|
this.seacthdata();
|
|
|
|
this.seacthdata();
|
|
|
@ -214,11 +224,15 @@ class Listofworksstudentone extends Component {
|
|
|
|
// updatetime:this.state.teacherdata.student_works[i].update_time,
|
|
|
|
// updatetime:this.state.teacherdata.student_works[i].update_time,
|
|
|
|
// updatetime:"",
|
|
|
|
// updatetime:"",
|
|
|
|
updatetime: timedata === "Invalid date" ? "--" : timedata,
|
|
|
|
updatetime: timedata === "Invalid date" ? "--" : timedata,
|
|
|
|
completion: this.state.teacherdata.complete_count === 4 ? "4/4" : this.state.teacherdata.complete_count === 3 ? "3/4" : this.state.teacherdata.complete_count === 2 ? "2/4" : this.state.teacherdata.complete_count === 1 ? "1/4" : this.state.teacherdata.complete_count === 0 ? "0" : 0,
|
|
|
|
completion: this.state.teacherdata.complete_count === null ? "0" :this.state.teacherdata.complete_count === undefined ? "0": this.state.teacherdata.complete_count,
|
|
|
|
levelscore: this.state.teacherdata.final_score,
|
|
|
|
levelscore: this.state.teacherdata.final_score,
|
|
|
|
efficiencyscore: this.state.teacherdata.eff_score,
|
|
|
|
efficiencyscore: this.state.teacherdata.eff_score,
|
|
|
|
finalscore: this.state.teacherdata.work_score,
|
|
|
|
finalscore: this.state.teacherdata.work_score,
|
|
|
|
operating: "查看",
|
|
|
|
operating: "查看",
|
|
|
|
|
|
|
|
late_penalty: this.state.teacherdata.late_penalty=== null?"0":this.state.teacherdata.student_works[i].late_penalty === undefined?"0":this.state.teacherdata.student_works[i].late_penalty,
|
|
|
|
|
|
|
|
ultimate_score:this.state.teacherdata.ultimate_score,
|
|
|
|
|
|
|
|
user_name: this.state.teacherdata.user_name,
|
|
|
|
|
|
|
|
user_login: this.state.teacherdata.user_login,
|
|
|
|
})
|
|
|
|
})
|
|
|
|
|
|
|
|
|
|
|
|
// }
|
|
|
|
// }
|
|
|
@ -253,11 +267,15 @@ class Listofworksstudentone extends Component {
|
|
|
|
// updatetime:this.state.teacherdata.student_works[i].update_time,
|
|
|
|
// updatetime:this.state.teacherdata.student_works[i].update_time,
|
|
|
|
// updatetime:"",
|
|
|
|
// updatetime:"",
|
|
|
|
updatetime: timedata === "Invalid date" ? "--" : timedata,
|
|
|
|
updatetime: timedata === "Invalid date" ? "--" : timedata,
|
|
|
|
completion: this.state.student_works[i].complete_count === 4 ? "4/4" : this.state.student_works[i].complete_count === 3 ? "3/4" : this.state.student_works[i].complete_count === 2 ? "2/4" : this.state.student_works[i].complete_count === 1 ? "1/4" : this.state.student_works[i].complete_count === 0 ? "0" : 0,
|
|
|
|
completion: this.state.teacherdata.student_works[i].complete_count === null ? "0" :this.state.teacherdata.student_works[i].complete_count === undefined ? "0": this.state.teacherdata.student_works[i].complete_count,
|
|
|
|
levelscore: this.state.student_works[i].final_score,
|
|
|
|
levelscore: this.state.student_works[i].final_score,
|
|
|
|
efficiencyscore: this.state.student_works[i].eff_score,
|
|
|
|
efficiencyscore: this.state.student_works[i].eff_score,
|
|
|
|
finalscore: this.state.student_works[i].work_score,
|
|
|
|
finalscore: this.state.student_works[i].work_score,
|
|
|
|
operating: "查看",
|
|
|
|
operating: "查看",
|
|
|
|
|
|
|
|
late_penalty: this.state.teacherdata.student_works[i].late_penalty=== null?"0":this.state.teacherdata.student_works[i].late_penalty === undefined?"0":this.state.teacherdata.student_works[i].late_penalty,
|
|
|
|
|
|
|
|
ultimate_score:this.state.teacherdata.student_works[i].ultimate_score,
|
|
|
|
|
|
|
|
user_name: this.state.teacherdata.student_works[i].user_name,
|
|
|
|
|
|
|
|
user_login: this.state.teacherdata.student_works[i].user_login,
|
|
|
|
})
|
|
|
|
})
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -310,11 +328,15 @@ class Listofworksstudentone extends Component {
|
|
|
|
// updatetime:this.state.teacherdata.student_works[i].update_time,
|
|
|
|
// updatetime:this.state.teacherdata.student_works[i].update_time,
|
|
|
|
// updatetime:"",
|
|
|
|
// updatetime:"",
|
|
|
|
updatetime: timedata === "Invalid date" ? "--" : timedata,
|
|
|
|
updatetime: timedata === "Invalid date" ? "--" : timedata,
|
|
|
|
completion: this.state.teacherdata.complete_count === 4 ? "4/4" : this.state.teacherdata.complete_count === 3 ? "3/4" : this.state.teacherdata.complete_count === 2 ? "2/4" : this.state.teacherdata.complete_count === 1 ? "1/4" : this.state.teacherdata.complete_count === 0 ? "0" : 0,
|
|
|
|
completion: this.state.teacherdata.complete_count === null ? "0" :this.state.teacherdata.complete_count === undefined ? "0": this.state.teacherdata.complete_count,
|
|
|
|
levelscore: this.state.teacherdata.final_score,
|
|
|
|
levelscore: this.state.teacherdata.final_score,
|
|
|
|
efficiencyscore: this.state.teacherdata.eff_score,
|
|
|
|
efficiencyscore: this.state.teacherdata.eff_score,
|
|
|
|
finalscore: this.state.teacherdata.work_score,
|
|
|
|
finalscore: this.state.teacherdata.work_score,
|
|
|
|
operating: "查看",
|
|
|
|
operating: "查看",
|
|
|
|
|
|
|
|
late_penalty: this.state.teacherdata.late_penalty=== null?"0":this.state.teacherdata.student_works[i].late_penalty === undefined?"0":this.state.teacherdata.student_works[i].late_penalty,
|
|
|
|
|
|
|
|
ultimate_score:this.state.teacherdata.ultimate_score,
|
|
|
|
|
|
|
|
user_name: this.state.teacherdata.user_name,
|
|
|
|
|
|
|
|
user_login: this.state.teacherdata.user_login,
|
|
|
|
})
|
|
|
|
})
|
|
|
|
|
|
|
|
|
|
|
|
// }
|
|
|
|
// }
|
|
|
@ -361,7 +383,8 @@ class Listofworksstudentone extends Component {
|
|
|
|
// console.log(JSON.stringify(result))
|
|
|
|
// console.log(JSON.stringify(result))
|
|
|
|
let datalist = [];
|
|
|
|
let datalist = [];
|
|
|
|
var game_list = result.data.game_list
|
|
|
|
var game_list = result.data.game_list
|
|
|
|
|
|
|
|
var boolgalist=true;
|
|
|
|
|
|
|
|
var experience=0;
|
|
|
|
for (var i = 0; i < game_list.length; i++) {
|
|
|
|
for (var i = 0; i < game_list.length; i++) {
|
|
|
|
|
|
|
|
|
|
|
|
datalist.push({
|
|
|
|
datalist.push({
|
|
|
@ -371,7 +394,11 @@ class Listofworksstudentone extends Component {
|
|
|
|
classroom: game_list[i].score,
|
|
|
|
classroom: game_list[i].score,
|
|
|
|
complete_status: game_list[i].complete_status,
|
|
|
|
complete_status: game_list[i].complete_status,
|
|
|
|
})
|
|
|
|
})
|
|
|
|
|
|
|
|
experience=game_list[i].complete_status+experience;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if(game_list[i].complete_status === 2 || game_list[i].complete_status===3){
|
|
|
|
|
|
|
|
boolgalist=false;
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
// console.log("viewtraining");
|
|
|
|
// console.log("viewtraining");
|
|
|
|
// console.log(datalist);
|
|
|
|
// console.log(datalist);
|
|
|
@ -379,7 +406,9 @@ class Listofworksstudentone extends Component {
|
|
|
|
this.setState({
|
|
|
|
this.setState({
|
|
|
|
viewtrainingdata: result.data,
|
|
|
|
viewtrainingdata: result.data,
|
|
|
|
visibles: true,
|
|
|
|
visibles: true,
|
|
|
|
game_list: datalist
|
|
|
|
game_list: datalist,
|
|
|
|
|
|
|
|
experience:experience,
|
|
|
|
|
|
|
|
boolgalist:boolgalist,
|
|
|
|
})
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}).catch((error) => {
|
|
|
|
}).catch((error) => {
|
|
|
@ -458,7 +487,13 @@ class Listofworksstudentone extends Component {
|
|
|
|
task_status: result.data.task_status,
|
|
|
|
task_status: result.data.task_status,
|
|
|
|
course_group_info: result.data.course_group_info,
|
|
|
|
course_group_info: result.data.course_group_info,
|
|
|
|
student_works: result.data.student_works,
|
|
|
|
student_works: result.data.student_works,
|
|
|
|
loadingstate: false
|
|
|
|
loadingstate: false,
|
|
|
|
|
|
|
|
jobsettingsdata: result,
|
|
|
|
|
|
|
|
publish_immediately: result.data.publish_immediately,
|
|
|
|
|
|
|
|
work_efficiency: result.data.work_efficiency,
|
|
|
|
|
|
|
|
end_immediately: result.data.end_immediately,
|
|
|
|
|
|
|
|
code_review: result.data.code_review,
|
|
|
|
|
|
|
|
challenges_count:result.data.challenges_count,
|
|
|
|
})
|
|
|
|
})
|
|
|
|
this.seacthdata();
|
|
|
|
this.seacthdata();
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -495,7 +530,7 @@ class Listofworksstudentone extends Component {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
render() {
|
|
|
|
render() {
|
|
|
|
let {visibles, game_list, limit, viewtrainingdata, teacherdata, page, data, jobsettingsdata, styletable, datas, order, loadingstate} = this.state;
|
|
|
|
let {visibles, game_list, limit,experience, boolgalist,viewtrainingdata, teacherdata, page, data, jobsettingsdata, styletable, datas, order, loadingstate} = this.state;
|
|
|
|
let columns = [
|
|
|
|
let columns = [
|
|
|
|
{
|
|
|
|
{
|
|
|
|
title: '序号',
|
|
|
|
title: '序号',
|
|
|
@ -639,10 +674,7 @@ class Listofworksstudentone extends Component {
|
|
|
|
align: "center",
|
|
|
|
align: "center",
|
|
|
|
render: (text, record) => (
|
|
|
|
render: (text, record) => (
|
|
|
|
<span>
|
|
|
|
<span>
|
|
|
|
<a style={{
|
|
|
|
<a style={{"color": '#07111B', "text-align": "center"}}>{record.completion+"/"+this.state.challenges_count}</a>
|
|
|
|
"color": '#9A9A9A',
|
|
|
|
|
|
|
|
"text-align": "center"
|
|
|
|
|
|
|
|
}}>{record.completion === undefined ? "--" : record.completion === "" ? "--" : record.completion}</a>
|
|
|
|
|
|
|
|
</span>
|
|
|
|
</span>
|
|
|
|
),
|
|
|
|
),
|
|
|
|
},
|
|
|
|
},
|
|
|
@ -719,6 +751,8 @@ class Listofworksstudentone extends Component {
|
|
|
|
viewtrainingdata={viewtrainingdata}
|
|
|
|
viewtrainingdata={viewtrainingdata}
|
|
|
|
game_list={game_list}
|
|
|
|
game_list={game_list}
|
|
|
|
visible={visibles}
|
|
|
|
visible={visibles}
|
|
|
|
|
|
|
|
experience={experience}
|
|
|
|
|
|
|
|
boolgalist={boolgalist}
|
|
|
|
Cancel={() => this.cancelModulationModels()}
|
|
|
|
Cancel={() => this.cancelModulationModels()}
|
|
|
|
/>
|
|
|
|
/>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
@ -851,6 +885,8 @@ class Listofworksstudentone extends Component {
|
|
|
|
viewtrainingdata={viewtrainingdata}
|
|
|
|
viewtrainingdata={viewtrainingdata}
|
|
|
|
game_list={game_list}
|
|
|
|
game_list={game_list}
|
|
|
|
visible={visibles}
|
|
|
|
visible={visibles}
|
|
|
|
|
|
|
|
experience={experience}
|
|
|
|
|
|
|
|
boolgalist={boolgalist}
|
|
|
|
Cancel={() => this.cancelModulationModels()}
|
|
|
|
Cancel={() => this.cancelModulationModels()}
|
|
|
|
/> : ""
|
|
|
|
/> : ""
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -925,7 +961,6 @@ class Listofworksstudentone extends Component {
|
|
|
|
pagination={false}
|
|
|
|
pagination={false}
|
|
|
|
loading={false}
|
|
|
|
loading={false}
|
|
|
|
showHeader={false}
|
|
|
|
showHeader={false}
|
|
|
|
scroll={{y: 240}}
|
|
|
|
|
|
|
|
/>}
|
|
|
|
/>}
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
{JSON.stringify(datas) !== "[]" ?
|
|
|
|
{JSON.stringify(datas) !== "[]" ?
|
|
|
|