|
|
|
@ -6,7 +6,7 @@ import axios from 'axios';
|
|
|
|
|
import moment from 'moment';
|
|
|
|
|
import HomeworkModal from "../../coursesPublic/HomeworkModal";
|
|
|
|
|
import Modals from '../../../modals/Modals';
|
|
|
|
|
|
|
|
|
|
import DownloadMessage from '../../../modals/DownloadMessage';
|
|
|
|
|
import CoursesListType from '../../coursesPublic/CoursesListType';
|
|
|
|
|
|
|
|
|
|
import ModulationModal from "../../coursesPublic/ModulationModal";
|
|
|
|
@ -612,7 +612,51 @@ class GraduationTaskssettinglist extends Component{
|
|
|
|
|
this.seacthdata(teacher_comment,task_status,course_group,cross_comment,order,b_order,search,pageNumber);
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
/// 确认是否下载
|
|
|
|
|
confirmysl(url){
|
|
|
|
|
|
|
|
|
|
let {teacher_comment, task_status, course_group, cross_comment, order, b_order, search,page} =this.state;
|
|
|
|
|
|
|
|
|
|
axios.get(url,{
|
|
|
|
|
teacher_comment:teacher_comment,
|
|
|
|
|
task_status:task_status,
|
|
|
|
|
course_group:course_group,
|
|
|
|
|
cross_comment:cross_comment,
|
|
|
|
|
order:order,
|
|
|
|
|
b_order:b_order,
|
|
|
|
|
search:search,
|
|
|
|
|
}).then((response) => {
|
|
|
|
|
if(response.data.status&&response.data.status===-1){
|
|
|
|
|
|
|
|
|
|
}else if(response.data.status&&response.data.status===-2){
|
|
|
|
|
if(response.data.messages === "100"){
|
|
|
|
|
// 已超出文件导出的上限数量(100 ),建议:
|
|
|
|
|
|
|
|
|
|
this.setState({
|
|
|
|
|
DownloadType:true,
|
|
|
|
|
DownloadMessageval:100
|
|
|
|
|
})
|
|
|
|
|
}else {
|
|
|
|
|
//因附件资料超过500M
|
|
|
|
|
this.setState({
|
|
|
|
|
DownloadType:true,
|
|
|
|
|
DownloadMessageval:500
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
}else {
|
|
|
|
|
this.props.showNotification(`正在下载中`);
|
|
|
|
|
window.open("/api"+url, '_blank');
|
|
|
|
|
}
|
|
|
|
|
}).catch((error) => {
|
|
|
|
|
console.log(error)
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
Downloadcal=()=>{
|
|
|
|
|
this.setState({
|
|
|
|
|
DownloadType:false,
|
|
|
|
|
DownloadMessageval:undefined
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
render(){
|
|
|
|
|
|
|
|
|
|
let {coursename,coursesearch,taskname,taskid,taskslistdata,data,page,limit,teacher_comment,task_status,cross_comment,search,loadingstate,
|
|
|
|
@ -959,7 +1003,17 @@ class GraduationTaskssettinglist extends Component{
|
|
|
|
|
Cancel={this.Cancelvisible}
|
|
|
|
|
categoryid={taskslistdata.work_id}
|
|
|
|
|
setupdate={this.setupdate}
|
|
|
|
|
/>:""} {taskslistdata&&taskslistdata?
|
|
|
|
|
/>:""}
|
|
|
|
|
|
|
|
|
|
<DownloadMessage
|
|
|
|
|
{...this.props}
|
|
|
|
|
value={this.state.DownloadMessageval}
|
|
|
|
|
modalCancel={this.Downloadcal}
|
|
|
|
|
modalsType={this.state.DownloadType}
|
|
|
|
|
/>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
{taskslistdata&&taskslistdata?
|
|
|
|
|
// 教师列表
|
|
|
|
|
this.props.isAdmin()?<div className="newMain clearfix">
|
|
|
|
|
<div className={"educontent mb20"}>
|
|
|
|
@ -1025,8 +1079,8 @@ class GraduationTaskssettinglist extends Component{
|
|
|
|
|
{this.props.isAdmin()? <li className="li_line drop_down fr color-blue font-16 mr20 mt20" style={{"paddingLeft":"0px"}}>
|
|
|
|
|
导出<i className="iconfont icon-xiajiantou font-12 ml2"></i>
|
|
|
|
|
<ul className="drop_down_menu" style={{"right":"-34px","left":"unset","height":"auto"}}>
|
|
|
|
|
<li><a href={"/api/graduation_tasks/"+task_Id+"/tasks_list.xlsx"} className="color-dark">学生成绩</a></li>
|
|
|
|
|
<li><a href={"/api/graduation_tasks/"+task_Id+"/tasks_list.zip"} className="color-dark">作品附件</a></li>
|
|
|
|
|
<li><a onClick={()=>this.confirmysl("/api/graduation_tasks/"+task_Id+"/tasks_list.xlsx")} className="color-dark">学生成绩</a></li>
|
|
|
|
|
<li><a onClick={()=>this.confirmysl("/api/graduation_tasks/"+task_Id+"/tasks_list.zip")} className="color-dark">作品附件</a></li>
|
|
|
|
|
</ul>
|
|
|
|
|
</li>:""}
|
|
|
|
|
|
|
|
|
|