mirror of
https://github.com/moodle/moodle.git
synced 2025-08-04 16:36:37 +02:00
MDL-10181, user management improvements fixes
This commit is contained in:
parent
0a5a42ed76
commit
c55dee3fa9
12 changed files with 127 additions and 109 deletions
|
@ -6,23 +6,22 @@ class note_edit_form extends moodleform {
|
|||
|
||||
function definition() {
|
||||
$mform =& $this->_form;
|
||||
|
||||
$mform->addElement('header', 'general', get_string('general', 'form'));
|
||||
$strcontent = get_string('content', 'notes');
|
||||
$strpublishstate = get_string('publishstate', 'notes');
|
||||
$mform->addElement('header', 'general', get_string('note', 'notes'));
|
||||
|
||||
$mform->addElement('select', 'user', get_string('user'), $this->_customdata['userlist']);
|
||||
$mform->addRule('user', get_string('nouser', 'notes'), 'required', null, 'client');
|
||||
|
||||
$mform->addElement('textarea', 'content', get_string('content', 'notes'), array('rows'=>15, 'cols'=>40));
|
||||
$mform->addElement('textarea', 'content', $strcontent, array('rows'=>15, 'cols'=>40));
|
||||
$mform->setType('content', PARAM_RAW);
|
||||
$mform->addRule('content', get_string('nocontent', 'notes'), 'required', null, 'client');
|
||||
$mform->setHelpButton('content', array('writing', 'richtext'), false, 'editorhelpbutton');
|
||||
$mform->setHelpButton('content', 'writing');
|
||||
|
||||
$mform->addElement('select', 'rating', get_string('rating', 'notes'), note_get_rating_names());
|
||||
$mform->setDefault('rating', 3);
|
||||
|
||||
$mform->addElement('select', 'publishstate', get_string('publishstate', 'notes'), note_get_state_names());
|
||||
$mform->addElement('select', 'publishstate', $strpublishstate, note_get_state_names());
|
||||
$mform->setDefault('publishstate', NOTES_STATE_PUBLIC);
|
||||
$mform->setType('publishstate', PARAM_ALPHA);
|
||||
$mform->setHelpButton('publishstate', array('status', $strpublishstate, 'notes'));
|
||||
|
||||
$this->add_action_buttons();
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue