dev_unstable
hjm 6 years ago
parent da0863751c
commit dae6ee08e0

@ -236,6 +236,12 @@ class BoardsNew extends Component{
title_num: 60 - parseInt(e.target.value.length) title_num: 60 - parseInt(e.target.value.length)
}) })
} }
goBack = () => {
// this.props.history.goBack()
const courseId=this.props.match.params.coursesId;
const boardId = this.props.match.params.boardId
this.props.toListPage(courseId, boardId)
}
render() { render() {
let { addGroup, fileList, course_id, title_num } = this.state; let { addGroup, fileList, course_id, title_num } = this.state;
const { getFieldDecorator } = this.props.form; const { getFieldDecorator } = this.props.form;
@ -309,8 +315,8 @@ class BoardsNew extends Component{
<p className="clearfix mt20 mb20"> <p className="clearfix mt20 mb20">
<span className="fl font-24 color-grey-3">{this.isEdit ? "编辑" : "新建"}帖子</span> <span className="fl font-24 color-grey-3">{this.isEdit ? "编辑" : "新建"}帖子</span>
<a href="javascript:void(0)" className="color-grey-6 fr font-16 mr2" <a href="javascript:void(0)" className="color-grey-6 fr font-16 mr2"
onClick={() => this.props.history.goBack()}> onClick={this.goBack}>
{/*返回*/} 返回
</a> </a>
</p> </p>
{/* notRequired */} {/* notRequired */}

@ -75,15 +75,15 @@ class CommonWorkDetailIndex extends Component{
}) })
} }
goback = () => { goback = () => {
// let workId=this.props.match.params.workId; let workId=this.props.match.params.workId;
// //
// if ( window.location.pathname.indexOf('appraise') == -1) { if ( window.location.pathname.indexOf('appraise') == -1) {
// let category_id= this.state.category.category_id; let category_id= this.state.category.category_id;
// this.props.toListPage(this.props.match.params, category_id) this.props.toListPage(this.props.match.params, category_id)
// } else { } else {
// this.props.toWorkListPage(this.props.match.params, workId) this.props.toWorkListPage(this.props.match.params, workId)
// } }
this.props.history.goBack() // this.props.history.goBack()
} }
// 补交附件 // 补交附件

@ -418,7 +418,8 @@ class ExerciceNew extends Component{
<p className="clearfix mt20 mb20"> <p className="clearfix mt20 mb20">
<span className="fl font-24 color-grey-3">{this.isEdit ? "编辑" : "新建"}试卷</span> <span className="fl font-24 color-grey-3">{this.isEdit ? "编辑" : "新建"}试卷</span>
<a href="javascript:void(0)" className="color-grey-6 fr font-16 mr2" <a href="javascript:void(0)" className="color-grey-6 fr font-16 mr2"
onClick={() => this.props.history.length == 1 ? this.props.history.push(`/courses/${courseId}/exercises/${left_banner_id}`): this.props.history.goBack()}> // () => this.props.history.length == 1 ? : this.props.history.goBack()
onClick={() => this.props.history.push(`/courses/${courseId}/exercises/${left_banner_id}`)}>
返回 返回
</a> </a>
</p> </p>

Loading…
Cancel
Save