From 5e43f534b5bfffaf5329af1d261c80212db75008 Mon Sep 17 00:00:00 2001 From: cxt <853663049@qq.com> Date: Mon, 16 Dec 2019 15:08:48 +0800 Subject: [PATCH 01/10] =?UTF-8?q?=E8=AE=A1=E7=AE=97=E6=88=90=E7=BB=A9?= =?UTF-8?q?=E8=B7=B3=E8=BF=87=E9=AA=8C=E8=AF=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/services/homeworks_service.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/services/homeworks_service.rb b/app/services/homeworks_service.rb index 0dc814c89..1c57b7f12 100644 --- a/app/services/homeworks_service.rb +++ b/app/services/homeworks_service.rb @@ -346,7 +346,7 @@ class HomeworksService work.work_score = format("%.2f",(score < 0 ? 0 : score).to_f) unless work.ultimate_score #logger.info("#############work_score: #{score}") work.calculation_time = Time.now - work.save! + work.save(validate: false) end end end \ No newline at end of file From c321745d88b4ab1c02205e5abd2fc161c18ae179 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=9E=97?= <904079904@qq.com> Date: Mon, 16 Dec 2019 15:15:47 +0800 Subject: [PATCH 02/10] =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- public/react/src/modules/tpm/component/TPMNav.js | 9 --------- 1 file changed, 9 deletions(-) diff --git a/public/react/src/modules/tpm/component/TPMNav.js b/public/react/src/modules/tpm/component/TPMNav.js index ac5128f26..677c6bb83 100644 --- a/public/react/src/modules/tpm/component/TPMNav.js +++ b/public/react/src/modules/tpm/component/TPMNav.js @@ -53,13 +53,8 @@ class TPMNav extends Component { {/*jupyter*/} { this.props.is_jupyter===true? - ( - is_teacher===true? 数据集 - :"" - ) - :"" } @@ -80,12 +75,8 @@ class TPMNav extends Component { 审核情况 : - is_teacher===true? 审核情况 - : - "" - ) From 98fdcf4bbb758888c0edf906de0d38be482f845f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=9E=97?= <904079904@qq.com> Date: Mon, 16 Dec 2019 15:31:55 +0800 Subject: [PATCH 03/10] =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- public/react/src/modules/courses/statistics/Statistics.js | 6 ------ 1 file changed, 6 deletions(-) diff --git a/public/react/src/modules/courses/statistics/Statistics.js b/public/react/src/modules/courses/statistics/Statistics.js index 21041a59c..20427a1fa 100644 --- a/public/react/src/modules/courses/statistics/Statistics.js +++ b/public/react/src/modules/courses/statistics/Statistics.js @@ -397,25 +397,19 @@ class Statistics extends Component{ const operations = {course_grouptype===false||this.state.course_groups.length===0?"": - this.state.activeKey==="1"? this.getwork_scoredata(1,group_idss,'desc') } /> - :"" } { this.state.activeKey==="1"? this.setComputeTimet(this.props.match.params.coursesId)}>获取最新成绩 :"" } - { - this.state.activeKey==="1"? this.derivefun(this.state.activeKey==="1"?`/courses/${this.props.match.params.coursesId}/export_member_scores_excel.xlsx`:`/courses/${this.props.match.params.coursesId}/export_member_act_score.xlsx`)}>导出 - :"" - } ; return( From 42e47bd447beb083dd922f37f881ec26c776a6cd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=9E=97?= <904079904@qq.com> Date: Mon, 16 Dec 2019 16:50:37 +0800 Subject: [PATCH 04/10] =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- public/react/src/AppConfig.js | 1 - .../shixunHomework/Listofworksstudentone.js | 8 +++---- .../modules/courses/statistics/Statistics.js | 24 ++++++++++++++----- .../Challenges/Challengesjupyter.js | 1 + 4 files changed, 23 insertions(+), 11 deletions(-) diff --git a/public/react/src/AppConfig.js b/public/react/src/AppConfig.js index acd18e6c3..95b08ecb4 100644 --- a/public/react/src/AppConfig.js +++ b/public/react/src/AppConfig.js @@ -52,7 +52,6 @@ export function initAxiosInterceptors(props) { //proxy="http://47.96.87.25:48080" proxy="https://pre-newweb.educoder.net" proxy="https://test-newweb.educoder.net" - proxy="https://test-jupyterweb.educoder.net" //proxy="http://192.168.2.63:3001" // 在这里使用requestMap控制,避免用户通过双击等操作发出重复的请求; diff --git a/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js b/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js index ab75b6c89..9c1d2146c 100644 --- a/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js +++ b/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js @@ -269,7 +269,7 @@ class Listofworksstudentone extends Component { ), }, { - title: '提交状态', + title: '作品状态', dataIndex: 'submitstate', key: 'submitstate', align: "center", @@ -638,7 +638,7 @@ class Listofworksstudentone extends Component { ), }, { - title: '提交状态', + title: '作品状态', dataIndex: 'submitstate', key: 'submitstate', align: "center", @@ -967,7 +967,7 @@ class Listofworksstudentone extends Component { ) }, { - title: '提交状态', + title: '作品状态', dataIndex: 'submitstate', key: 'submitstate', align: 'center', @@ -1315,7 +1315,7 @@ class Listofworksstudentone extends Component { ) }, { - title: '提交状态', + title: '作品状态', dataIndex: 'submitstate', key: 'submitstate', align: 'center', diff --git a/public/react/src/modules/courses/statistics/Statistics.js b/public/react/src/modules/courses/statistics/Statistics.js index 20427a1fa..d8647870e 100644 --- a/public/react/src/modules/courses/statistics/Statistics.js +++ b/public/react/src/modules/courses/statistics/Statistics.js @@ -392,24 +392,36 @@ class Statistics extends Component{ ) } - // console.log(this.props.isAdmin) + // console.log("Statistics"); + // console.log(this.props.user.course_is_end) - - const operations = + const course_is_endismy=this.props&&this.props.user&&this.props.user.course_is_end; + const operations = {course_grouptype===false||this.state.course_groups.length===0?"": + this.props.isAdmin()===true? this.getwork_scoredata(1,group_idss,'desc') } /> + :"" } { this.state.activeKey==="1"? - this.setComputeTimet(this.props.match.params.coursesId)}>获取最新成绩 + ( + course_is_endismy===false? + this.setComputeTimet(this.props.match.params.coursesId)}>获取最新成绩 + : + "" + ) + :"" + } + { + this.props.isAdmin()===true? + this.derivefun(this.state.activeKey==="1"?`/courses/${this.props.match.params.coursesId}/export_member_scores_excel.xlsx`:`/courses/${this.props.match.params.coursesId}/export_member_act_score.xlsx`)}>导出 :"" } - this.derivefun(this.state.activeKey==="1"?`/courses/${this.props.match.params.coursesId}/export_member_scores_excel.xlsx`:`/courses/${this.props.match.params.coursesId}/export_member_act_score.xlsx`)}>导出 ; return( @@ -586,7 +598,7 @@ class Statistics extends Component{ } ` } - + {bomdata===undefined||bomdata===null?"":bomdata.length===0?: Date: Mon, 16 Dec 2019 17:49:51 +0800 Subject: [PATCH 05/10] =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../courses/shixunHomework/Listofworksstudentone.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js b/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js index 9c1d2146c..855f860ef 100644 --- a/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js +++ b/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js @@ -269,7 +269,7 @@ class Listofworksstudentone extends Component { ), }, { - title: '作品状态', + title: '提交状态', dataIndex: 'submitstate', key: 'submitstate', align: "center", @@ -638,7 +638,7 @@ class Listofworksstudentone extends Component { ), }, { - title: '作品状态', + title: '提交状态', dataIndex: 'submitstate', key: 'submitstate', align: "center", @@ -967,7 +967,7 @@ class Listofworksstudentone extends Component { ) }, { - title: '作品状态', + title: '提交状态', dataIndex: 'submitstate', key: 'submitstate', align: 'center', @@ -1315,7 +1315,7 @@ class Listofworksstudentone extends Component { ) }, { - title: '作品状态', + title: '提交状态', dataIndex: 'submitstate', key: 'submitstate', align: 'center', @@ -4005,7 +4005,7 @@ class Listofworksstudentone extends Component { height: 58px; } .ysltableows .ant-table-thead > tr > th, .ant-table-tbody > tr > td { - padding: 9px; + padding: 9px; } ` } From 001a40a1438fd2d4be793f2c8374dfa0dd5dd593 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=98=8E?= <775174143@qq.com> Date: Mon, 16 Dec 2019 18:44:06 +0800 Subject: [PATCH 06/10] =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- public/react/src/AppConfig.js | 2 +- .../modules/courses/shixunHomework/ShixunHomeworkPage.js | 8 +++++--- .../modules/courses/shixunHomework/ShixunhomeWorkItem.js | 3 ++- .../src/modules/courses/shixunHomework/shixunHomework.js | 2 +- 4 files changed, 9 insertions(+), 6 deletions(-) diff --git a/public/react/src/AppConfig.js b/public/react/src/AppConfig.js index acd18e6c3..0356f25f1 100644 --- a/public/react/src/AppConfig.js +++ b/public/react/src/AppConfig.js @@ -35,7 +35,7 @@ if (isDev) { // 老师 //ebugType="teacher"; // 学生 -// debugType="student"; +//debugType="student"; window._debugType = debugType; export function initAxiosInterceptors(props) { diff --git a/public/react/src/modules/courses/shixunHomework/ShixunHomeworkPage.js b/public/react/src/modules/courses/shixunHomework/ShixunHomeworkPage.js index 05a3eb5cd..ad3eadef4 100644 --- a/public/react/src/modules/courses/shixunHomework/ShixunHomeworkPage.js +++ b/public/react/src/modules/courses/shixunHomework/ShixunHomeworkPage.js @@ -232,9 +232,11 @@ class ShixunHomeworkPage extends Component { typelist={teacherdatapage === undefined ? [""] : teacherdatapage.homework_status} /> this.gotohome()}>返回 - {teacherdatapage&&teacherdatapage.shixun_status>1?1?this.props.isAdmin()?实训详情:""} + target={"_blank"}>实训详情: this.props.isStudent()?teacherdatapage&&teacherdatapage.time_status<5?实训详情:"":"":""} @@ -336,7 +338,7 @@ class ShixunHomeworkPage extends Component { {teacherdatapage.commit_des} } - {teacherdatapage === undefined ? "" :teacherdatapage&&teacherdatapage.shixun_status>1?1&&teacherdatapage&&teacherdatapage.time_status<5?:""} diff --git a/public/react/src/modules/courses/shixunHomework/ShixunhomeWorkItem.js b/public/react/src/modules/courses/shixunHomework/ShixunhomeWorkItem.js index fc39effdd..a9bea3118 100644 --- a/public/react/src/modules/courses/shixunHomework/ShixunhomeWorkItem.js +++ b/public/react/src/modules/courses/shixunHomework/ShixunhomeWorkItem.js @@ -371,6 +371,7 @@ class ShixunhomeWorkItem extends Component{ {this.props.isStudent===true?this.props.course_identity===5?discussMessage&&discussMessage.shixun_status>1? + discussMessage.time_status<5? {startbtn===false? (discussMessage.task_operation[0] == '继续挑战' || discussMessage.task_operation[0] == '查看实战' ? @@ -381,7 +382,7 @@ class ShixunhomeWorkItem extends Component{ this.taskoperationId(discussMessage.task_operation[1])}> {discussMessage.task_operation[0]} ):开启中} - :"":"":"" + :"":"":"":"" } diff --git a/public/react/src/modules/courses/shixunHomework/shixunHomework.js b/public/react/src/modules/courses/shixunHomework/shixunHomework.js index d16562892..4705e7a8f 100644 --- a/public/react/src/modules/courses/shixunHomework/shixunHomework.js +++ b/public/react/src/modules/courses/shixunHomework/shixunHomework.js @@ -1208,7 +1208,7 @@ class ShixunHomework extends Component{ {this.props.isAdmin()?未发布:""} 提交中 补交中 - 评阅中 + 已截止
From 2ed7d095b094acd835c3e968854846f4c3a752be Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=9E=97?= <904079904@qq.com> Date: Mon, 16 Dec 2019 18:59:23 +0800 Subject: [PATCH 07/10] =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../courses/shixunHomework/Listofworksstudentone.js | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js b/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js index 435a9ca6e..6a80d6d48 100644 --- a/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js +++ b/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js @@ -382,7 +382,8 @@ class Listofworksstudentone extends Component { }, { title:关卡得分 - 截止前学员完成的关卡才有成绩
+ 计算规则: + 截止前学员完成的关卡才有成绩
}>
, dataIndex: 'levelscore', key: 'levelscore', @@ -774,7 +775,8 @@ class Listofworksstudentone extends Component { }, { title:关卡得分 - 截止前学员完成的关卡才有成绩
+ 计算规则: + 截止前学员完成的关卡才有成绩
}>
, dataIndex: 'levelscore', key: 'levelscore', @@ -1120,7 +1122,8 @@ class Listofworksstudentone extends Component { }, { title:关卡得分 - 截止前学员完成的关卡才有成绩
+ 计算规则: + 截止前学员完成的关卡才有成绩
}>
, dataIndex: 'levelscore', key: 'levelscore', @@ -1480,7 +1483,8 @@ class Listofworksstudentone extends Component { }, { title:关卡得分 - 截止前学员完成的关卡才有成绩
+ 计算规则: + 截止前学员完成的关卡才有成绩
}>
, dataIndex: 'levelscore', key: 'levelscore', From 9cb5ecb25718963d950ac78c595f14143ec5324a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=9E=97?= <904079904@qq.com> Date: Mon, 16 Dec 2019 19:18:23 +0800 Subject: [PATCH 08/10] =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../shixunHomework/Listofworksstudentone.js | 20 +++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js b/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js index 6a80d6d48..5afd7adf0 100644 --- a/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js +++ b/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js @@ -382,11 +382,11 @@ class Listofworksstudentone extends Component { }, { title:关卡得分 - 计算规则: + 计算规则:
截止前学员完成的关卡才有成绩
}>
, - dataIndex: 'levelscore', - key: 'levelscore', + dataIndex: 'final_score', + key: 'final_score', align: 'center', className: 'font-14', width: '99px', @@ -775,11 +775,11 @@ class Listofworksstudentone extends Component { }, { title:关卡得分 - 计算规则: + 计算规则:
截止前学员完成的关卡才有成绩
}>
, - dataIndex: 'levelscore', - key: 'levelscore', + dataIndex: 'final_score', + key: 'final_score', align: 'center', className: 'font-14', width: '99px', @@ -1122,11 +1122,11 @@ class Listofworksstudentone extends Component { }, { title:关卡得分 - 计算规则: + 计算规则:
截止前学员完成的关卡才有成绩
}>
, - dataIndex: 'levelscore', - key: 'levelscore', + dataIndex: 'final_score', + key: 'final_score', align: 'center', className: 'font-14', render: (text, record) => ( @@ -1483,7 +1483,7 @@ class Listofworksstudentone extends Component { }, { title:关卡得分 - 计算规则: + 计算规则:
截止前学员完成的关卡才有成绩
}>
, dataIndex: 'levelscore', From 19cd24ad9bbf21cabd6e42cc94c3469969112b25 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=9E=97?= <904079904@qq.com> Date: Mon, 16 Dec 2019 19:37:47 +0800 Subject: [PATCH 09/10] =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../shixunHomework/Listofworksstudentone.js | 159 +++++++++--------- 1 file changed, 83 insertions(+), 76 deletions(-) diff --git a/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js b/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js index 5afd7adf0..b7945ee60 100644 --- a/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js +++ b/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js @@ -61,6 +61,9 @@ class Listofworksstudentone extends Component { //要提交的分班状态checkedValuesineinfo //searchtext 输入的姓名和学号 //order 排序时间 + //当前成绩work_score + //关卡得分final_score + this.state = { jobsettingsdata: undefined, endTime: "2018/11/10 17:10:00", @@ -394,19 +397,19 @@ class Listofworksstudentone extends Component { - = 90 ? {color: '#DD1717', textAlign: "center", width: '99px',} : { + } : parseInt(record.final_score) >= 90 ? {color: '#DD1717', textAlign: "center", width: '99px',} : { color: '#747A7F', textAlign: "center", width: '99px', - }}>{record.levelscore} + }}>{record.final_score} ) }, @@ -460,26 +463,26 @@ class Listofworksstudentone extends Component { }, { title: '当前成绩', - dataIndex: 'levelscore', - key: 'levelscore', + dataIndex: 'work_score', + key: 'work_score', align: "center", className: 'font-14', width: '99px', render: (text, record) => ( { - record.levelscore && record.levelscore === "--" ? - {record.levelscore} + record.work_score && record.work_score === "--" ? + {record.work_score} : - = 90 ? { + = 90 ? { color: '#DD1717', textAlign: "center", width: '99px', - } : parseInt(record.levelscore) <= 60 ? { + } : parseInt(record.work_score) <= 60 ? { color: '#FF6800', textAlign: "center", width: '99px', - } : {color: '#747A7F', textAlign: "center", width: '99px',}}>{record.levelscore} + } : {color: '#747A7F', textAlign: "center", width: '99px',}}>{record.work_score} } @@ -787,19 +790,19 @@ class Listofworksstudentone extends Component { - = 90 ? {color: '#DD1717', textAlign: "center", width: '99px',} : { + } : parseInt(record.final_score) >= 90 ? {color: '#DD1717', textAlign: "center", width: '99px',} : { color: '#747A7F', textAlign: "center", width: '99px', - }}>{record.levelscore} + }}>{record.final_score} ) }, @@ -853,26 +856,26 @@ class Listofworksstudentone extends Component { }, { title: '当前成绩', - dataIndex: 'levelscore', - key: 'levelscore', + dataIndex: 'work_score', + key: 'work_score', align: "center", className: 'font-14', width: '99px', render: (text, record) => ( { - record.levelscore && record.levelscore === "--" ? - {record.levelscore} + record.work_score && record.work_score === "--" ? + {record.work_score} : - = 90 ? { + = 90 ? { color: '#DD1717', textAlign: "center", width: '99px', - } : parseInt(record.levelscore) <= 60 ? { + } : parseInt(record.work_score) <= 60 ? { color: '#FF6800', textAlign: "center", width: '99px', - } : {color: '#747A7F', textAlign: "center", width: '99px',}}>{record.levelscore} + } : {color: '#747A7F', textAlign: "center", width: '99px',}}>{record.work_score} } @@ -1131,16 +1134,16 @@ class Listofworksstudentone extends Component { className: 'font-14', render: (text, record) => ( - = 90 ? {color: '#DD1717', "text-align": "center"} : { + } : parseInt(record.final_score) >= 90 ? {color: '#DD1717', "text-align": "center"} : { color: '#747A7F', "text-align": "center" - }}>{record.levelscore} + }}>{record.final_score} ) }, @@ -1198,8 +1201,8 @@ class Listofworksstudentone extends Component { }, { title: '当前成绩', - dataIndex: 'finalscore', - key: 'finalscore', + dataIndex: 'work_score', + key: 'work_score', align: 'center', className: 'font-14', sorter: true, @@ -1211,35 +1214,35 @@ class Listofworksstudentone extends Component { record.ultimate_score === true ? {/*
{record.user_name}{record.user_login}
*/} -
{record.finalscore === "--" ? 最终调整成绩:0分 : - 最终调整成绩:{record.finalscore}分}
+
{record.work_score === "--" ? 最终调整成绩:0分 : + 最终调整成绩:{record.work_score}分}
}> { - record.finalscore && record.finalscore === "--" ? + record.work_score && record.work_score === "--" ? {record.finalscore} + }}>{record.work_score} : - = 90 ? {color: '#DD1717', "text-align": "center"} : { + } : parseInt(record.work_score) >= 90 ? {color: '#DD1717', "text-align": "center"} : { color: '#747A7F', "text-align": "center" - }}>{record.finalscore} + }}>{record.work_score} } : {/*
{record.user_name}{record.user_login}
*/} -
{record.levelscore === "--" ? 关卡得分:0分 : - 关卡得分:{record.levelscore}分}
+
{record.final_score === "--" ? 关卡得分:0分 : + 关卡得分:{record.final_score}分}
{record.efficiencyscore === "--" ? 效率评分:0分 : 效率评分:{record.efficiencyscore}分}
@@ -1249,27 +1252,27 @@ class Listofworksstudentone extends Component { {answer_open_evaluation===true?"":
查看参考答案:{record.view_answer_count}关
} -
{record.finalscore === "--" ? 最终成绩:0分 : - 最终成绩:{record.finalscore}分}
+
{record.work_score === "--" ? 最终成绩:0分 : + 最终成绩:{record.work_score}分}
}> { - record.finalscore && record.finalscore === "--" ? + record.work_score && record.work_score === "--" ? {record.finalscore} + }}>{record.work_score} : - = 90 ? {color: '#DD1717', "text-align": "center"} : { + } : parseInt(record.work_score) >= 90 ? {color: '#DD1717', "text-align": "center"} : { color: '#747A7F', "text-align": "center" - }}>{record.finalscore} + }}>{record.work_score} }
@@ -1486,22 +1489,22 @@ class Listofworksstudentone extends Component { 计算规则:
截止前学员完成的关卡才有成绩
}>, - dataIndex: 'levelscore', - key: 'levelscore', + dataIndex: 'final_score', + key: 'final_score', align: 'center', className: 'font-14', render: (text, record) => ( - = 90 ? {color: '#DD1717', textAlign: "center"} : { + } : parseInt(record.final_score) >= 90 ? {color: '#DD1717', textAlign: "center"} : { color: '#747A7F', textAlign: "center" - }}>{record.levelscore} + }}>{record.final_score} ) }, @@ -1559,8 +1562,8 @@ class Listofworksstudentone extends Component { }, { title: '当前成绩', - dataIndex: 'finalscore', - key: 'finalscore', + dataIndex: 'work_score', + key: 'work_score', align: 'center', className: 'font-14', sorter: true, @@ -1572,35 +1575,35 @@ class Listofworksstudentone extends Component { record.ultimate_score === true ? {/*
{record.user_name}{record.user_login}
*/} -
{record.finalscore === "--" ? 最终调整成绩:0分 : - 最终调整成绩:{record.finalscore}分}
+
{record.work_score === "--" ? 最终调整成绩:0分 : + 最终调整成绩:{record.work_score}分}
}> { - record.finalscore && record.finalscore === "--" ? + record.work_score && record.work_score === "--" ? {record.finalscore} + }}>{record.work_score} : - = 90 ? {color: '#DD1717', textAlign: "center"} : { + } : parseInt(record.work_score) >= 90 ? {color: '#DD1717', textAlign: "center"} : { color: '#747A7F', textAlign: "center" - }}>{record.finalscore} + }}>{record.work_score} }
: {/*
{record.user_name}{record.user_login}
*/} -
{record.levelscore === "--" ? 关卡得分:0分 : - 关卡得分:{record.levelscore}分}
+
{record.final_score === "--" ? 关卡得分:0分 : + 关卡得分:{record.final_score}分}
{record.efficiencyscore === "--" ? 效率评分:0分 : 效率评分:{record.efficiencyscore}分}
@@ -1610,27 +1613,27 @@ class Listofworksstudentone extends Component { {answer_open_evaluation===true?"":
查看参考答案:{record.view_answer_count}关
} -
{record.finalscore === "--" ? 最终成绩:0分 : - 最终成绩:{record.finalscore}分}
+
{record.work_score === "--" ? 最终成绩:0分 : + 最终成绩:{record.work_score}分}
}> { - record.finalscore && record.finalscore === "--" ? + record.work_score && record.work_score === "--" ? {record.finalscore} + }}>{record.work_score} : - = 90 ? {color: '#DD1717', textAlign: "center"} : { + } : parseInt(record.work_score) >= 90 ? {color: '#DD1717', textAlign: "center"} : { color: '#747A7F', textAlign: "center" - }}>{record.finalscore} + }}>{record.work_score} }
@@ -2082,7 +2085,8 @@ class Listofworksstudentone extends Component { levelscore: teacherdata.final_score, view_answer_count: teacherdata.view_answer_count, efficiencyscore: teacherdata.eff_score, - finalscore: teacherdata.work_score, + final_score: teacherdata.final_score===null||teacherdata.final_score===undefined||teacherdata.final_score===""?"--":teacherdata.final_score, + work_score: teacherdata.work_score===null||teacherdata.work_score===undefined||teacherdata.work_score===""?"--":teacherdata.work_score, operating: "查看", late_penalty: teacherdata.late_penalty === null ? "0" : teacherdata.late_penalty === undefined ? "0" : teacherdata.late_penalty, ultimate_score: teacherdata.ultimate_score, @@ -2123,8 +2127,9 @@ class Listofworksstudentone extends Component { updatetime: timedata === "Invalid date" ? "--" : timedata, completion: student_works[i].complete_count === null ? "0" : student_works[i].complete_count === undefined ? "0" : student_works[i].complete_count, levelscore: student_works[i].final_score, + final_score: student_works[i].final_score=== null ||student_works[i].final_score=== undefined||student_works[i].final_score=== ""?"--":student_works[i].final_score, + work_score: student_works[i].work_score===null||student_works[i].work_score===undefined||student_works[i].work_score===""?"--":student_works[i].work_score, efficiencyscore: student_works[i].eff_score === "0.0" ? "--" : student_works[i].eff_score === "0" ? "--" : student_works[i].eff_score, - finalscore: student_works[i].work_score, view_answer_count: student_works[i].view_answer_count, operating: "查看", late_penalty: student_works[i].late_penalty === null ? "0" : student_works[i].late_penalty === undefined ? "0" : student_works[i].late_penalty, @@ -2285,7 +2290,8 @@ class Listofworksstudentone extends Component { levelscore: teacherdata.final_score, efficiencyscore: teacherdata.eff_score, view_answer_count: teacherdata.view_answer_count, - finalscore: teacherdata.work_score, + final_score: teacherdata.final_score===null||teacherdata.final_score===undefined||teacherdata.final_score===""?"--":teacherdata.final_score, + work_score:teacherdata.work_score===null||teacherdata.work_score===undefined||teacherdata.work_score===""?"--":teacherdata.work_score, operating: "查看", late_penalty: teacherdata.late_penalty === null ? "0" : teacherdata.late_penalty === undefined ? "0" : teacherdata.late_penalty, ultimate_score: teacherdata.ultimate_score, @@ -2645,7 +2651,8 @@ class Listofworksstudentone extends Component { completion: student_works[i].complete_count === null ? "0" : student_works[i].complete_count === undefined ? "0" : student_works[i].complete_count, levelscore: student_works[i].final_score, efficiencyscore: student_works[i].eff_score === "0.0" ? "--" : student_works[i].eff_score === "0" ? "--" : student_works[i].eff_score, - finalscore: student_works[i].work_score, + final_score: student_works[i].final_score===null||student_works[i].final_score===undefined||student_works[i].final_score===""?"--":student_works[i].final_score, + work_score:student_works[i].work_score===null||student_works[i].work_score===undefined||student_works[i].work_score===""?"--":student_works[i].work_score, view_answer_count: student_works[i].view_answer_count, operating: "查看", late_penalty: student_works[i].late_penalty === null ? "0" : student_works[i].late_penalty === undefined ? "0" : student_works[i].late_penalty, From db8b54fe43fae42b3c1821e574a0346557f0e94d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=9E=97?= <904079904@qq.com> Date: Mon, 16 Dec 2019 21:40:33 +0800 Subject: [PATCH 10/10] =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../shixunHomework/Listofworksstudentone.js | 15 ++++----------- 1 file changed, 4 insertions(+), 11 deletions(-) diff --git a/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js b/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js index b7945ee60..7a2d811c7 100644 --- a/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js +++ b/public/react/src/modules/courses/shixunHomework/Listofworksstudentone.js @@ -1810,7 +1810,7 @@ class Listofworksstudentone extends Component { Getalistofworks = (homeworkid, bool) => { // console.log("获取作品列表"); // console.log("935"); - // debugger + // debugger111111111111111 let searchtype = this.props.history.location.search; let urll = `/homework_commons/${homeworkid}/works_list.json`; var datasysl = { @@ -1823,16 +1823,9 @@ class Listofworksstudentone extends Component { course_group: this.state.checkedValuesineinfo, } axios.post(urll, datasysl).then((result) => { - // console.log("980000000____________________"); - if (result === undefined) { return } - // if(result.data.message!==undefined){ - // - // return; - // } - this.setState({ teacherdata: result.data, task_status: result.data.task_status, @@ -1891,7 +1884,7 @@ class Listofworksstudentone extends Component { // 获取作品列表 Getalistofworkstwo = (ordervlue, checkedValuesine, checkedValuesineinfo, searchtext, page, limit) => { - // console.log("获取作品列表"); + // console.log("获取作品列表");222222222222 var homeworkid = this.props.match.params.homeworkid; let urll = `/homework_commons/${homeworkid}/works_list.json`; // console.log(homeworkid); @@ -2427,7 +2420,7 @@ class Listofworksstudentone extends Component { } Startsorting = (ordervlue, checkedValuesine, checkedValuesineinfo, searchtext, page, limit) => { - // console.log("获取作品列表Listofworksstudenttwo"); + // console.log("获取作品列表Listofworksstudenttwo");33333333 var homeworkid = this.props.match.params.homeworkid; let urll = `/homework_commons/${homeworkid}/works_list.json`; // console.log(homeworkid); @@ -2548,7 +2541,7 @@ class Listofworksstudentone extends Component { //searchtext 输入的姓名和学号 //order 排序时间 //debug=t 是老师的意思 - // console.log(ordervlue)7009 + // console.log(ordervlue)70094444444 var homeworkid = this.props.match.params.homeworkid; let urll = `/homework_commons/${homeworkid}/works_list.json?`;