|
|
@ -27,6 +27,7 @@ import moment from 'moment';
|
|
|
|
import 'moment/locale/zh-cn';
|
|
|
|
import 'moment/locale/zh-cn';
|
|
|
|
import Modals from "../../modals/Modals";
|
|
|
|
import Modals from "../../modals/Modals";
|
|
|
|
import DownloadMessage from '../../modals/DownloadMessage';
|
|
|
|
import DownloadMessage from '../../modals/DownloadMessage';
|
|
|
|
|
|
|
|
import Startshixuntask from "../coursesPublic/Startshixuntask";
|
|
|
|
const RadioGroup = Radio.Group;
|
|
|
|
const RadioGroup = Radio.Group;
|
|
|
|
|
|
|
|
|
|
|
|
//GraduationTaskssetting.js
|
|
|
|
//GraduationTaskssetting.js
|
|
|
@ -1686,30 +1687,31 @@ class Trainingjobsetting extends Component {
|
|
|
|
|
|
|
|
|
|
|
|
/// 确认是否下载
|
|
|
|
/// 确认是否下载
|
|
|
|
confirmysl(url){
|
|
|
|
confirmysl(url){
|
|
|
|
axios.get(url).then((response) => {
|
|
|
|
this.refs.DownloadMessage.confirmysl(url);
|
|
|
|
if(response.data.status&&response.data.status===-1){
|
|
|
|
// axios.get(url).then((response) => {
|
|
|
|
|
|
|
|
// if(response.data.status&&response.data.status===-1){
|
|
|
|
|
|
|
|
|
|
|
|
}else if(response.data.status&&response.data.status===-2){
|
|
|
|
// }else if(response.data.status&&response.data.status===-2){
|
|
|
|
if(response.data.messages === "100"){
|
|
|
|
// if(response.data.messages === "100"){
|
|
|
|
// 已超出文件导出的上限数量(100 ),建议:
|
|
|
|
// // 已超出文件导出的上限数量(100 ),建议:
|
|
|
|
this.setState({
|
|
|
|
// this.setState({
|
|
|
|
DownloadType:true,
|
|
|
|
// DownloadType:true,
|
|
|
|
DownloadMessageval:100
|
|
|
|
// DownloadMessageval:100
|
|
|
|
})
|
|
|
|
// })
|
|
|
|
}else {
|
|
|
|
// }else {
|
|
|
|
//因附件资料超过500M
|
|
|
|
// //因附件资料超过500M
|
|
|
|
this.setState({
|
|
|
|
// this.setState({
|
|
|
|
DownloadType:true,
|
|
|
|
// DownloadType:true,
|
|
|
|
DownloadMessageval:500
|
|
|
|
// DownloadMessageval:500
|
|
|
|
})
|
|
|
|
// })
|
|
|
|
}
|
|
|
|
// }
|
|
|
|
}else {
|
|
|
|
// }else {
|
|
|
|
this.props.showNotification(`正在下载中`);
|
|
|
|
// this.props.showNotification(`正在下载中`);
|
|
|
|
window.open("/api"+url, '_blank');
|
|
|
|
// window.open("/api"+url, '_blank');
|
|
|
|
}
|
|
|
|
// }
|
|
|
|
}).catch((error) => {
|
|
|
|
// }).catch((error) => {
|
|
|
|
console.log(error)
|
|
|
|
// console.log(error)
|
|
|
|
});
|
|
|
|
// });
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
Downloadcal=()=>{
|
|
|
|
Downloadcal=()=>{
|
|
|
@ -1776,9 +1778,7 @@ class Trainingjobsetting extends Component {
|
|
|
|
|
|
|
|
|
|
|
|
<DownloadMessage
|
|
|
|
<DownloadMessage
|
|
|
|
{...this.props}
|
|
|
|
{...this.props}
|
|
|
|
value={this.state.DownloadMessageval}
|
|
|
|
ref="DownloadMessage"
|
|
|
|
modalCancel={this.Downloadcal}
|
|
|
|
|
|
|
|
modalsType={this.state.DownloadType}
|
|
|
|
|
|
|
|
/>
|
|
|
|
/>
|
|
|
|
|
|
|
|
|
|
|
|
{/*立即发布*/}
|
|
|
|
{/*立即发布*/}
|
|
|
@ -1807,77 +1807,17 @@ class Trainingjobsetting extends Component {
|
|
|
|
loadtype={loadtype}
|
|
|
|
loadtype={loadtype}
|
|
|
|
modalSave={modalSave}
|
|
|
|
modalSave={modalSave}
|
|
|
|
></Modals>
|
|
|
|
></Modals>
|
|
|
|
<div className={"educontent mb20"}>
|
|
|
|
<div className={"educontent "}>
|
|
|
|
<div className="edu-back-white">
|
|
|
|
<div className="edu-back-white" style={{paddingTop: "20px"}}>
|
|
|
|
<div className="stud-class-set bor-bottom-greyE ">
|
|
|
|
|
|
|
|
<div className=" clearfix edu-back-white poll_list">
|
|
|
|
|
|
|
|
<a onClick={(e)=>this.ChangeTab(0)}>作品列表</a>
|
|
|
|
|
|
|
|
<a onClick={(e)=>this.ChangeTab(1)}>作业问答</a>
|
|
|
|
|
|
|
|
{this.props.isAdmin()?this.state.code_review===true||jobsettingsdata === undefined ? [""] : jobsettingsdata.data.homework_status[0]==="未发布"?"": <a onClick={(e)=>this.ChangeTab(2)}>代码查重</a> : ""}
|
|
|
|
|
|
|
|
<style>{
|
|
|
|
|
|
|
|
`
|
|
|
|
|
|
|
|
.poll_list a.active:after {
|
|
|
|
|
|
|
|
content: '';
|
|
|
|
|
|
|
|
width: 57px;
|
|
|
|
|
|
|
|
left: 10px;
|
|
|
|
|
|
|
|
bottom: 0px;
|
|
|
|
|
|
|
|
height: 2px;
|
|
|
|
|
|
|
|
background-color: #4CACFF;
|
|
|
|
|
|
|
|
position: absolute;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
`
|
|
|
|
|
|
|
|
}</style>
|
|
|
|
|
|
|
|
<a className="active"
|
|
|
|
|
|
|
|
onClick={(e)=>this.ChangeTab(3)}
|
|
|
|
|
|
|
|
>设置</a>
|
|
|
|
|
|
|
|
<style>{`
|
|
|
|
|
|
|
|
.drop_down_menu li a {
|
|
|
|
|
|
|
|
padding: 0px;
|
|
|
|
|
|
|
|
font-size: 14px;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
.drop_down_menu {
|
|
|
|
|
|
|
|
width: 93px;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
.drop_down_menu li {
|
|
|
|
|
|
|
|
overflow: visible;
|
|
|
|
|
|
|
|
width: 93px;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
.drop_down_menu, .drop_down_normal {
|
|
|
|
|
|
|
|
padding-top: 10px;
|
|
|
|
|
|
|
|
padding-bottom: 8px;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
a:hover {
|
|
|
|
|
|
|
|
color:#1A0B00 !important;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
`}</style>
|
|
|
|
|
|
|
|
{this.props.isAdmin() ? <li className="li_line drop_down fr color-blue font-16 mr8 mt20" style={{"padding": "0 20px"}}>
|
|
|
|
|
|
|
|
导出<i className="iconfont icon-xiajiantou font-12 ml2"></i>
|
|
|
|
|
|
|
|
<ul className="drop_down_menu" style={{"right": "-0px", "left": "unset", "height": "auto"}}>
|
|
|
|
|
|
|
|
<li><a onClick={()=>this.confirmysl(`/zip/shixun_report?homework_common_id=${this.props.match.params.homeworkid}`)}>实训报告</a>
|
|
|
|
|
|
|
|
</li>
|
|
|
|
|
|
|
|
<li><a onClick={()=>this.confirmysl(`/homework_commons/${this.props.match.params.homeworkid}/works_list.xlsx`)}>学生成绩</a>
|
|
|
|
|
|
|
|
</li>
|
|
|
|
|
|
|
|
</ul>
|
|
|
|
|
|
|
|
</li>: ""}
|
|
|
|
|
|
|
|
{this.props.isAdmin() ?jobsettingsdata&&jobsettingsdata.data.end_immediately===true?
|
|
|
|
|
|
|
|
<a className="fr color-blue font-16" onClick={this.homeworkends}>立即截止</a>
|
|
|
|
|
|
|
|
: "": ""}
|
|
|
|
|
|
|
|
{this.props.isAdmin() ?jobsettingsdata&&jobsettingsdata.data.publish_immediately===true?
|
|
|
|
|
|
|
|
<a className="fr color-blue font-16" onClick={this.homeworkstart}>立即发布</a>: "" : ""}
|
|
|
|
|
|
|
|
{this.props.isAdmin()?
|
|
|
|
|
|
|
|
jobsettingsdata&&jobsettingsdata.data.code_review===true?
|
|
|
|
|
|
|
|
<a className="fr color-blue font-16" onClick={this.workshowmodel}>代码查重</a>: "":""}
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
{/*发布设置*/}
|
|
|
|
{/*发布设置*/}
|
|
|
|
<div className="stud-class-set bor-bottom-greyE edu-back-white">
|
|
|
|
<div className="stud-class-set bor-bottom-greyE edu-back-white">
|
|
|
|
<div className=" mt20 pl20">
|
|
|
|
<div className=" pl20">
|
|
|
|
<p className=" clearfix " style={{height:"41px"}}>
|
|
|
|
<p className=" clearfix " style={{height:"41px"}}>
|
|
|
|
<span className="font-16 fl "style={{"color":"#05101A"}}>发布设置 <span className="ml15 color-grey-9" style={{"font-size":"14px","text-align":"left"}}></span></span>
|
|
|
|
<span className="font-16 fl "style={{"color":"#05101A"}}>发布设置 <span className="ml15 color-grey-9" style={{"font-size":"14px","text-align":"left"}}></span></span>
|
|
|
|
{
|
|
|
|
{
|
|
|
|
!flagPageEdit && this.props.isAdmin() === true ?
|
|
|
|
!flagPageEdit && this.props.isAdmin() === true ?
|
|
|
|
<a className="fr" onClick={this.editSetting}><i
|
|
|
|
<a className="fr" onClick={this.editSetting}><Tooltip title="编辑"><i
|
|
|
|
className="iconfont font-16 pr20 " style={{color:"#333333"}}>编辑</i></a>
|
|
|
|
className="iconfont icon-bianjidaibeijing font-20 color-green pr20 "></i></Tooltip></a>
|
|
|
|
: ""
|
|
|
|
: ""
|
|
|
|
}
|
|
|
|
}
|
|
|
|
</p>
|
|
|
|
</p>
|
|
|
@ -1903,7 +1843,7 @@ class Trainingjobsetting extends Component {
|
|
|
|
unifiedsetting === undefined ? "" : unifiedsetting=== true ?
|
|
|
|
unifiedsetting === undefined ? "" : unifiedsetting=== true ?
|
|
|
|
<div>
|
|
|
|
<div>
|
|
|
|
<div className="clearfix mb5 ml15">
|
|
|
|
<div className="clearfix mb5 ml15">
|
|
|
|
<span className="font-16 fl mt6" style={{"color":"#999999"}}>发布时间:</span>
|
|
|
|
<span className="font-16 fl mt3" style={{"color":"#999999"}}>发布时间:</span>
|
|
|
|
<Tooltip placement="bottom" title={this.props.isSuperAdmin() ? "" : !flagPageEditstwo === true ? "发布时间已过,则不能修改" : ""}>
|
|
|
|
<Tooltip placement="bottom" title={this.props.isSuperAdmin() ? "" : !flagPageEditstwo === true ? "发布时间已过,则不能修改" : ""}>
|
|
|
|
<div className="fl">
|
|
|
|
<div className="fl">
|
|
|
|
<DatePicker
|
|
|
|
<DatePicker
|
|
|
@ -1927,7 +1867,7 @@ class Trainingjobsetting extends Component {
|
|
|
|
/>
|
|
|
|
/>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</Tooltip>
|
|
|
|
</Tooltip>
|
|
|
|
<span className="ml20 fl mt10 color-grey-c" style={{"text-align":"left","font-size":"14px"}}>(学生收到作业的时间)</span>
|
|
|
|
<span className="ml20 fl mt5 color-grey-c" style={{"text-align":"left","font-size":"14px"}}>(学生收到作业的时间)</span>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<p className="color-red lineh-25 clearfix" style={{height:"25px"}}>
|
|
|
|
<p className="color-red lineh-25 clearfix" style={{height:"25px"}}>
|
|
|
|
{
|
|
|
|
{
|
|
|
@ -1936,7 +1876,7 @@ class Trainingjobsetting extends Component {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
</p>
|
|
|
|
</p>
|
|
|
|
<div className="clearfix ml15 mb5">
|
|
|
|
<div className="clearfix ml15 mb5">
|
|
|
|
<span className=" fl mt10 font-16" style={{"color":"#999999"}}>截止时间:</span>
|
|
|
|
<span className=" fl mt3 font-16" style={{"color":"#999999"}}>截止时间:</span>
|
|
|
|
<Tooltip placement="bottom" title={this.props.isSuperAdmin() ? "" : !flagPageEditsthrees === true ? "截止时间已过,则不能修改" : ""}>
|
|
|
|
<Tooltip placement="bottom" title={this.props.isSuperAdmin() ? "" : !flagPageEditsthrees === true ? "截止时间已过,则不能修改" : ""}>
|
|
|
|
<div className="fl">
|
|
|
|
<div className="fl">
|
|
|
|
<DatePicker
|
|
|
|
<DatePicker
|
|
|
@ -1961,7 +1901,7 @@ class Trainingjobsetting extends Component {
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</Tooltip>
|
|
|
|
</Tooltip>
|
|
|
|
|
|
|
|
|
|
|
|
<span className=" ml20 fl mt10 color-grey-c" style={{"text-align":"left","font-size":"14px"}}>(学生“按时”提交作品的时间截点)</span>
|
|
|
|
<span className=" ml20 fl mt5 color-grey-c" style={{"text-align":"left","font-size":"14px"}}>(学生“按时”提交作品的时间截点)</span>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<p className="color-red lineh-25 clearfix" style={{height:"25px"}}>
|
|
|
|
<p className="color-red lineh-25 clearfix" style={{height:"25px"}}>
|
|
|
|
{
|
|
|
|
{
|
|
|
@ -2124,9 +2064,8 @@ class Trainingjobsetting extends Component {
|
|
|
|
color:"#666666",
|
|
|
|
color:"#666666",
|
|
|
|
}} disabled={!flagPageEdit} className="c_grey mt20 ml30"
|
|
|
|
}} disabled={!flagPageEdit} className="c_grey mt20 ml30"
|
|
|
|
value={"自定义分值"} style={{"color":"#666666"}}>自定义分值
|
|
|
|
value={"自定义分值"} style={{"color":"#666666"}}>自定义分值
|
|
|
|
<a onClick={()=>this.testscripttip(0)}><img style={{marginBottom:"3px",marginLeft:"10px"}} src={getImageUrl("images/educoder/problem.png") }/></a>
|
|
|
|
|
|
|
|
{testscripttiptype===true?
|
|
|
|
{testscripttiptype===true?
|
|
|
|
<div className="invite-tip clearfix " id="test_script_tip" style={{left: '140px',width: '322px',zIndex: '10'}}>
|
|
|
|
<div className="invite-tipysls clearfix " id="test_script_tip" style={{left: '148px',width: '322px',zIndex: '10'}}>
|
|
|
|
<span className="right-black-trangles"></span>
|
|
|
|
<span className="right-black-trangles"></span>
|
|
|
|
<div className="padding20 invitecontent clearfix">
|
|
|
|
<div className="padding20 invitecontent clearfix">
|
|
|
|
<p className="font-12 edu-txt-left">
|
|
|
|
<p className="font-12 edu-txt-left">
|
|
|
@ -2147,7 +2086,9 @@ class Trainingjobsetting extends Component {
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
:""}
|
|
|
|
:""}
|
|
|
|
</Radio>
|
|
|
|
</Radio>
|
|
|
|
</RadioGroup></span>
|
|
|
|
</RadioGroup>
|
|
|
|
|
|
|
|
<a onClick={()=>this.testscripttip(0)}><img style={{marginBottom:"3px",marginLeft:"20px"}} src={getImageUrl("images/educoder/problem.png") }/></a>
|
|
|
|
|
|
|
|
</span>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<p className="ml20 mt15 c_grey font-13 " style={{"color":"#666666"}}> 关卡名称<span
|
|
|
|
<p className="ml20 mt15 c_grey font-13 " style={{"color":"#666666"}}> 关卡名称<span
|
|
|
|
className="color-grey-c font-10 ml10">(需要学生完成的任务请选中)</span></p>
|
|
|
|
className="color-grey-c font-10 ml10">(需要学生完成的任务请选中)</span></p>
|
|
|
@ -2224,3 +2165,73 @@ class Trainingjobsetting extends Component {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
export default Trainingjobsetting;
|
|
|
|
export default Trainingjobsetting;
|
|
|
|
|
|
|
|
// <div className="stud-class-set bor-bottom-greyE ">
|
|
|
|
|
|
|
|
// <div className=" clearfix edu-back-white poll_list">
|
|
|
|
|
|
|
|
// <a onClick={(e)=>this.ChangeTab(0)}>作品列表</a>
|
|
|
|
|
|
|
|
// <a onClick={(e)=>this.ChangeTab(1)}>作业问答</a>
|
|
|
|
|
|
|
|
// {this.props.isAdmin()?this.state.code_review===true||jobsettingsdata === undefined ? [""] : jobsettingsdata.data.homework_status[0]==="未发布"?"": <a onClick={(e)=>this.ChangeTab(2)}>代码查重</a> : ""}
|
|
|
|
|
|
|
|
// <style>{
|
|
|
|
|
|
|
|
// `
|
|
|
|
|
|
|
|
// .poll_list a.active:after {
|
|
|
|
|
|
|
|
// content: '';
|
|
|
|
|
|
|
|
// width: 57px;
|
|
|
|
|
|
|
|
// left: 10px;
|
|
|
|
|
|
|
|
// bottom: 0px;
|
|
|
|
|
|
|
|
// height: 2px;
|
|
|
|
|
|
|
|
// background-color: #4CACFF;
|
|
|
|
|
|
|
|
// position: absolute;
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
// `
|
|
|
|
|
|
|
|
// }</style>
|
|
|
|
|
|
|
|
// <a className="active"
|
|
|
|
|
|
|
|
// onClick={(e)=>this.ChangeTab(3)}
|
|
|
|
|
|
|
|
// >设置</a>
|
|
|
|
|
|
|
|
// <style>{`
|
|
|
|
|
|
|
|
// .drop_down_menu li a {
|
|
|
|
|
|
|
|
// padding: 0px;
|
|
|
|
|
|
|
|
// font-size: 14px;
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
// .drop_down_menu {
|
|
|
|
|
|
|
|
// width: 93px;
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
// .drop_down_menu li {
|
|
|
|
|
|
|
|
// overflow: visible;
|
|
|
|
|
|
|
|
// width: 93px;
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
// .drop_down_menu, .drop_down_normal {
|
|
|
|
|
|
|
|
// padding-top: 10px;
|
|
|
|
|
|
|
|
// padding-bottom: 8px;
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
// a:hover {
|
|
|
|
|
|
|
|
// color:#1A0B00 !important;
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
// `}</style>
|
|
|
|
|
|
|
|
// {this.props.isAdmin() ? <li className="li_line drop_down fr color-blue font-16 mr8 mt20" style={{"padding": "0 20px"}}>
|
|
|
|
|
|
|
|
// 导出<i className="iconfont icon-xiajiantou font-12 ml2"></i>
|
|
|
|
|
|
|
|
// <ul className="drop_down_menu" style={{"right": "-0px", "left": "unset", "height": "auto"}}>
|
|
|
|
|
|
|
|
// <li><a onClick={()=>this.confirmysl(`/zip/shixun_report?homework_common_id=${this.props.match.params.homeworkid}`)}>实训报告</a>
|
|
|
|
|
|
|
|
// </li>
|
|
|
|
|
|
|
|
// <li><a onClick={()=>this.confirmysl(`/homework_commons/${this.props.match.params.homeworkid}/works_list.xlsx`)}>学生成绩</a>
|
|
|
|
|
|
|
|
// </li>
|
|
|
|
|
|
|
|
// </ul>
|
|
|
|
|
|
|
|
// </li>: ""}
|
|
|
|
|
|
|
|
// {this.props.isAdmin() ?jobsettingsdata&&jobsettingsdata.data.end_immediately===true?
|
|
|
|
|
|
|
|
// <a className="fr color-blue font-16" onClick={this.homeworkends}>立即截止</a>
|
|
|
|
|
|
|
|
// : "": ""}
|
|
|
|
|
|
|
|
// {this.props.isAdmin() ?jobsettingsdata&&jobsettingsdata.data.publish_immediately===true?
|
|
|
|
|
|
|
|
// <a className="fr color-blue font-16" onClick={this.homeworkstart}>立即发布</a>: "" : ""}
|
|
|
|
|
|
|
|
// {this.props.isAdmin()?
|
|
|
|
|
|
|
|
// jobsettingsdata&&jobsettingsdata.data.code_review===true?
|
|
|
|
|
|
|
|
// <a className="fr color-blue font-16" onClick={this.workshowmodel}>代码查重</a>: "":""}
|
|
|
|
|
|
|
|
// {
|
|
|
|
|
|
|
|
// jobsettingsdata&& jobsettingsdata&&jobsettingsdata.data === undefined ? ""
|
|
|
|
|
|
|
|
// : jobsettingsdata&& jobsettingsdata.data.commit_des === null || jobsettingsdata&& jobsettingsdata.data.commit_des === undefined ? "" :
|
|
|
|
|
|
|
|
// <a className="fr color-blue font-16"
|
|
|
|
|
|
|
|
// href={`/courses/${this.state.props.match.params.coursesId}/${this.state.shixuntypes}/${ jobsettingsdata&& jobsettingsdata.data === undefined ? "" : jobsettingsdata&& jobsettingsdata.data.id}/commitsummary/${this.state.props.match.params.homeworkid}`}>{ jobsettingsdata&& jobsettingsdata.data.commit_des}</a>
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
// { jobsettingsdata&&jobsettingsdata.data === undefined ? "" : <Startshixuntask
|
|
|
|
|
|
|
|
// {...this.props}
|
|
|
|
|
|
|
|
// data={ jobsettingsdata&& jobsettingsdata.data}
|
|
|
|
|
|
|
|
// />}
|
|
|
|
|
|
|
|
{/* </div>*/}
|
|
|
|
|
|
|
|
{/*</div>*/}
|
|
|
|