mirror of
https://github.com/moodle/moodle.git
synced 2025-04-21 08:22:07 +02:00
Merge branch 'MDL-39422-master' of git://github.com/danpoltawski/moodle
Conflicts: mod/wiki/mod_form.php
This commit is contained in:
commit
d25103c4ef
3
course/yui/toolboxes/toolboxes.js
vendored
3
course/yui/toolboxes/toolboxes.js
vendored
@ -517,7 +517,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 />')
|
||||
|
@ -54,6 +54,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'));
|
||||
|
||||
// Appearance.
|
||||
|
@ -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');
|
||||
|
||||
// Appearance.
|
||||
$mform->addElement('header', 'appearancehdr', get_string('appearance'));
|
||||
|
@ -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,7 +53,8 @@ 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');
|
||||
// Adding the optional "intro" and "introformat" pair of fields.
|
||||
$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'));
|
||||
|
||||
$wikimodeoptions = array ('collaborative' => get_string('wikimodecollaborative', 'wiki'), 'individual' => get_string('wikimodeindividual', 'wiki'));
|
||||
|
Loading…
x
Reference in New Issue
Block a user