Merge remote-tracking branch 'origin/master'

dev_forum
杨树明 6 years ago
commit 2cf4eccc46

@ -102,6 +102,7 @@ export function initAxiosInterceptors(props) {
if(response===undefined){ if(response===undefined){
return return
} }
const config = response.config
if (response.data.status === -1) { if (response.data.status === -1) {
// console.error('error:', response.data.message) // console.error('error:', response.data.message)
// throw new Error() // throw new Error()

@ -243,6 +243,12 @@ class CommonWorkDetailIndex extends Component{
{work_statuses && work_statuses.indexOf('提交作品') != -1 && <a className={"fr color-blue font-16"} href={"javascript:void(0)"} {work_statuses && work_statuses.indexOf('提交作品') != -1 && <a className={"fr color-blue font-16"} href={"javascript:void(0)"}
onClick={() => { this.props.toWorkPostPage(this.props.match.params)}} onClick={() => { this.props.toWorkPostPage(this.props.match.params)}}
>提交作品</a>} >提交作品</a>}
{ work_statuses && work_statuses.indexOf('补交作品') != -1 &&
<a className={"fr color-blue font-16"} href={"javascript:void(0)"}
onClick={() => { this.props.toWorkPostPage(this.props.match.params, null, true, work_id)}}>
补交作品</a> }
{work_statuses && work_statuses.indexOf('修改作品') != -1 && <a className={"fr color-blue font-16"} href={"javascript:void(0)"} {work_statuses && work_statuses.indexOf('修改作品') != -1 && <a className={"fr color-blue font-16"} href={"javascript:void(0)"}
onClick={() => { this.props.toWorkPostPage(this.props.match.params, null, true, work_id)}} onClick={() => { this.props.toWorkPostPage(this.props.match.params, null, true, work_id)}}
>修改作品</a>} >修改作品</a>}

@ -234,7 +234,7 @@ function buildColumns(that, student_works) {
<span> <span>
<Tooltip title={ <Tooltip title={
getScoreTip(student_score, getScoreTip(student_score,
isNiPing ? `你的评阅分数:${record.student_score}` : <div> that.state.is_evaluation ? `你的评阅分数:${record.student_score}` : <div>
{record.student_comment_count && <div>{`${record.student_comment_count}名学生进行了匿评`}</div>} {record.student_comment_count && <div>{`${record.student_comment_count}名学生进行了匿评`}</div>}
<div>有效平均分{record.student_score}</div> <div>有效平均分{record.student_score}</div>
</div> </div>
@ -334,7 +334,7 @@ const orderMap = {
work_score: 'asc', work_score: 'asc',
student_id: 'asc', student_id: 'asc',
} }
const PAGE_SIZE = 50 const PAGE_SIZE = 20
// 类似页面 http://localhost:3007/courses/1309/graduation/graduation_tasks/48/76/setting // 类似页面 http://localhost:3007/courses/1309/graduation/graduation_tasks/48/76/setting
class CommonWorkList extends Component{ class CommonWorkList extends Component{
@ -564,6 +564,19 @@ class CommonWorkList extends Component{
} }
}) })
// time_status int 时间对应的状态: 0未发布1:提交中2:补交中3:匿评中4:申诉中5:评阅中6:已结束
let timeMsg = '提交剩余时间'
if (time_status === 1) {
} else if (time_status === 2) {
timeMsg = '补交剩余时间'
} else if (time_status === 3) {
timeMsg = '匿评剩余时间'
} else if (time_status === 4) {
timeMsg = '申诉剩余时间'
}
// console.log(StudentData) // console.log(StudentData)
// console.log(student_works) // console.log(student_works)
return( return(
@ -638,7 +651,7 @@ class CommonWorkList extends Component{
(!!commit_count || !!uncommit_count) && (!!commit_count || !!uncommit_count) &&
<React.Fragment> <React.Fragment>
<span className="color-orange-tip">{commit_count}</span> {uncommit_count}  <span className="color-orange-tip">{commit_count}</span> {uncommit_count} 
{time_status===5?"":"剩余提交时间"} {timeMsg || ''}
<span className="color-orange-tip">{left_time.time}</span> <span className="color-orange-tip">{left_time.time}</span>
</React.Fragment> </React.Fragment>
} }

@ -88,10 +88,14 @@ class commonWork extends Component{
let {page,search,order}=this.state; let {page,search,order}=this.state;
this.getList(page,search,order); this.getList(page,search,order);
} }
useBankSuccess = () => { useBankSuccess = (checkBoxValues, newWorkIdArray) => {
this.setState({ this.setState({
page:1 page:1,
checkBoxValues: newWorkIdArray
}, () => {
this.refs['publishModalRef'].open()
}) })
let {search, order}=this.state; let {search, order}=this.state;
this.getList(1, search, order); this.getList(1, search, order);
} }
@ -418,7 +422,7 @@ class commonWork extends Component{
onClick={this.onWorkDelete}>删除</a> onClick={this.onWorkDelete}>删除</a>
</li> </li>
<li className="li_line"> <li className="li_line">
<PublishRightnow showActionButton={true} {...this.props} checkBoxValues={checkBoxValues} <PublishRightnow ref="publishModalRef" showActionButton={true} {...this.props} checkBoxValues={checkBoxValues}
isPublish={true} doWhenSuccess={this.doWhenSuccess} fromListPage={true}></PublishRightnow> isPublish={true} doWhenSuccess={this.doWhenSuccess} fromListPage={true}></PublishRightnow>
</li> </li>
<li className="li_line"> <li className="li_line">

@ -160,7 +160,6 @@ class GraduationTasksappraiseReply extends Component{
<React.Fragment> <React.Fragment>
{comment_scores.length===0&&isStudent===true||comment_scores.length===0&&isNotMember===true? "": <div className="edu-back-white padding20-30" style={{marginTop: '16px'}}> {comment_scores.length===0&&isStudent===true||comment_scores.length===0&&isNotMember===true? "": <div className="edu-back-white padding20-30" style={{marginTop: '16px'}}>
{isStudent===true? {isStudent===true?
<GraduationTasksappraiseReplyChild <GraduationTasksappraiseReplyChild
{...this.props} {...this.props}
{...this.state} {...this.state}
@ -170,8 +169,7 @@ class GraduationTasksappraiseReply extends Component{
addSuccess={this.addSuccess} addSuccess={this.addSuccess}
onDelete={this.onDelete} onDelete={this.onDelete}
/> />
: : <GraduationTasksappraiseReplyChild {...this.state} {...this.props}
<GraduationTasksappraiseReplyChild {...this.state} {...this.props}
cancelmodel={this.cancelmodel} cancelmodel={this.cancelmodel}
showModulationtype={(id)=>this.showModulationtype(id)} showModulationtype={(id)=>this.showModulationtype(id)}
saveModulationModal={(value,num)=>this.saveModulationModal(value,num)} saveModulationModal={(value,num)=>this.saveModulationModal(value,num)}

@ -80,10 +80,11 @@ class GraduateTopicDetailTable extends Component{
} }
sureAgreeTopic=(count)=>{ sureAgreeTopic=(count)=>{
if(count > 0){ if(count > 0){
debugger
let{tableData}=this.props; let{tableData}=this.props;
let{operationId,classesId}=this.state let{operationId,classesId}=this.state
let courseId=this.props.match.params.course_id; let courseId=this.props.match.params.course_id;
let name=tableData.group_list.filter(item=>item.course_group_id==classesId)[0].group_name; let name=tableData.group_list.filter(item=>item.group_id==classesId)[0].group_name;
this.agreeChoose(courseId,operationId,classesId,name); this.agreeChoose(courseId,operationId,classesId,name);
}else{ }else{
this.setState({ this.setState({

@ -1747,7 +1747,7 @@ class Trainingjobsetting extends Component {
<div> <div>
<div className="clearfix mb5 ml15"> <div className="clearfix mb5 ml15">
<span className="font-16 mr15 fl mt6" style={{"color":"#999999"}}>发布时间</span> <span className="font-16 mr15 fl mt6" style={{"color":"#999999"}}>发布时间</span>
<Tooltip placement="bottom" title={this.props.isSuperAdmin() ? "" : starttimetype === true ? "发布时间已过,则不能修改" : ""}></Tooltip> <Tooltip placement="bottom" title={this.props.isSuperAdmin() ? "" : !flagPageEditstwo === true ? "发布时间已过,则不能修改" : ""}>
<div className="fl"> <div className="fl">
<DatePicker <DatePicker
showToday={false} showToday={false}
@ -1775,11 +1775,12 @@ class Trainingjobsetting extends Component {
} }
</p> </p>
</div> </div>
</Tooltip>
<span className="ml20 fl mt10" style={{"color":"#999999","text-align":"left","font-size":"14px"}}>(学生收到作业的时间)</span> <span className="ml20 fl mt10" style={{"color":"#999999","text-align":"left","font-size":"14px"}}>(学生收到作业的时间)</span>
</div> </div>
<div className="clearfix ml15"> <div className="clearfix ml15">
<span className="mr15 fl mt10 font-16" style={{"color":"#999999"}}>截止时间</span> <span className="mr15 fl mt10 font-16" style={{"color":"#999999"}}>截止时间</span>
<Tooltip placement="bottom" title={this.props.isSuperAdmin() ? "" : starttimetype === true ? "截止时间已过,则不能修改" : ""}> </Tooltip> <Tooltip placement="bottom" title={this.props.isSuperAdmin() ? "" : !flagPageEditsthrees === true ? "截止时间已过,则不能修改" : ""}>
<div className="fl"> <div className="fl">
<DatePicker <DatePicker
showToday={false} showToday={false}
@ -1807,6 +1808,7 @@ class Trainingjobsetting extends Component {
} }
</p> </p>
</div> </div>
</Tooltip>
<span className=" ml20 fl mt10 color-grey-9" style={{"text-align":"left","font-size":"14px"}}>(学生按时提交作品的时间截点)</span> <span className=" ml20 fl mt10 color-grey-9" style={{"text-align":"left","font-size":"14px"}}>(学生按时提交作品的时间截点)</span>
</div> </div>
</div> </div>
@ -1924,7 +1926,7 @@ class Trainingjobsetting extends Component {
checked={this.state.completionefficiencyscore} style={{"color":"#666666"}}>效率分<span checked={this.state.completionefficiencyscore} style={{"color":"#666666"}}>效率分<span
className={"font-14 color-grey-9 font-14 ml15"} style={{"text-align":"left"}}>(选中则学生最终成绩包含效率分)</span></Checkbox> className={"font-14 color-grey-9 font-14 ml15"} style={{"text-align":"left"}}>(选中则学生最终成绩包含效率分)</span></Checkbox>
</div> </div>
<div className="ml80 mt30"> <div className="ml85 mt30">
<span className="c_grey mr10" style={{"color":"#999999"}}>分值</span> <span className="c_grey mr10" style={{"color":"#999999"}}>分值</span>
<InputNumber min={0} disabled={!flagPageEdit} max={100} className="ml10 h40 mr10 color-grey-9" <InputNumber min={0} disabled={!flagPageEdit} max={100} className="ml10 h40 mr10 color-grey-9"
style={{width: "100px","color":"#999999"}} style={{width: "100px","color":"#999999"}}

@ -1,5 +1,5 @@
.dialogBox{ .dialogBox{
height: 370px; height: 338px;
} }
.dialogBox2{ .dialogBox2{
height: 420px; height: 420px;

@ -268,25 +268,23 @@ class Trialapplication extends Component {
reason: this.state.reason, reason: this.state.reason,
}).then((result) => { }).then((result) => {
// console.log(result); // console.log(result);
try {
// this.onTabChange("1"); // this.onTabChange("1");
thiss.props.showNotification(`试用申请已提交,我们将尽快完成审核`); if(result !== undefined){
if (thiss.state.showTrial === false) { this.props.showNotification(`试用申请已提交,我们将尽快完成审核`);
if (this.state.showTrial === false) {
window.location.href = "/"; window.location.href = "/";
thiss.setState({ this.setState({
isRenders: false isRenders: false
}) })
thiss.Cancel(); this.Cancel();
} else { } else {
thiss.setState({ this.setState({
isRenders: false isRenders: false
}) })
thiss.Cancel(); this.Cancel();
} }
} catch (e) {
} }
}).catch((error) => { }).catch((error) => {

@ -198,7 +198,7 @@ class UpdateDrawer extends Component {
} }
</div> </div>
</DialogContent> </DialogContent>
<DialogActions id="dialog-actions"> <DialogActions id="dialog-actions" style={{ 'margin-bottom': '16px'}}>
{ needUpdateScript ? { needUpdateScript ?
<React.Fragment> <React.Fragment>
<Button <Button

Loading…
Cancel
Save