MDL-9447 - Default grade field is redundant in embeded answer (Cloze) question. Merged from MOODLE_18_STABLE.
This commit is contained in:
@@ -68,7 +68,7 @@ if ($wizardnow!==''){
|
||||
$mform = $QTYPES[$question->qtype]->next_wizard_form('question.php', $question, $wizardnow);
|
||||
}
|
||||
} else {
|
||||
$mform = $QTYPES[$question->qtype]->create_editing_form('question.php', $question, $category->course);
|
||||
$mform = $QTYPES[$question->qtype]->create_editing_form('question.php', $question);
|
||||
}
|
||||
|
||||
if ($mform === null) {
|
||||
|
||||
@@ -19,6 +19,9 @@ class question_edit_multianswer_form extends question_edit_form {
|
||||
parent::definition();
|
||||
$mform =& $this->_form;
|
||||
$mform->addRule('questiontext', null, 'required', null, 'client');
|
||||
|
||||
// Remove meaningless defaultgrade field.
|
||||
$mform->removeElement('defaultgrade');
|
||||
}
|
||||
function set_data($question) {
|
||||
if (isset($question->id) and $question->id and $question->qtype and $question->questiontext) {
|
||||
|
||||
Reference in New Issue
Block a user