Merge branch 'MDL-39422-23' of git://github.com/danpoltawski/moodle into MOODLE_23_STABLE
This commit is contained in:
Vendored
+2
-1
@@ -509,7 +509,8 @@ YUI.add('moodle-course-toolboxes', function(Y) {
|
||||
'name' : 'title',
|
||||
'value' : titletext,
|
||||
'autocomplete' : 'off',
|
||||
'aria-describedby' : 'id_editinstructions'
|
||||
'aria-describedby' : 'id_editinstructions',
|
||||
'maxLength' : '255'
|
||||
})
|
||||
.addClass('titleeditor');
|
||||
var editform = Y.Node.create('<form />')
|
||||
|
||||
@@ -57,6 +57,7 @@ class mod_assign_mod_form extends moodleform_mod {
|
||||
$mform->setType('name', PARAM_CLEANHTML);
|
||||
}
|
||||
$mform->addRule('name', null, 'required', null, 'client');
|
||||
$mform->addRule('name', get_string('maximumchars', '', 255), 'maxlength', 255, 'client');
|
||||
|
||||
$this->add_intro_editor(true, get_string('description', 'assign'));
|
||||
|
||||
|
||||
@@ -45,6 +45,7 @@ class mod_assignment_mod_form extends moodleform_mod {
|
||||
$mform->setType('name', PARAM_CLEANHTML);
|
||||
}
|
||||
$mform->addRule('name', null, 'required', null, 'client');
|
||||
$mform->addRule('name', get_string('maximumchars', '', 255), 'maxlength', 255, 'client');
|
||||
|
||||
$this->add_intro_editor(true, get_string('description', 'assignment'));
|
||||
|
||||
|
||||
@@ -45,6 +45,7 @@ class mod_book_mod_form extends moodleform_mod {
|
||||
$mform->setType('name', PARAM_CLEANHTML);
|
||||
}
|
||||
$mform->addRule('name', null, 'required', null, 'client');
|
||||
$mform->addRule('name', get_string('maximumchars', '', 255), 'maxlength', 255, 'client');
|
||||
$this->add_intro_editor($config->requiremodintro, get_string('moduleintro'));
|
||||
|
||||
$alloptions = book_get_numbering_types();
|
||||
|
||||
@@ -22,6 +22,7 @@ class mod_chat_mod_form extends moodleform_mod {
|
||||
$mform->setType('name', PARAM_CLEANHTML);
|
||||
}
|
||||
$mform->addRule('name', null, 'required', null, 'client');
|
||||
$mform->addRule('name', get_string('maximumchars', '', 255), 'maxlength', 255, 'client');
|
||||
|
||||
$this->add_intro_editor(true, get_string('chatintro', 'chat'));
|
||||
|
||||
|
||||
@@ -22,6 +22,7 @@ class mod_choice_mod_form extends moodleform_mod {
|
||||
$mform->setType('name', PARAM_CLEANHTML);
|
||||
}
|
||||
$mform->addRule('name', null, 'required', null, 'client');
|
||||
$mform->addRule('name', get_string('maximumchars', '', 255), 'maxlength', 255, 'client');
|
||||
|
||||
$this->add_intro_editor(true, get_string('chatintro', 'chat'));
|
||||
|
||||
|
||||
@@ -22,6 +22,7 @@ class mod_data_mod_form extends moodleform_mod {
|
||||
$mform->setType('name', PARAM_CLEANHTML);
|
||||
}
|
||||
$mform->addRule('name', null, 'required', null, 'client');
|
||||
$mform->addRule('name', get_string('maximumchars', '', 255), 'maxlength', 255, 'client');
|
||||
|
||||
$this->add_intro_editor(true, get_string('intro', 'data'));
|
||||
|
||||
|
||||
@@ -44,6 +44,7 @@ class mod_feedback_mod_form extends moodleform_mod {
|
||||
$mform->addElement('text', 'name', get_string('name', 'feedback'), array('size'=>'64'));
|
||||
$mform->setType('name', PARAM_TEXT);
|
||||
$mform->addRule('name', null, 'required', null, 'client');
|
||||
$mform->addRule('name', get_string('maximumchars', '', 255), 'maxlength', 255, 'client');
|
||||
|
||||
$this->add_intro_editor(true, get_string('description', 'feedback'));
|
||||
|
||||
|
||||
@@ -44,6 +44,7 @@ class mod_folder_mod_form extends moodleform_mod {
|
||||
$mform->setType('name', PARAM_CLEANHTML);
|
||||
}
|
||||
$mform->addRule('name', null, 'required', null, 'client');
|
||||
$mform->addRule('name', get_string('maximumchars', '', 255), 'maxlength', 255, 'client');
|
||||
$this->add_intro_editor($config->requiremodintro);
|
||||
|
||||
//-------------------------------------------------------
|
||||
|
||||
@@ -22,6 +22,7 @@ class mod_glossary_mod_form extends moodleform_mod {
|
||||
$mform->setType('name', PARAM_CLEANHTML);
|
||||
}
|
||||
$mform->addRule('name', null, 'required', null, 'client');
|
||||
$mform->addRule('name', get_string('maximumchars', '', 255), 'maxlength', 255, 'client');
|
||||
|
||||
$this->add_intro_editor(true);
|
||||
|
||||
|
||||
@@ -45,6 +45,7 @@ class mod_imscp_mod_form extends moodleform_mod {
|
||||
$mform->setType('name', PARAM_CLEANHTML);
|
||||
}
|
||||
$mform->addRule('name', null, 'required', null, 'client');
|
||||
$mform->addRule('name', get_string('maximumchars', '', 255), 'maxlength', 255, 'client');
|
||||
$this->add_intro_editor($config->requiremodintro);
|
||||
|
||||
//-------------------------------------------------------
|
||||
|
||||
@@ -89,6 +89,7 @@ class mod_lesson_mod_form extends moodleform_mod {
|
||||
$mform->setType('name', PARAM_CLEANHTML);
|
||||
}
|
||||
$mform->addRule('name', null, 'required', null, 'client');
|
||||
$mform->addRule('name', get_string('maximumchars', '', 255), 'maxlength', 255, 'client');
|
||||
|
||||
// Create a text box that can be enabled/disabled for lesson time limit
|
||||
$timedgrp = array();
|
||||
|
||||
@@ -67,6 +67,7 @@ class mod_lti_mod_form extends moodleform_mod {
|
||||
$mform->addElement('text', 'name', get_string('basicltiname', 'lti'), array('size'=>'64'));
|
||||
$mform->setType('name', PARAM_TEXT);
|
||||
$mform->addRule('name', null, 'required', null, 'client');
|
||||
$mform->addRule('name', get_string('maximumchars', '', 255), 'maxlength', 255, 'client');
|
||||
// Adding the optional "intro" and "introformat" pair of fields
|
||||
$this->add_intro_editor(false, get_string('basicltiintro', 'lti'));
|
||||
$mform->setAdvanced('introeditor');
|
||||
|
||||
@@ -47,6 +47,7 @@ class mod_page_mod_form extends moodleform_mod {
|
||||
$mform->setType('name', PARAM_CLEANHTML);
|
||||
}
|
||||
$mform->addRule('name', null, 'required', null, 'client');
|
||||
$mform->addRule('name', get_string('maximumchars', '', 255), 'maxlength', 255, 'client');
|
||||
$this->add_intro_editor($config->requiremodintro);
|
||||
|
||||
//-------------------------------------------------------
|
||||
|
||||
@@ -69,6 +69,7 @@ class mod_quiz_mod_form extends moodleform_mod {
|
||||
$mform->setType('name', PARAM_CLEANHTML);
|
||||
}
|
||||
$mform->addRule('name', null, 'required', null, 'client');
|
||||
$mform->addRule('name', get_string('maximumchars', '', 255), 'maxlength', 255, 'client');
|
||||
|
||||
// Introduction.
|
||||
$this->add_intro_editor(false, get_string('introduction', 'quiz'));
|
||||
|
||||
@@ -55,6 +55,7 @@ class mod_resource_mod_form extends moodleform_mod {
|
||||
$mform->setType('name', PARAM_CLEANHTML);
|
||||
}
|
||||
$mform->addRule('name', null, 'required', null, 'client');
|
||||
$mform->addRule('name', get_string('maximumchars', '', 255), 'maxlength', 255, 'client');
|
||||
$this->add_intro_editor($config->requiremodintro);
|
||||
|
||||
//-------------------------------------------------------
|
||||
|
||||
@@ -43,6 +43,7 @@ class mod_scorm_mod_form extends moodleform_mod {
|
||||
$mform->setType('name', PARAM_CLEANHTML);
|
||||
}
|
||||
$mform->addRule('name', null, 'required', null, 'client');
|
||||
$mform->addRule('name', get_string('maximumchars', '', 255), 'maxlength', 255, 'client');
|
||||
|
||||
// Summary
|
||||
$this->add_intro_editor(true);
|
||||
|
||||
@@ -45,6 +45,7 @@ class mod_url_mod_form extends moodleform_mod {
|
||||
$mform->setType('name', PARAM_CLEANHTML);
|
||||
}
|
||||
$mform->addRule('name', null, 'required', null, 'client');
|
||||
$mform->addRule('name', get_string('maximumchars', '', 255), 'maxlength', 255, 'client');
|
||||
$this->add_intro_editor($config->requiremodintro);
|
||||
|
||||
//-------------------------------------------------------
|
||||
|
||||
@@ -53,6 +53,7 @@ class mod_wiki_mod_form extends moodleform_mod {
|
||||
$mform->addElement('text', 'name', get_string('wikiname', 'wiki'), array('size' => '64'));
|
||||
$mform->setType('name', PARAM_TEXT);
|
||||
$mform->addRule('name', $required, 'required', null, 'client');
|
||||
$mform->addRule('name', get_string('maximumchars', '', 255), 'maxlength', 255, 'client');
|
||||
// Adding the optional "intro" and "introformat" pair of fields
|
||||
$this->add_intro_editor(true, get_string('wikiintro', 'wiki'));
|
||||
|
||||
|
||||
Reference in New Issue
Block a user