From cda62a3829ffdbc971cfded244c99916f6382667 Mon Sep 17 00:00:00 2001 From: Tim Hunt Date: Tue, 21 Oct 2014 15:03:20 +0100 Subject: [PATCH] MDL-47791 question editing: remove permission info from above the form This information is not really meaningful for users, and takes up prime real-estate, so we are removing it. --- question/type/questiontypebase.php | 23 ----------------------- question/type/random/questiontype.php | 7 ------- 2 files changed, 30 deletions(-) diff --git a/question/type/questiontypebase.php b/question/type/questiontypebase.php index 256ebe561ea..7c70a6acdc6 100644 --- a/question/type/questiontypebase.php +++ b/question/type/questiontypebase.php @@ -244,30 +244,7 @@ class question_type { public function display_question_editing_page($mform, $question, $wizardnow) { global $OUTPUT; $heading = $this->get_heading(empty($question->id)); - echo $OUTPUT->heading_with_help($heading, 'pluginname', $this->plugin_name()); - - $permissionstrs = array(); - if (!empty($question->id)) { - if ($question->formoptions->canedit) { - $permissionstrs[] = get_string('permissionedit', 'question'); - } - if ($question->formoptions->canmove) { - $permissionstrs[] = get_string('permissionmove', 'question'); - } - if ($question->formoptions->cansaveasnew) { - $permissionstrs[] = get_string('permissionsaveasnew', 'question'); - } - } - if (count($permissionstrs)) { - echo $OUTPUT->heading(get_string('permissionto', 'question'), 3); - $html = ''; - echo $OUTPUT->box($html, 'boxwidthnarrow boxaligncenter generalbox'); - } $mform->display(); } diff --git a/question/type/random/questiontype.php b/question/type/random/questiontype.php index 3d1f0b7539a..107e647acd1 100644 --- a/question/type/random/questiontype.php +++ b/question/type/random/questiontype.php @@ -115,13 +115,6 @@ class qtype_random extends question_type { $this->manualqtypes = implode(',', $manualqtypes); } - public function display_question_editing_page($mform, $question, $wizardnow) { - global $OUTPUT; - $heading = $this->get_heading(empty($question->id)); - echo $OUTPUT->heading_with_help($heading, 'pluginname', $this->plugin_name()); - $mform->display(); - } - public function get_question_options($question) { return true; }