diff --git a/public/react/src/context/TPIContextProvider.js b/public/react/src/context/TPIContextProvider.js index b5c8cf565..ae88bf865 100644 --- a/public/react/src/context/TPIContextProvider.js +++ b/public/react/src/context/TPIContextProvider.js @@ -714,10 +714,10 @@ pop_box_new(htmlvalue, 480, 182); } testSetUnlock() { - const { game } = this.state; - const url = `/v1/games/${game.identifier}/check_test_sets.json` + const { game, challenge } = this.state; + const url = `/tasks/${game.identifier}/check_test_sets.json` axios.get(url, { - withCredentials: true, + // withCredentials: true, }) .then((response) => { // TODO status -2 重复操作,直接解锁 @@ -727,12 +727,12 @@ pop_box_new(htmlvalue, 480, 182); return; } else { // 被扣除的金币,是负数 - const deltaScore = response.data.score; + const deltaScore = -challenge.score * 5; // output_sets let { output_sets } = this.state; output_sets = Object.assign({}, output_sets); - const test_sets_array = JSON.parse("[" + response.data.test_sets + "]"); - output_sets.test_sets_array = test_sets_array; + // const test_sets_array = JSON.parse("[" + response.data.test_sets + "]"); + output_sets.test_sets_array = response.data.test_sets; this.setState({ output_sets: output_sets, grade: this.state.grade + deltaScore, diff --git a/public/react/src/modules/comment/Comments.js b/public/react/src/modules/comment/Comments.js index 20f48cd92..711ece6fa 100644 --- a/public/react/src/modules/comment/Comments.js +++ b/public/react/src/modules/comment/Comments.js @@ -323,11 +323,14 @@ class Comments extends Component {
违规评论已被屏蔽!
- : - } + : */} + + {/* } */}还未上传附件
+是否确认提交作品?
+
- 发布设置(课堂管理员、教师、助教拥有发布设置权限)
+ 发布设置
{
!flagPageEdit&&this.props.isAdmin()===true ?
@@ -660,7 +660,7 @@ class Exercisesetting extends Component{
@@ -185,7 +194,7 @@ class ShixunWorkReport extends Component {
第{item.position}关
-
+
{item.subject}
diff --git a/public/react/src/modules/courses/shixunHomework/Shixunworkdetails/ShixunWorkModal.js b/public/react/src/modules/courses/shixunHomework/Shixunworkdetails/ShixunWorkModal.js
index e914ee19c..eaf1c433e 100644
--- a/public/react/src/modules/courses/shixunHomework/Shixunworkdetails/ShixunWorkModal.js
+++ b/public/react/src/modules/courses/shixunHomework/Shixunworkdetails/ShixunWorkModal.js
@@ -74,6 +74,9 @@ class ShixunWorkModal extends Component{
response.data. course_groups.group_list&&response.data.group_list.map((item,key)=>{
newgroup_list.push(item)
})
+ response.data. course_groups.ungroup_list&&response.data.ungroup_list.map((items,keys)=>{
+ newgroup_list.push(items)
+ })
this.setState({
course_groups:response.data,
group_list:newgroup_list,
@@ -123,6 +126,15 @@ class ShixunWorkModal extends Component{
isSave=()=>{
let{group_ids}=this.state;
+ if(group_ids&&group_ids.length === 0){
+ this.props.showNotification(`请先选择分班`);
+ return
+ }
+ if(group_ids&&group_ids.length < 2){
+ this.props.showNotification(`有效作品数少于2个,无法查重`);
+ return
+ }
+
let url="/homework_commons/"+this.props.match.params.homeworkid+"/homework_code_repeat.json";
axios.post(url, {
group_ids: group_ids,
diff --git a/public/react/src/modules/courses/shixunHomework/shixunreport/OfficialAcademicTranscript.js b/public/react/src/modules/courses/shixunHomework/shixunreport/OfficialAcademicTranscript.js
index 091b94130..fb24e6a3e 100644
--- a/public/react/src/modules/courses/shixunHomework/shixunreport/OfficialAcademicTranscript.js
+++ b/public/react/src/modules/courses/shixunHomework/shixunreport/OfficialAcademicTranscript.js
@@ -1,173 +1,181 @@
-import React, {Component} from "react";
-import {WordsBtn} from 'educoder';
-import {Table} from "antd";
-import {Link,Switch,Route,Redirect} from 'react-router-dom';
-
-class OfficialAcademicTranscript extends Component {
-
- constructor(props) {
- super(props);
- this.state = {
- loadingstate:true,
- datas:undefined
- }
- }
-
- componentDidMount() {
-
- }
-
- render() {
-
- let {data}=this.props;
-
- let datas=[];
- if(data!=undefined){
- data.stage_list===undefined?"":data.stage_list.forEach((item,key)=>{
- datas.push({
- customs: key+1,
- taskname:{name:item.name,complete_status:item.complete_status},
- openingtime:item.open_time,
- evaluating: item.evaluate_count,
- finishtime:item.finished_time,
- elapsedtime:item.time_consuming,
- empvalue:{myself:item.myself_experience,experience:item.experience},
- // adjustmentminute:asdasd
- })
- })
- }
-
-
-
- let columns=[{
- title: '关卡',
- dataIndex: 'customs',
- key: 'customs',
- render: (text, record) => (
-
- {record.customs}
-
- ),
- }, {
- title: '任务名称',
- dataIndex: 'taskname',
- key: 'taskname',
- render: (text, record) => (
-
- {record.taskname.name}
- {record.taskname.complete_status===2?延时:record.taskname.complete_status===3?延时:""}
-
- ),
- }, {
- title: '开启时间',
- dataIndex: 'openingtime',
- key: 'openingtime',
- render: (text, record) => (
-
- {record.openingtime}
-
- ),
- }, {
- title: '评测次数',
- key: 'evaluating',
- dataIndex: 'evaluating',
-
- render: (text, record) => (
-
- {record.evaluating}
-
- ),
- }, {
- title: '完成时间',
- key: 'finishtime',
- dataIndex: 'finishtime',
- render: (text, record) => (
-
- {record.finishtime}
-
- ),
- }, {
- title: '耗时',
- key: 'elapsedtime',
- dataIndex: 'elapsedtime',
-
- render: (text, record) => (
-
- {record.elapsedtime}
-
- ),
- }, {
- title: '经验值',
- key: 'empvalue',
- dataIndex: 'empvalue',
-
- render: (text, record) => (
-
- {record.empvalue.myself}/{record.empvalue.experience}
-
- ),
- }];
- // {
- // title: '调分',
- // key: 'adjustmentminute',
- // dataIndex: 'adjustmentminute',
- //
- // render: (text, record) => (
- //
- // 6小时 50分钟 6秒
- //
- // ),
- // },
-
-
-
- return (
- }
-
}
+