From 341958003b1063f32687ed772dbf31c245af4d99 Mon Sep 17 00:00:00 2001 From: hjm <63528605@qq.com> Date: Fri, 28 Jun 2019 09:29:40 +0800 Subject: [PATCH] =?UTF-8?q?=E9=A2=84=E8=A7=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/modules/courses/exercise/ExerciseNew.js | 14 +++++++++++++- .../modules/courses/exercise/new/NullDisplay.js | 4 +++- 2 files changed, 16 insertions(+), 2 deletions(-) diff --git a/public/react/src/modules/courses/exercise/ExerciseNew.js b/public/react/src/modules/courses/exercise/ExerciseNew.js index 8bc7ed6ae..0e1489c72 100644 --- a/public/react/src/modules/courses/exercise/ExerciseNew.js +++ b/public/react/src/modules/courses/exercise/ExerciseNew.js @@ -342,6 +342,11 @@ class ExerciceNew extends Component{ this.editingId = null; this.fetchExercise() } + goToPreview = () => { + const exercise_id = this.props.match.params.Id + const courseId = this.props.match.params.coursesId + this.props.history.push(`/courses/${courseId}/exercises/${exercise_id}/student_exercise_list?tab=2`) + } render() { let { exercise_name, exercise_description, course_id, exercise_types, exercise_questions, left_banner_id } = this.state; @@ -366,6 +371,8 @@ class ExerciceNew extends Component{ const isAdmin = this.props.isAdmin() const courseId=this.props.match.params.coursesId; + const exercise_id = this.props.match.params.Id + const isEdit = this.isEdit const commonHandler = { onQestionDelete: this.onQestionDelete, @@ -395,7 +402,7 @@ class ExerciceNew extends Component{ background: #fff; } .exerciseNew .markdown-body { - max-width: 1088px; + max-width: 1128px; } `}