caishi 6 years ago
commit 3c0590086a

@ -67,7 +67,7 @@
<!-- <link rel="stylesheet" type="text/css" href="https://www.educoder.net/stylesheets/css/font-awesome.css?1510652321"> -->
<link rel="stylesheet" type="text/css" href="/stylesheets/educoder/iconfont/iconfont.css">
<link rel="stylesheet" type="text/css" href="http://47.96.87.25:48080/stylesheets/educoder/iconfont/iconfont.css">
<link rel="stylesheet" type="text/css" href="/css/iconfont.css">
<style>
/*<!--去除浏览器点击操作后有蓝色的底块-->*/

@ -78,6 +78,7 @@ class BoardsNew extends Component{
if (data) {
this.editTopic = data;
this.props.form.setFieldsValue({
sticky: !!data.sticky,
content: data.content,
subject: data.subject,
select_board_id: data.board_id // TODO 没返回给前端
@ -309,6 +310,14 @@ class BoardsNew extends Component{
label="标题"
className="topicTitle "
>
{getFieldDecorator('sticky', {
valuePropName: 'checked',
})(
<Checkbox style={{ right: '0px',
top: '-50px',
position: 'absolute'
}}>置顶</Checkbox>
)}
{getFieldDecorator('subject', {
rules: [{
required: true, message: '请输入标题',
@ -347,7 +356,7 @@ class BoardsNew extends Component{
)}
</Form.Item>
{ isAdmin && <Form.Item
{/* { isAdmin && <Form.Item
label=""
style={{ display: 'inline-block', marginLeft: "14px" }}
>
@ -355,7 +364,7 @@ class BoardsNew extends Component{
})(
<Checkbox>置顶</Checkbox>
)}
</Form.Item> }
</Form.Item> } */}
</div>
<style>{`
@ -380,6 +389,7 @@ class BoardsNew extends Component{
<Form.Item
label="内容"
className="mdInForm"
>
{getFieldDecorator('content', {
rules: [{

@ -1028,9 +1028,11 @@ class CommonWorkSetting extends Component{
<React.Fragment>
<div className={"h20 mb30 ml30"}>
<span>发布时间</span>
<Tooltip placement="bottom" title={this.props.isSuperAdmin()?"":publish_time_type===true?"发布时间已过,则不能修改":""}>
<span>
{/* <Tooltip placement="bottom" title={this.props.isSuperAdmin()?"":publish_time_type===true?"":""}>
</Tooltip> */}
<ConditionToolTip condition={moment(this.state.init_publish_time) < moment()} title={"时间已过,不能再修改"}>
<span>
<DatePicker
dropdownClassName="hideDisable"
@ -1051,17 +1053,18 @@ class CommonWorkSetting extends Component{
// return publish_time && publish_time < moment().add(-1, 'days'); }
// }
/>
</ConditionToolTip>
</span>
</Tooltip>
</ConditionToolTip>
<span className={"font-14 color-grey-9 ml10"}>学生收到作业的时间</span>
</div>
<div className={"h20 mb30 ml30"}>
<span>截止时间</span>
<Tooltip placement="bottom" title={this.props.isSuperAdmin()?"":end_time_type===true?"截止时间已过,则不能修改":""}>
<span>
{/* <Tooltip placement="bottom" title={this.props.isSuperAdmin()?"":end_time_type===true?"":""}>
</Tooltip> */}
<ConditionToolTip condition={moment(this.state.init_end_time) < moment()} title={"时间已过,不能再修改"}>
<span>
<DatePicker
dropdownClassName="hideDisable"
showTime={{ format: 'HH:mm' }}
@ -1087,9 +1090,9 @@ class CommonWorkSetting extends Component{
// return end_time.valueOf() < moment(publish_time, dateFormat).valueOf(); }
// }
/>
</ConditionToolTip>
</span>
</Tooltip>
</ConditionToolTip>
<span className={"font-14 color-grey-9 ml10"}>学生按时提交作品的时间截点</span>
</div>
@ -1133,6 +1136,7 @@ class CommonWorkSetting extends Component{
<div className={" mb10 ml30"}>
<span>结束时间</span>
<ConditionToolTip condition={moment(init_late_time) < moment()} title={"时间已过,不能再修改"}>
<span>
<DatePicker
showToday={false}
dropdownClassName="hideDisable"
@ -1153,6 +1157,7 @@ class CommonWorkSetting extends Component{
// return late_time < moment(end_time, dateFormat).add(-1, 'days'); }
// }
/>
</span>
</ConditionToolTip>
<span className={"font-14 color-grey-9 ml10"}>学生延时提交作品的时间截点</span>
{<div className={"latetimetype color-red "}>{latetimetype}</div>}
@ -1178,8 +1183,8 @@ class CommonWorkSetting extends Component{
<div className={"h20 mb30 ml60"}>
<span>开启时间</span>
<Tooltip placement="bottom" title={this.props.isSuperAdmin()?"":starttimetype===true?"发布时间已过,则不能修改":""}>
<span>
<ConditionToolTip condition={moment(init_evaluation_start) < moment()} title={"时间已过,不能再修改"}>
<span>
<DatePicker
dropdownClassName="hideDisable"
showTime={{ format: 'HH:mm' }}
@ -1200,16 +1205,17 @@ class CommonWorkSetting extends Component{
// return evaluation_start.valueOf() < moment(end_time, dateFormat).valueOf(); }
// }
/>
</ConditionToolTip>
</span>
</ConditionToolTip>
</Tooltip>
<span className={"font-14 color-grey-9 ml10"}>匿评开始时间之前提交作品的学生参与匿评</span>
</div>
<div className={"h20 mb30 ml60"}>
<span>结束时间</span>
<Tooltip placement="bottom" title={this.props.isSuperAdmin()?"":starttimetype===true?"发布时间已过,则不能修改":""}>
<span>
<ConditionToolTip condition={moment(init_evaluation_end) < moment()} title={"时间已过,不能再修改"}>
<span>
<DatePicker
dropdownClassName="hideDisable"
showTime={{ format: 'HH:mm' }}
@ -1230,15 +1236,18 @@ class CommonWorkSetting extends Component{
// return evaluation_end.valueOf() < moment(evaluation_start, dateFormat).valueOf(); }
// }
/>
</span>
</ConditionToolTip>
<span className={"font-14 color-grey-9 ml10"}>学生匿评TA人作品的时间截点</span>
</span>
</Tooltip>
<span className={"font-14 color-grey-9 ml10"}></span>
</div>
{<div className={" anonymous_comment_time_tip color-red ml60"} style={{marginTop: '-6px'}}>{anonymous_comment_time_tip}</div>}
{/* marginTop: '-6px' */}
{<div className={" anonymous_comment_time_tip color-red ml60"} style={{}}>{anonymous_comment_time_tip}</div>}
{/* 匿评数量 */}
<div className={"h20 mb30 ml60"}>
@ -1301,9 +1310,10 @@ class CommonWorkSetting extends Component{
{/* 启用匿评申述 结束时间: */}
<div className={"h20 mb30 ml60"}>
<span>结束时间</span>
<Tooltip placement="bottom" title={this.props.isSuperAdmin()?"":starttimetype===true?"发布时间已过,则不能修改":""}>
<span>
{/* <Tooltip placement="bottom" title={this.props.isSuperAdmin()?"":starttimetype===true?"":""}>
</Tooltip> */}
<ConditionToolTip condition={moment(init_appeal_time) < moment()} title={"时间已过,不能再修改"}>
<span>
<DatePicker
dropdownClassName="hideDisable"
showTime={{ format: 'HH:mm' }}
@ -1318,9 +1328,9 @@ class CommonWorkSetting extends Component{
onChange={this.appeal_time_change}
disabled={ (anonymous_appeal && !noAuth ? false : true) || moment(init_appeal_time) < moment()}
/>
</ConditionToolTip>
</span>
</Tooltip>
</ConditionToolTip>
<span className={"font-14 color-grey-9 ml10"}>学生提交匿评申诉的时间截点</span>
</div>

@ -945,11 +945,20 @@ a.white-btn.use_scope-btn:hover{
font-size: 12px !important;
}
/* md编辑器在form中时使用这个样式可以把错误信息绝对定位 */
/* 去掉form下边距 */
.mdInForm.ant-form-item {
margin-bottom: 0px;
}
.mdInForm .has-error .ant-form-explain {
position: absolute;
margin-top: -2px;
margin-left: -7px;
}
/* 课堂下统一的form样式前缀 courseForm */
.courseForm .ant-select-selection--single, .courseForm .ant-select-selection__rendered{
height: 40px;
line-height: 40px;
}
/*新建课堂*/

@ -734,13 +734,6 @@ class GraduationTaskssettinglist extends Component{
),
}, {
// finalscore: {work_score:worklists[i].final_score.work_score === null ? "--" : worklists[i].final_score.work_score,
// teacher_comment_score:worklists[i].teacher_comment_score,
// cross_comment_score:worklists[i].cross_comment_score,
// late_penalty:worklists[i].late_penalty
// },
title: '最终成绩',
key: 'finalscore',
dataIndex: 'finalscore',
@ -748,11 +741,11 @@ class GraduationTaskssettinglist extends Component{
render: (text, record) => (
<span>
<Tooltip placement="bottom" title={record.finalscore==="--"?"未评阅": <pre>
{record.final_score.username}{(record.final_score.login)}<br/>
{record.ultimate_score===true?"":"教师评分:"+record.final_score.teacher_comment_score+"分"}<br/>
{taskslistdata.cross_comment===true?"":"交叉评分:"+record.final_score.cross_comment_score+"分"}<br/>
{record.final_score.late_penalty===undefined?"":"迟交扣分:"+record.final_score.late_penalty+"分"}<br/>
最终成绩{record.final_score.work_score}<br/>
{record.finalscore.final_score.username}({record.finalscore.final_score.login})<br/>
{record.finalscore.ultimate_score===true?"":"教师评分:"+record.finalscore.teacher_comment_score+"分"}<br/>
{record.finalscore.cross_comment_score===undefined?"":"交叉评分:"+record.finalscore.cross_comment_score+"分"+<br/>}
{record.finalscore.late_penalty===undefined?"":"迟交扣分:"+record.finalscore.late_penalty+"分"+<br/>}
最终成绩{record.finalscore.work_score}<br/>
</pre>}>
<a style={{color:parseInt(record.finalscore.work_score)>90?'#DD1717':parseInt(record.finalscore.work_score)>60&&parseInt(record.finalscore.work_score)<90?"#FF6800":'#747A7F'}}>{record.finalscore.work_score==="--"?"--":record.finalscore.work_score}</a>
</Tooltip>

@ -779,13 +779,13 @@ class PollNew extends Component {
}
}
if (maxtie < 2) {
if (maxtie < 3) {
if (object.question.question_type === 1) {
this.props.showNotification(`选项不能少于2个!`);
this.props.showNotification(`选项不能少于3个!`);
return
} else if (object.question.question_type === 2) {
this.props.showNotification(`选项不能少于2个!`);
this.props.showNotification(`选项不能少于3个!`);
return
}
@ -1259,12 +1259,12 @@ class PollNew extends Component {
}
}
if (maxtie < 2) {
if (maxtie < 3) {
if (object.question.question_type === 1) {
this.props.showNotification('选项不能少于2个!');
this.props.showNotification('选项不能少于3个!');
return
} else if (object.question.question_type === 2) {
this.props.showNotification('选项不能少于2个!');
this.props.showNotification('选项不能少于3个!');
return
}
@ -2061,8 +2061,8 @@ class PollNew extends Component {
// console.log(this.state.adddom);
}
//提交题目//没有就创建新的题库,新建问题和保存题目不一样不能同时保存 这里只是新建 和编辑 标题和须知
submitQuestionnaire = () => {
//提交题目//没有就创建新的题库,新建问newz题和保存题目不一样不能同时保存 这里只是新建 和编辑 标题和须知
submitQuestionnaire = (mews) => {
console.log("调用了submitQuestionnaire")
if (this.state.Newedit === true) {
@ -2084,6 +2084,12 @@ class PollNew extends Component {
pollid = this.state.pollid;
}
if(mews ==="new"){
if(this.state.poll_questions&&this.state.poll_questions.length===0){
this.props.showNotification("至少创建1个题目");
return;
}
}
var url = `/polls/${pollid}.json`;
axios.put(url, {
@ -2483,7 +2489,7 @@ class PollNew extends Component {
}
</p>
<p className="mt20"> <span className="font-16 flex1" style={item.question.question_type === 1?{"white-space":"pre-wrap","word-break": "break-all","word-wrap": "break-word","float": "left","width":"1116px"}:item.question.question_type === 2? {"white-space":"pre-wrap","word-break": "break-all","word-wrap": "break-word","float": "left","width":"1120px"}: {"white-space":"pre-wrap","word-break": "break-all","word-wrap": "break-word"}}>{item.question.question_title}</span></p>
<p className="mt20"> <span className="font-16 flex1" style={{"white-space":"pre-wrap","word-break": "break-all","word-wrap": "break-word"}}>{item.question.question_title}</span></p>
{/*<pre className="mt20 mb20 font-16 break_word flex1">{item.question.question_title}</pre>*/}
{item.question.question_type === 1 ?
(<RadioGroup defaultChecked={false} disabled>
@ -2494,7 +2500,7 @@ class PollNew extends Component {
{/*<pre className={"break_word flex1 fl"}*/}
{/* style={{"text-align": "left"}}>{items.answer_text}</pre>*/}
{/*<span className={"break_word flex1"}><pre className={"break_word flex1"}>{items.answer_text}</pre> </span>*/}
<span className={" flex1 "} style={{"text-align": "left","white-space":"pre-wrap","word-break": "break-all","word-wrap": "break-word"}} >{items.answer_text}</span>
<span className={" flex1 "} style={{"text-align": "left","white-space":"pre-wrap","word-break": "break-all","word-wrap": "break-word","float": "left","width":"1116px"}} >{items.answer_text}</span>
</div>
)
@ -2506,7 +2512,7 @@ class PollNew extends Component {
return (
<div className="mt10 mt20 mb20 " style={{"clear": "both"}}>
<Checkbox value={i} className={"fl"} style={{"text-align": "left"}}></Checkbox>
<span className={" flex1"} style={{"text-align": "left","white-space":"pre-wrap","word-break": "break-all","word-wrap": "break-word"}}>{items.answer_text}</span>
<span className={" flex1"} style={{"text-align": "left","white-space":"pre-wrap","word-break": "break-all","word-wrap": "break-word","float": "left","width":"1120px"}}>{items.answer_text}</span>
{/*<span*/}
{/* className={"break_word flex1 fl"} style={{"text-align": "left"}}><pre*/}
@ -2804,9 +2810,9 @@ class PollNew extends Component {
}}
>
<li className="clearfix mt30 mb50">
<a type="primary" className="defalutSubmitbtn fl mr20"
onClick={() => this.submitQuestionnaire()}>提交</a>
<a className="defalutCancelbtn fl" onClick={() => this.props.history.goBack()}>取消</ a>
<a className="defalutCancelbtn fl mr20" onClick={() => this.props.history.goBack()}>取消</a>
<a type="primary" className="defalutSubmitbtn fl"
onClick={() => this.submitQuestionnaire(this.props.match.params.news)}>提交</a>
</li>
@ -2823,9 +2829,9 @@ class PollNew extends Component {
}}
>
<li className="clearfix mt30 mb50">
<a className="defalutSubmitbtn fl mr20"onClick={() => this.props.history.goBack()}>取消</a>
<a type="primary" className="defalutCancelbtn fl"
onClick={() => this.submitQuestionnaire()}>提交</a>
<a className="defalutCancelbtn fl mr20"onClick={() => this.props.history.goBack()}>取消</a>
<a type="primary" className=" defalutSubmitbtn fl"
onClick={() => this.submitQuestionnaire(this.props.match.params.news)}>提交</a>
</li>
</div>
}

@ -36,7 +36,6 @@ class TraineetraininginformationModal extends Component {
props: this.props,
userids: this.props.userids,
game_list:this.props.game_list,
boolgalist:this.props.boolgalist,
experience:this.props.experience,
})
@ -52,26 +51,26 @@ class TraineetraininginformationModal extends Component {
// this.seacthdata();
}
componentWillReceiveProps(nextProps) {
// console.log("46");
// console.log(nextProps);
// console.log(this.props);
if (nextProps.boolgalist != this.props.boolgalist) {
// console.log("50");
// console.log(nextProps.user);
if (nextProps.boolgalist !== undefined) {
// console.log("53");
// console.log(nextProps.user);
this.setState({
boolgalist: nextProps.boolgalist,
})
}
}
}
// componentWillReceiveProps(nextProps) {
// // console.log("46");
// // console.log(nextProps);
// // console.log(this.props);
// if (nextProps.boolgalist != this.props.boolgalist) {
// // console.log("50");
// // console.log(nextProps.user);
// if (nextProps.boolgalist !== undefined) {
// // console.log("53");
// // console.log(nextProps.user);
// this.setState({
// boolgalist: nextProps.boolgalist,
// })
// }
//
//
// }
//
//
// }
LimitNumber=(txt)=> {
var str = txt;
if(str.length>25){
@ -81,7 +80,7 @@ class TraineetraininginformationModal extends Component {
}
render() {
var columns;
if(this.state.boolgalist&&this.state.boolgalist === true) {
if(this.props.boolgalist&&this.props.boolgalist === true) {
columns = [
{
title: '关卡',

@ -33,8 +33,10 @@ if (!window['indexHOCLoaded']) {
$('head').append($('<link rel="stylesheet" type="text/css" />')
.attr('href', `${_url_origin}/stylesheets/educoder/edu-main.css?1525440977`));
$('head').append($('<link rel="stylesheet" type="text/css" />')
.attr('href', `${_url_origin}/stylesheets/educoder/edu-all.css?1525440977`));
// index.html有加载
// $('head').append($('<link rel="stylesheet" type="text/css" />')
// .attr('href', `${_url_origin}/stylesheets/educoder/edu-all.css?1525440977`));
// $('head').append($('<link rel="stylesheet" type="text/css" />')
// .attr('href', `${_url_origin}/stylesheets/educoder/css_min_all.css?1525440977`));

@ -302,8 +302,8 @@ export default class TPMMDEditor extends Component {
</div>
</div>
<div className={"fr rememberTip"}>
{noStorage == true ? '' : <p id={`e_tip_mdEditor_${mdID}`} className="edu-txt-right color-grey-cd font-12"></p>}
{noStorage == true ? '' : <p id={`e_tips_mdEditor_${mdID}`} className="edu-txt-right color-grey-cd font-12"></p>}
{noStorage == true ? ' ' : <p id={`e_tip_mdEditor_${mdID}`} className="edu-txt-right color-grey-cd font-12"></p>}
{noStorage == true ? ' ' : <p id={`e_tips_mdEditor_${mdID}`} className="edu-txt-right color-grey-cd font-12"></p>}
</div>
</React.Fragment>
)

Loading…
Cancel
Save