diff --git a/public/react/src/modules/courses/exercise/Testpapersettinghomepage.js b/public/react/src/modules/courses/exercise/Testpapersettinghomepage.js
index 398a45228..f25f02d83 100644
--- a/public/react/src/modules/courses/exercise/Testpapersettinghomepage.js
+++ b/public/react/src/modules/courses/exercise/Testpapersettinghomepage.js
@@ -7,7 +7,7 @@ import '../css/members.css';
import '../css/busyWork.css';
import axios from 'axios';
import Modals from '../../modals/Modals';
-import DownloadMessage from '../../modals/DownloadMessage';
+import DownloadMessageysl from "../../modals/DownloadMessageysl";
import Studentshavecompletedthelist from './Studentshavecompletedthelist';
import WrappedExercisesetting from './Exercisesetting';
import ExerciseDisplay from './ExerciseDisplay'
@@ -30,6 +30,8 @@ class Testpapersettinghomepage extends Component{
visible:false,
groupyslsval:"",
current_status:undefined,
+ DownloadType:false,
+ DownloadMessageval:undefined,
}
}
//切换tab
@@ -159,7 +161,41 @@ class Testpapersettinghomepage extends Component{
}
}
+ /// 确认是否下载
+ confirmysl(url){
+ axios.get(url).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
+ })
+ }
cancelmodel=()=>{
this.setState({
Modalstype:false,
@@ -296,9 +332,9 @@ class Testpapersettinghomepage extends Component{
{isAdmin === true?
diff --git a/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js b/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js
index 7d3c37704..a2343abf8 100644
--- a/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js
+++ b/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js
@@ -13,6 +13,7 @@ import '../css/busyWork.css'
import '../poll/pollStyle.css'
import {getImageUrl} from 'educoder';
import TraineetraininginformationModal from "./TraineetraininginformationModal";
+import DownloadMessageysl from '../../modals/DownloadMessageysl';
import Startshixuntask from "../coursesPublic/Startshixuntask";
@@ -63,6 +64,8 @@ class Listofworksstudentone extends Component {
},
student_works: [],
startbtn: false,
+ DownloadType:false,
+ DownloadMessageval:undefined,
columns: [
{
title: '序号',
@@ -335,8 +338,9 @@ class Listofworksstudentone extends Component {
console.log("Listofworksstudentone");
console.log("componentDidMount");
this.props.triggerRef(this);
- var homeworkid = this.props.match.params.homeworkid;
- this.Getalistofworks(homeworkid);
+ // var homeworkid = this.props.match.params.homeworkid;
+ // this.Getalistofworks(homeworkid);
+ this.Getalistofworkstwo("", "", "", "", 1, 20);
let query = this.props.location.pathname;
const type = query.split('/');
this.setState({
@@ -857,16 +861,15 @@ class Listofworksstudentone extends Component {
axios.get(url).then((response) => {
this.props.showNotification(`${response.data.message}`);
- var homeworkid = this.props.match.params.homeworkid;
- this.Getalistofworks(homeworkid);
+ // var homeworkid = this.props.match.params.homeworkid;
+ // this.Getalistofworks(homeworkid);
+ this.Getalistofworkstwo("", "", "", "", 1, 20);
}).catch((error) => {
console.log(error)
});
}
- ChangeTab=(e)=>{
- this.props.ChangeTab(e);
- }
+
render() {
let {visibles, game_list,columns, limit,experience, boolgalist,viewtrainingdata, teacherdata, page, data, jobsettingsdata, styletable, datas, order, loadingstate,computeTimetype} = this.state;
// console.log(this.state.data);
@@ -920,6 +923,12 @@ class Listofworksstudentone extends Component {
{visibles === true ?
+