hjm 5 years ago
commit d6d81c440d

File diff suppressed because it is too large Load Diff

@ -1,5 +1,5 @@
import React,{ Component } from "react";
import { Modal,Checkbox,Input, Spin, Icon } from "antd";
import { Modal,Checkbox,Input, Spin, Icon,notification } from "antd";
import axios from 'axios';
import Modals from '../../modals/Modals';
const CheckboxGroup = Checkbox.Group;
@ -187,15 +187,26 @@ class Addcourses extends Component{
if(response.data.course_id!=undefined){
this.submitasyn(response.data.course_id)
}
notification.open({
message:"提示",
description:response.data.message
});
this.props.hideAddcoursestype();
this.props.showNotification(response.data.message);
// this.props.showNotification(response.data.message);
}else{
this.setState({
Addcoursestype:false
})
notification.open({
message:"提示",
description:response.data.message
});
this.setState({
Addcoursestype:false
})
this.props.hideAddcoursestype();
this.props.showNotification(response.data.message);
// this.setState({
// loadtype:true,
// modalsType:true,

@ -222,6 +222,8 @@ class Testpapersettinghomepage extends Component{
:
<Menu mode="horizontal" selectedKeys={tab} onClick={this.changeTab}>
<Menu.Item key="0">答题列表</Menu.Item>
{Commonheadofthetestpaper&&Commonheadofthetestpaper.show_statistic===true?
<Menu.Item key="1">统计结果</Menu.Item>:""}
<Menu.Item key="3">设置</Menu.Item>
</Menu>
}

@ -33,7 +33,7 @@ class GraduationTasksedit extends Component{
componentDidMount(){
let {title_num}=this.state;
let tasksid=this.props.match.params.category_id;
let url ="/graduation_tasks/"+tasksid+"/edit.json"
@ -52,15 +52,18 @@ class GraduationTasksedit extends Component{
}
}
let namelength=result.data.task_name.length;
let sixlength=title_num-namelength
this.setState({
fileList:newfilelist,
description:result.data.description,
tasktype:result.data.task_type,
name:result.data.task_name,
data:result.data,
title_num:sixlength
})
this.props.form.setFieldsValue({
tasktype:result.data.task_type,
name:result.data.task_name,

@ -1168,7 +1168,8 @@ class GraduationTaskssettingapp extends Component{
value={end_time===null||end_time===""?"":moment(end_time, dateFormat)}
onChange={this.onChangeTimeend}
disabledTime={disabledDateTime}
disabled={this.props.isSuperAdmin()===true?flagPageEdit===true?false:true:this.props.isAdmin()===true?endtimetype===true?true:flagPageEdit===true?false:true:true}
// disabled={this.props.isSuperAdmin()===true?flagPageEdit===true?false:true:this.props.isAdmin()===true?endtimetype===true?true:flagPageEdit===true?false:true:true}
disabled={this.props.isAdmin()===true?endtimetype===true?true:flagPageEdit===true?false:true:true}
className={this.state.endTimetypes===true||end_timetype===true?"noticeTip":""}
/>
</span>
@ -1251,7 +1252,8 @@ class GraduationTaskssettingapp extends Component{
<div className="stud-class-set bor-bottom-greyE pd20 edu-back-white pl36">
<div className={" font-16 color-dark h20 mb20"}>评分设置 </div>
<div className={"font-16 h20 mb20"}>最终成绩组成 <span className={"font-14 color-grey-c"}>取各教师最终评分的平均分</span></div>
<Checkbox className="ml40 font-16" checked={crosscomment} onChange={this.funcrosscomment} disabled={this.props.isAdmin()===true?flagPageEdit===true?false:true:true} >启用交叉评阅 <span className={"font-14 color-grey-c"}>给老师分配其他指导老师的学生作品</span>
<Checkbox className="ml40 font-16" checked={crosscomment} onChange={this.funcrosscomment}
disabled={this.props.isAdmin()===true?flagPageEdit===true?false:true:true} >启用交叉评阅 <span className={"font-14 color-grey-c"}>给老师分配其他指导老师的学生作品</span>
</Checkbox>
{crosscomment===true?<div>
<div className={"h20 mb30 ml30 mt20 ml87"}>

@ -800,55 +800,62 @@ class GraduationTaskssettinglist extends Component{
let category_id=this.props.match.params.category_id;
let task_Id = this.props.match.params.task_Id;
if(this.props.isStudent()===true){
columns.some((item,key)=> {
if (item.title === "学号") {
columns.splice(key, 1)
return true
}
}
)
}
if(taskslistdata&&taskslistdata.course_group_count<=0){
//分班有显示
columns.map((item,key)=>{
if(item.title==="分班"){
columns.splice(key,1)
columns.some((item,key)=> {
if (item.title === "分班") {
columns.splice(key, 1)
return true
}
}
})
)
}
if(taskslistdata&&taskslistdata.cross_comment===false){
columns.map((item,key)=>{
if(item.title==="交叉评分"){
columns.splice(key,1)
columns.some((item,key)=> {
if (item.title === "交叉评分") {
columns.splice(key, 1)
return true
}
}
)
}
if(taskslistdata&&taskslistdata.have_grouping===false){
columns.some((item,key)=> {
if (item.title === "关联项目") {
columns.splice(key, 1)
return true
}
})
}
)
if(taskslistdata&&taskslistdata.have_grouping===false){
columns.map((item,key)=>{
if(item.title==="关联项目"){
columns.splice(key,1)
}
})
columns.map((item,key)=>{
if(item.title==="分组"){
columns.splice(key,1)
}
})
}
}else{
if(taskslistdata&&taskslistdata.have_grouping===false){
columns.map((item,key)=>{
if(item.title==="关联项目"){
columns.splice(key,1)
}
})
columns.some((item,key)=> {
if (item.title === "分组") {
columns.splice(key, 1)
return true
}
}
)
columns.map((item,key)=>{
if(item.title==="分组"){
columns.splice(key,1)
}
})
}
}
}
return(
<React.Fragment>
@ -1018,8 +1025,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 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>
</ul>
</li>:""}

@ -3,6 +3,7 @@ import CoursesListType from '../coursesPublic/CoursesListType';
import {WordsBtn,ActionBtn} from 'educoder';
import ShixunWorkModal from './Shixunworkdetails/ShixunWorkModal';
import HomeworkModal from "../coursesPublic/HomeworkModal";
import NoneData from '../coursesPublic/NoneData'
import {
Form,
Select,
@ -93,23 +94,27 @@ class ShixunStudentWork extends Component {
let url = "/homework_commons/" + homeworkid + "/code_review_results.json";
axios.get(url).then((response) => {
debugger
if (response.data.status === undefined || response.data.status === 0) {
if(response.data!=undefined){
let datas=[];
let list=response.data.users_reviews;
for(var i=0; i<list.length; i++){
datas.push({
number:i+1,
name:list[i].username,
stduynumber:list[i].student_id,
classroom:parseInt(list[i].code_rate),
operating:list[i].user_id
if(response.data.status!=-2){
let datas=[];
let list=response.data.users_reviews;
for(var i=0; i<list.length; i++){
datas.push({
number:i+1,
name:list[i].username,
stduynumber:list[i].student_id,
classroom:parseInt(list[i].code_rate),
operating:list[i].user_id
})
}
this.setState({
data: response.data,
datalist:datas
})
}
this.setState({
data: response.data,
datalist:datas
})
}
}
@ -154,21 +159,24 @@ class ShixunStudentWork extends Component {
}}).then((response) => {
if (response.data.status === undefined || response.data.status === 0) {
if(response.data!=undefined){
let datas=[];
let list=response.data.users_reviews;
for(var i=0; i<list.length; i++){
datas.push({
number:i+1,
name:list[i].username,
stduynumber:list[i].student_id,
classroom:parseInt(list[i].code_rate),
operating:list[i].user_id
if(response.data.status!=-2) {
let datas = [];
let list = response.data.users_reviews;
for (var i = 0; i < list.length; i++) {
datas.push({
number: i + 1,
name: list[i].username,
stduynumber: list[i].student_id,
classroom: parseInt(list[i].code_rate),
operating: list[i].user_id
})
}
this.setState({
data: response.data,
datalist: datas
})
}
this.setState({
data: response.data,
datalist:datas
})
}
}
@ -505,6 +513,18 @@ class ShixunStudentWork extends Component {
},
];
if(this.props.isNotMember()===true){
columns.some((item,key)=> {
if (item.title === "学号") {
columns.splice(key, 1)
return true
}
}
)
}
return (
<div className="newMain clearfix ">
{this.state.showmodel===true?<ShixunWorkModal
@ -535,7 +555,6 @@ class ShixunStudentWork extends Component {
starttimes={this.state.starttimes}
typs={this.state.typs}
/>
{data&&data?
<div className={"educontent mb20"}>
<div className="educontent mb25">
<p className="clearfix mb25 mt5">
@ -554,10 +573,10 @@ class ShixunStudentWork extends Component {
</div>
<div className="educontent mb30">
<p className=" fl color-black summaryname">
{data.homework_name}
{data&&data.homework_name}
</p>
<CoursesListType
typelist={data.homework_status}
typelist={data&&data.homework_status}
/>
<a className="color-grey-9 fr font-16 summaryname ml20 mr20"
href={`/courses/${this.state.props.match.params.coursesId}/${this.state.shixuntypes}/${jobsettingsdata === undefined ? "" :jobsettingsdata.data.category.category_id}`}>返回</a>
@ -593,10 +612,10 @@ class ShixunStudentWork extends Component {
href={`/api/homework_commons/${this.props.match.params.coursesId}/works_list.xlsx`}
>导出</a> : ""}
{this.props.isAdmin()?
data.end_immediately===true?
data&&data.end_immediately===true?
<a className="fr color-blue font-16" onClick={this.homeworkends}>立即截止</a> : "" : ""}
{this.props.isAdmin()?
data.publish_immediately===true?
data&&data.publish_immediately===true?
<a className="fr color-blue font-16" onClick={this.homeworkstart}>立即发布</a> : "" : ""}
{/*{this.props.isAdmin()?*/}
@ -623,10 +642,11 @@ class ShixunStudentWork extends Component {
`}
</style>
<li className="clearfix startbox" style={{display:duplicatechecking===true?"":"none"}}>
<li className="clearfix startbox mb20" style={{display:duplicatechecking===true?"":"none"}}>
<span className={"startfont"}>
正在执行查重请稍后刷新页面查看结果 温馨提示执行时间因查重作品数以及作品的代码量而异
</span>
<NoneData></NoneData>
</li>
<style>
{`
@ -638,6 +658,8 @@ class ShixunStudentWork extends Component {
`}
</style>
{data&&data?
<div>
<ul className="clearfix" style={{padding: '20px 40px 10px 40px'}}>
<li className="clearfix ">
@ -742,9 +764,9 @@ class ShixunStudentWork extends Component {
/>}
</div>
</div>
</div>:""}
</div>:""}
</div></div>

@ -95,7 +95,7 @@ class SiderBar extends Component {
</div>
<div className="feedback" tooltips="意见反馈">
<a target="_blank" className="color_white" href="https://www.educoder.net/help?index=6">
<a target="_blank" className="color_white" href="/help?index=6">
<i className="iconfont icon-yijianfankui color-white font-22"></i>
</a>
</div>

Loading…
Cancel
Save